cvs commit: hints paco.txt

tushar at linuxfromscratch.org tushar at linuxfromscratch.org
Sun Jun 20 20:17:19 PDT 2004


tushar      04/06/20 21:17:19

  Added:       .        paco.txt
  Log:
  Added Hint: paco
  
  Revision  Changes    Path
  1.1                  hints/paco.txt
  
  Index: paco.txt
  ===================================================================
  AUTHOR:   David Rosal (davidrr at menta.net)
  
  DATE:     2004-06-08
  
  LICENSE:  GNU Free Documentation License Version 1.2
  
  SYNOPSIS: Paco, installpac - Package management for LFS
  
  DESCRIPTION:
  Yet another try to provide a package manager for source-code-based systems,
  such as LFS. But I woudn't submit this hint if I did not think that it might
  be really useful. Paco comes with some nice features that you won't find in
  any other package manager, such as a gtk graphic interface, and the use of
  the LD_PRELOAD method to keep track of the files installed by the packages,
  wich is much better than the "timestamp sandwich" method.
  
  PREREQUISITES: * gtk+-2.0 or later
                 * pkg-config
                 
  ATTACHMENTS:
  Paco tarball:
  * http://www.webpersonal.net/kusoft/paco/paco-0.2.tar.bz2
  
  
  HINT:
  
  1. Installpac
  =============
  Installpac logs the installation of a new package. It uses the LD_PRELOAD
  method to keep track of all installed files, and writes the list in a log
  file.
  
  Installpac is actually a hack of "installwatch", which is described as
  follows in its home page:
  
      Installwatch is an extremely simple utility I wrote to keep track of
      created and modified files during the installation of a new program.
      It's fast and easy to use. It doesn't require a "pre-install" phase
      because it monitors processes while they run.
      Installwatch works with every dynamically linked ELF program,
      overriding system calls that cause file system alterations. Some of
      such system calls are open(2) and unlink(2).
  
  1.1 Usage
  ---------
      $ installpac [-p <package>] [OPTIONS] <command>
  
  This monitors <command> and creates a log file for the <package>, with a
  list of every created or modified file. The log is placed automatically in
  the paco log directory, where it can be read by paco.
  
  When called without a package name, like:
      
      $ installpac <command>
  
  does the same thing, but writing data to the standard output.
  The typical use is:
  
      $ installpac -p foolbar-x.y.z make install
  
  1.2 The LD_PRELOAD method
  -------------------------
  When I began to wrote paco, I used the timestamp method to log the
  installation of a new package, but I always keeped in mind that this is not
  a very reliable method. As said in the BLFS book:
      
      In this technique, a file is timestamped before the installation of
      the package. After the installation, a simple use of the find
      command with the appropriate options can generate a log of all the
      files installed after the timestamp file was created. A package
      manager written with this approach is install-log.
  
      Though this scheme has the advantage of being simple, it has two
      drawbacks. If during installation, the files are installed with any
      timestamp other than the current time, those files will not be
      tracked by the package manager. Also, this scheme can only be used
      when one package is installed at a time. The logs are not reliable
      if two packages are being installed on two different consoles. 
  
  The main advantage of the LD_PRELOAD method is that it's able to keep trace
  of a given command (e.g. "make install"), even if there are different
  processes running on the same machine. In other words: with installpac is
  possible to log different package installations at the same time.
  
  2. Paco
  =======
  Once you have installed some packages and logged them with installpac, you
  can use paco to organize your stuff.
  Paco retrieves package information from the logs, and displays it in a
  friendly format, on the console or by a gtk graphic interface. It has also
  several options to perform some basic operations on the logged packages,
  such as removing a package or querying for the owner of one or more files.
  
  2.1. Usage
  ----------
  This is a brief usage message, as displayed by "paco --help":
  
    paco [OPTIONS] <package(s)>
    paco -q <file(s)>
  
  Options:
        --block-size=SIZE  Show sizes in SIZE-byte blocks.
    -b, --bytes            Like '--block-size=1'
    -d, --show-dates       Show installation dates.
    -f, --files            List installed files
        --help             Display this help and exit
    -g, --gui              Run the gui
    -h, --human-readable   Show sizes in human readable format, like 1.2M 7k
    -k, --kilobytes        Show sizes in blocks of 1024 bytes
    -m, --missing          With '-f': list only the missing files.
                            Without '-f': Print the number of missing files
    -q, --query            Query for the package(s) that own one or more files
    -r, --remove           Remove a package
        --remove-forced    With -r: don't ask for confirmation when removing
        --remove-shared    With -r: remove also the shared files
    -R, --reverse          Reverse order while sorting
        --sort=WORD        Sort by WORD: 'size', 'date' or 'missing'
    -s, --show-sizes       Show sizes
    -t, --total            Print the total(s)
    -u, --update           Update the logs, recalculating the size of the
                            files, and setting their status (missing or not)
    -v, --version          Display version information
  
  
  ACKNOWLEDGEMENTS:
  This program was inspired mainly on Andy Goth's "install-log", which is no
  long maintained. Nevertheless, their work has been very useful to me to
  learn some C programming issues.
  Install-log can be found at:    
      --> http://ioioio.net/devel/install-log
  
  I'd also like to thank "installwatch" developers:
      --> http://asic-linux.com.mx/~izto/checkinstall/installwatch.html
  
  
  CHANGELOG:
  [2003-08-15]
    * Initial hint.
  
  
  



More information about the hints mailing list