1
0
mirror of git://projects.qi-hardware.com/xburst-tools.git synced 2024-11-01 18:05:18 +02:00
xburst-tools/usbboot/debian/rules
Jonathan Nieder 3d82483481 debian/rules: rewrite as a minimal debian/rules file (using dh)
This makes the packaging easier to read and modify.

Features added:

 * runs ‘make’ with the -j option for a tiny speedup
 * uses appropriate compiler flags even when run directly instead of
   through dpkg-buildpackage
 * after interrupting a partial build, there is no need any more
   for (fake) root privileges to clean up
 * after interrupting a partial build, ‘debian/rules clean’ will
   work without running autoreconf again.

Features retained:

 * ‘debian/rules -n <target>’ provides the list of commands used
   to make that target.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
2010-04-05 14:56:44 +08:00

32 lines
727 B
Makefile
Executable File

#!/usr/bin/make -f
# This file is in the public domain.
# You may freely use, modify, distribute, and relicense it.
build clean install binary-arch binary-indep binary:
+dh --parallel $(opt_no_act) $@
override_dh_auto_clean:
dh_auto_clean
sh debian/clean.sh
override_dh_auto_configure:
AUTOMAKE="automake --foreign" autoreconf -is
dh_auto_configure -- $(opt_optimize) $(opt_quiet) LDFLAGS=-Wl,-z,defs
opt_optimize = CFLAGS="-g -O2"
opt_no_act =
opt_quiet =
ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
opt_optimize = CFLAGS="-g -O0"
endif
ifneq (,$(findstring n,$(MAKEFLAGS)))
opt_no_act = --no-act
endif
ifneq (,$(filter quiet,$(DEB_BUILD_OPTIONS)))
opt_quiet = --quiet
MAKEFLAGS += --quiet
endif