/[ddp]/manuals/trunk/apt-howto/apt-howto-en.sgml
ViewVC logotype

Diff of /manuals/trunk/apt-howto/apt-howto-en.sgml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1225 by kov, Sat Aug 11 05:16:27 2001 UTC revision 1234 by kov, Tue Aug 21 22:25:10 2001 UTC
# Line 8  Line 8 
8  <name>Gustavo Noronha Silva</name> <email>kov@debian.org</email>  <name>Gustavo Noronha Silva</name> <email>kov@debian.org</email>
9  </author>  </author>
10    
11  <version>1.5 - August 2001</version>  <version>1.6 - August 2001</version>
12    
13  <abstract>  <abstract>
14  This document intends to provide the user with a good understanding  This document intends to provide the user with a good understanding
# Line 117  mkdir /root/debs Line 117  mkdir /root/debs
117  </example>  </example>
118  So, inside the directory /root, create an empty file, with any name.  So, inside the directory /root, create an empty file, with any name.
119  That is because an APT repository needs a file known as "override",  That is because an APT repository needs a file known as "override",
120  it may be empty, but it have to exist. One may use the following  it may be empty, but it has to exist. One may use the following
121  command to create this file:  command to create this file:
122  <example>  <example>
123  touch file  touch file
# Line 131  package is the name of the package, prio Line 131  package is the name of the package, prio
131  high and section is the section to which it belongs. It is enough  high and section is the section to which it belongs. It is enough
132  to leave the file empty/  to leave the file empty/
133  <p>  <p>
134  Still in the /root directoy do:  Still in the /root directory do:
135  <example>  <example>
136  dpkg-scanpackages debs file | gzip > debs/Packages.gz  dpkg-scanpackages debs file | gzip > debs/Packages.gz
137  </example>  </example>
138  In the above line, file is the "override" file, the command  In the above line, file is the "override" file, the command
139  generates a file debs/Packages.gz that contains various  generates a file debs/Packages.gz that contains various
140  informations about the packages, which are used by APT. To use  informations about the packages, which are used by APT. To use
141  the packages, finaly, add:  the packages, finally, add:
142  <example>  <example>
143  deb file:/root debs/  deb file:/root debs/
144  </example>  </example>
145  After that just use the APT commands as usual. You may also generate  After that just use the APT commands as usual. You may also generate
146  a sources repository. To do that use the same procedore,  a sources repository. To do that use the same procedure,
147  but remember that you need to have the files <tt>.orig.tar.gz</tt>,  but remember that you need to have the files <tt>.orig.tar.gz</tt>,
148  <tt>.dsc</tt> and <tt>.diff.gz</tt> in the directory and you  <tt>.dsc</tt> and <tt>.diff.gz</tt> in the directory and you
149  have to use Sources.gz instead of Packages.gz. The program used  have to use Sources.gz instead of Packages.gz. The program used
# Line 201  ftp.debian.org.br Line 201  ftp.debian.org.br
201    365 ftp.debian.org.br    365 ftp.debian.org.br
202  bash$  bash$
203  </example>  </example>
204  This shows the same result as before, but it presents statistics of all  This shows the same results as before, but it presents statistics of all
205  the other hosts. The second column is the estimated ping time (in ms),  the other hosts. The second column is the estimated ping time (in ms),
206  the third is the number of hops between your machine and the host,  the third is the number of hops between your machine and the host,
207  the forth is the packet loss percentual between your machine and the  the fourth is the packet loss percenage between your machine and the
208  host, and the last is the score.  host, and the last is the score.
209  <p>  <p>
210  <strong>Note:</strong> alista of mirrors may always be found in the file  <strong>Note:</strong> the list of mirrors may always be found in the file
211  README.mirrors.txt in the debian/ directory of each mirror (for example,  README.mirrors.txt in the debian/ directory of each mirror (for example,
212  <url id="http://http.us.debian.org/debian/README.mirrors.txt" name="http://http.us.debian.org/debian/README.mirrors.txt">)  <url id="http://http.us.debian.org/debian/README.mirrors.txt" name="http://http.us.debian.org/debian/README.mirrors.txt">)
213  </sect>  </sect>
# Line 260  configured in your system's <tt>/etc/fst Line 260  configured in your system's <tt>/etc/fst
260  <sect id="update">Updating the list of available packages  <sect id="update">Updating the list of available packages
261  <p>  <p>
262  The packaging system uses a private database to keep track of which  The packaging system uses a private database to keep track of which
263  packages are installed, which are not and which are available for  packages are installed, which are not installed and which are available for
264  installation.  The <prgn>apt-get</prgn> program uses this database to  installation.  The <prgn>apt-get</prgn> program uses this database to
265  find out how to install packages requested by the user and to find out  find out how to install packages requested by the user and to find out
266  which additional packages are needed in order for a selected package to  which additional packages are needed in order for a selected package to
# Line 287  you can run: Line 287  you can run:
287  apt-get install xchat  apt-get install xchat
288  </example>  </example>
289    
290  APT will search its database for the most recent version of this package and  APT will search it's database for the most recent version of this package and
291  will retrieve it from the corresponding archive as specified in  will retrieve it from the corresponding archive as specified in
292  <tt>sources.list</tt>.  In the event that this package depends on another --  <tt>sources.list</tt>.  In the event that this package depends on another --
293  as is the case here -- APT will check the dependencies and install the  as is the case here -- APT will check the dependencies and install the
# Line 306  Need to get 8329kB of archives. After un Line 306  Need to get 8329kB of archives. After un
306  Do you want to continue? [Y/n]  Do you want to continue? [Y/n]
307  </example>  </example>
308    
309  The package <package>nautilus</package> depends on the shared libs cited,  The package <package>nautilus</package> depends on the shared libraries cited,
310  therefore APT will get them from the archive.  If you had  therefore APT will get them from the archive.  If you had
311  specified the names of these libraries on the <tt>apt-get</tt> command line,  specified the names of these libraries on the <tt>apt-get</tt> command line,
312  APT would not have asked if you wanted to continue; it would automatically  APT would not have asked if you wanted to continue; it would automatically
# Line 365  Do you want to continue? [Y/n] Line 365  Do you want to continue? [Y/n]
365  </example>  </example>
366    
367  The version of APT used in the creation of this manual is version 0.5.3,  The version of APT used in the creation of this manual is version 0.5.3,
368  the current version in Debian `unstable' (<tt>sid</tt>) at the time of  wich was the current version in Debian `unstable' (<tt>sid</tt>) at the time of
369  writing. If you have this version installed, you have additional  writing. If you have this version installed, you have additional
370  functionality at your disposal: you can use a command of the form  functionality at your disposal: you can use a command of the form
371  <tt>apt-get install package/distribution</tt> to install a package from a  <tt>apt-get install package/distribution</tt> to install a package from a
# Line 430  Need to get 0B of archives. After unpack Line 430  Need to get 0B of archives. After unpack
430  Do you want to continue? [Y/n]  Do you want to continue? [Y/n]
431  </example>  </example>
432    
433  Note the '*' in front of the names.  This indicates that the configuration  Note the '*' after the names.  This indicates that the configuration
434  files for each of these packages will also be removed.  files for each of these packages will also be removed.
435  <p>  <p>
436  Just as in the case of the <tt>install</tt> method, you can use a symbol  Just as in the case of the <tt>install</tt> method, you can use a symbol
# Line 516  It is also used when changes are made to Line 516  It is also used when changes are made to
516  packages.  With <tt>apt-get upgrade</tt>, these packages would be kept  packages.  With <tt>apt-get upgrade</tt>, these packages would be kept
517  untouched (<tt>kept back</tt>).  untouched (<tt>kept back</tt>).
518  <p>  <p>
519  For example, supposing that you're using revision 0 of the stable version of  For example, suppose that you're using revision 0 of the stable version of
520  Debian and you buy a CD with revision 3, you can use APT to upgrade your  Debian and you buy a CD with revision 3. You can use APT to upgrade your
521  system from this new CD.  To do this, use <prgn>apt-cdrom</prgn>  system from this new CD. To do this, use <prgn>apt-cdrom</prgn>
522  (see section <ref id="cdrom">) to add the CD to your  (see section <ref id="cdrom">) to add the CD to your
523  <tt>/etc/apt/sources.list</tt> and run <tt>apt-get dist-upgrade</tt>.  <tt>/etc/apt/sources.list</tt> and run <tt>apt-get dist-upgrade</tt>.
524  <p>  <p>
# Line 659  section a package is in, what its priori Line 659  section a package is in, what its priori
659  But... our goal here is to learn how to use pure APT.  So how can you find  But... our goal here is to learn how to use pure APT.  So how can you find
660  out the name of a package that you want to install?  out the name of a package that you want to install?
661  <p>  <p>
662  We have a number of resources for such a task.  We'll beging with  We have a number of resources for such a task.  We'll begin with
663  <tt>apt-cache</tt>.  This program is used by the APT system for maintaining  <tt>apt-cache</tt>.  This program is used by the APT system for maintaining
664  its database.  We'll take just a brief look at some of its more practical  its database.  We'll take just a brief look at some of its more practical
665  applications.  applications.
# Line 667  applications. Line 667  applications.
667  <sect id="cache">Discovering package names  <sect id="cache">Discovering package names
668  <p>  <p>
669  For example, suppose that you want to reminisce about the good old days of  For example, suppose that you want to reminisce about the good old days of
670  the atari 2600.  You want to use APT to install an atari emulator, and then  the Atari 2600.  You want to use APT to install an Atari emulator, and then
671  download some games.  You can do:  download some games.  You can do:
672    
673  <example>  <example>
# Line 830  You're compiling a program and, all of a Line 830  You're compiling a program and, all of a
830  because it needs a <tt>.h</tt> file you don't have.  The program  because it needs a <tt>.h</tt> file you don't have.  The program
831  <prgn>auto-apt</prgn> can save you from such scenarios.  It asks you to  <prgn>auto-apt</prgn> can save you from such scenarios.  It asks you to
832  install packages if they're needed, stopping the relevant process and  install packages if they're needed, stopping the relevant process and
833  continiuing once the package is installed.  continuing once the package is installed.
834  <p>  <p>
835  What you do, basically, is run:  What you do, basically, is run:
836    
# Line 959  Conectiva (<url id="http://www.conectiva Line 959  Conectiva (<url id="http://www.conectiva
959  <p>  <p>
960  Mandrake (<url id="http://www.mandrake.com" name="http://www.mandrake.com">)  Mandrake (<url id="http://www.mandrake.com" name="http://www.mandrake.com">)
961  <p>  <p>
962  PLD (<url id="http://pld.org.pl" name="http://pld.org.pl">)  PLD (<url id="http://www.pld.org.pl" name="http://pld.org.pl">)
963  <p>  <p>
964  Vine (<url id="http://www.vinelinux.org" name="http://www.vinelinux.org">)  Vine (<url id="http://www.vinelinux.org" name="http://www.vinelinux.org">)
965  </chapt>  </chapt>
# Line 969  Vine (<url id="http://www.vinelinux.org" Line 969  Vine (<url id="http://www.vinelinux.org"
969  <sect id="erros-comuns">Common errors  <sect id="erros-comuns">Common errors
970  <p>  <p>
971  Errors will always happen, many of them caused by users not paying  Errors will always happen, many of them caused by users not paying
972  attention.  I list here some of the most frequently reported errors and  attention.  The following is a list of some of the most frequently reported errors and
973  how to deal with them.  how to deal with them.
974  <p>  <p>
975  If you receive a message that looks like the one below when trying to  If you receive a message that looks like the one below when trying to
# Line 978  run <tt>apt-get install package</tt>... Line 978  run <tt>apt-get install package</tt>...
978  <example>  <example>
979  Reading Package Lists... Done  Reading Package Lists... Done
980  Building Dependency Tree... Done  Building Dependency Tree... Done
981  W: Couldn't stat source package list 'http://people.debian.org unstable/ Packages' (/var/state/apt/lists/people.debian.org_%7ekov_debian_unstable_Packages) - stat (2 Arquivo ou diretório não encontrado)  W: Couldn't stat source package list 'http://people.debian.org unstable/ Packages' (/var/state/apt/lists/people.debian.org_%7ekov_debian_unstable_Packages) - stat (2 No such file or directory)
982  W: You may want to run apt-get update to correct these missing files  W: You may want to run apt-get update to correct these missing files
983  E: Couldn't find package penguineyes  E: Couldn't find package penguineyes
984  </example>  </example>
# Line 1050  our project and to all the free projects Line 1050  our project and to all the free projects
1050    
1051  And special thanks to:  And special thanks to:
1052  <p>  <p>
1053    Bryan &lt;Stillwell bryan@bokeoa.com&gt; - for the various patches
1054    and corrections he sent to me.
1055    <p>
1056    Tecza Pawel &lt;pawel.tecza@poland.com&gt; - for the various corrections
1057    he sent.
1058    <p>
1059  Pablo Lorenzzoni &lt;spectra@debian.org&gt; - for writing the section  Pablo Lorenzzoni &lt;spectra@debian.org&gt; - for writing the section
1060  about netselect.  about netselect.
1061  <p>  <p>
# Line 1058  manual to english. Line 1064  manual to english.
1064  <p>  <p>
1065  Arnaldo Carvalho de Melo &lt;acme@conectiva.com.br&gt; - for  Arnaldo Carvalho de Melo &lt;acme@conectiva.com.br&gt; - for
1066  contributing the list of additional distributions that now include APT:  contributing the list of additional distributions that now include APT:
1067  Mandrake, PLD e Vine.  Mandrake, PLD and Vine.
1068  </chapt>  </chapt>
1069    
1070  <chapt id="novas">New versions of this tutorial  <chapt id="novas">New versions of this tutorial

Legend:
Removed from v.1225  
changed lines
  Added in v.1234

  ViewVC Help
Powered by ViewVC 1.1.5