Chapter 4. Source packages
24
The
build
target must not do anything that might require root privilege.
The
build
target may need to run the
clean
target first   see below.
When a package has a configuration and build routine which takes a long time, or when
the makefiles are poorly designed, or when
build
needs to run
clean
first, it is a
good idea to
touch build
when the build process is complete. This will ensure that
if
debian/rules build
is run again it will not rebuild the whole program.
13
build arch
(optional),
build indep
(optional) A package may also provide both of the
targets
build arch
and
build indep
. The
build arch
target, if provided, should
perform all the configuration and compilation required for producing all architecture 
dependant binary packages (those packages for which the body of the
Architecture
field in
debian/control
is not
all
). Similarly, the
build indep
target, if pro 
vided, should perform all the configuration and compilation required for producing all
architecture independent binary packages (those packages for which the body of the
Architecture
field in
debian/control
is
all
). The
build
target should depend
on those of the targets
build arch
and
build indep
that are provided in the rules
file.
If one or both of the targets
build arch
and
build indep
are not provided, then
invoking
debian/rules
with one of the not provided targets as arguments should pro 
duce a exit status code of 2. Usually this is provided automatically by make if the target
is missing.
The
build arch
and
build indep
targets must not do anything that might require
root privilege.
binary
,
binary arch
,
binary indep
The
binary
target must be all that is necessary for
the user to build the binary package(s) produced from this source package. It is split into
two parts:
binary arch
builds the binary packages which are specific to a particular
architecture, and
binary indep
builds those which are not.
binary
may be (and commonly is) a target with no commands which simply depends
on
binary arch
and
binary indep
.
Both
binary *
targets should depend on the
build
target, or on the appropriate
build arch
or
build indep
target, if provided, so that the package is built if it
has not been already.
It should then create the relevant binary package(s), using
dpkg gencontrol
to make their control files and
dpkg deb
to build them and place
them in the parent of the top level directory.
Both the
binary arch
and
binary indep
targets must exist. If one of them has noth 
ing to do (which will always be the case if the source generates only a single binary
package, whether architecture dependent or not), it must still exist and must always suc 
ceed.
13
Another common way to do this is for
build
to depend on
build stamp
and to do nothing else, and for the
build stamp
target to do the building and to
touch build stamp
on completion. This is especially useful if
the build routine creates a file or directory called
build
; in such a case,
build
will need to be listed as a phony
target (i.e., as a dependency of the
.PHONY
target). See the documentation of
make
for more information on phony
targets.






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

gay web hosting

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Inexpensive Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Jsp Hosting Cheap Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved