MAKEPKG

Section: Maintenance Commands (8)
Updated: 21 May 1994
Index Return to Main Contents
 

NAME

makepkg - make Slackware packages.  

SYNOPSIS

makepkg packagename  

DESCRIPTION

makepkg creates a new Slackware compatible package. The package is constructed using the contents of the current directory and all subdirectories. If symbolic links exist, they will be converted to script code to recreate them when the package is installed. This code will be appended to the primary installation script ( install/doinst.sh ) , or, if that script does not exist it will be created with those contents. The package will be written out to the file packagename which should be the full name, including the extension (usually .tgz).  

INSTALLATION SCRIPTS

There are 3 types of installation scripts supported in the Slackware package system.
The first is the
primary installation script. This is found in the subdirectory ./install and must have the name doinst.sh in order to be recognized. This ( and other install scripts ) should be written using the basic Bourne shell syntax recognized by the ash shell, since this is the shell that will be used to execute the script when installing from a Slackware install floppy. This is a common trap - beware of using bash syntax extensions, because the script will work fine when installed from the hard drive, but will bomb out when installed from floppy. If the package is for personal use, this isn't a problem. Be careful, though, if you plan to share your package with other users. The primary installation script is executed immediately after the package is installed with installpkg, pkgtool, or setup.
The second type of script is the
configuration script. This is found in the subdirectory ./var/adm/setup and must have a name that starts with setup. in order to be recongnized. An example is the timezone script: /var/adm/setup/setup.timeconfig. These scripts are executed during the CONFIGURE phase of setup, and are re-executed each time the user runs the CONFIGURE option from setup from then on. Typically, the user will go through this phase of setup following the installation of all the packages. Anything that needs to be interactive should go in one of these scripts to avoid halting the package installation process during setup.
The third type of script is the
onlyonce script. Like the name suggests, these are executed only once after the package is installed, in contrast to the standard configuration script. These scripts are also found in the ./var/adm/setup directory and must have a name that starts with setup., but in addition the name must contain the string onlyonce. An example might be a script with the name /var/adm/setup/setup.onlyonce.testscript
 

PACKAGE FORMAT

makepkg uses GNU tar plus GNU gzip to create its packages. A simple way to extract the contents of a package (without executing the installation scripts, of course) is to use a command like this:
tar xzvvf package.tgz
 

AUTHOR

Patrick J. Volkerding <volkerdi@mhd1.moorhead.msus.edu>  

SEE ALSO

installpkg(8), explodepkg(8), removepkg(8), pkgtool(8), setup(8)


 

Index

NAME
SYNOPSIS
DESCRIPTION
INSTALLATION SCRIPTS
PACKAGE FORMAT
AUTHOR
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 21:01:11 GMT, January 12, 2025