2009-06-22 18:06:58 +03:00
|
|
|
#!/usr/bin/make -f
|
2010-04-05 06:42:07 +03:00
|
|
|
# This file is in the public domain.
|
|
|
|
# You may freely use, modify, distribute, and relicense it.
|
2009-06-22 18:06:58 +03:00
|
|
|
|
2010-04-05 06:42:07 +03:00
|
|
|
build clean install binary-arch binary-indep binary:
|
|
|
|
+dh --parallel $(opt_no_act) $@
|
2009-06-22 18:06:58 +03:00
|
|
|
|
2010-04-05 06:42:07 +03:00
|
|
|
override_dh_auto_clean:
|
2010-04-05 06:45:12 +03:00
|
|
|
test -e debian/xburst_stage1.bin || { \
|
|
|
|
echo >&2 see debian/README.source; \
|
|
|
|
exit 1; \
|
|
|
|
}
|
2010-04-05 06:42:07 +03:00
|
|
|
dh_auto_clean
|
|
|
|
sh debian/clean.sh
|
2009-06-22 18:06:58 +03:00
|
|
|
|
2010-04-05 06:45:12 +03:00
|
|
|
override_dh_auto_configure: configure
|
|
|
|
dh_auto_configure -- $(opt_optimize) $(opt_quiet) \
|
|
|
|
--disable-firmware LDFLAGS=-Wl,-z,defs
|
|
|
|
|
|
|
|
override_dh_auto_install:
|
|
|
|
dh_auto_install
|
|
|
|
: install firmware from source package
|
|
|
|
dh_install debian/xburst_stage1.bin usr/share/xburst-tools/
|
|
|
|
dh_install debian/xburst_stage2.bin usr/share/xburst-tools/
|
2009-06-22 18:06:58 +03:00
|
|
|
|
2010-04-05 06:42:07 +03:00
|
|
|
opt_optimize = CFLAGS="-g -O2"
|
|
|
|
opt_no_act =
|
|
|
|
opt_quiet =
|
2009-06-22 18:06:58 +03:00
|
|
|
|
2010-04-05 06:42:07 +03:00
|
|
|
ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
|
|
|
|
opt_optimize = CFLAGS="-g -O0"
|
2009-06-22 18:06:58 +03:00
|
|
|
endif
|
|
|
|
|
2010-04-05 06:42:07 +03:00
|
|
|
ifneq (,$(findstring n,$(MAKEFLAGS)))
|
|
|
|
opt_no_act = --no-act
|
|
|
|
endif
|
2009-06-22 18:06:58 +03:00
|
|
|
|
2010-04-05 06:42:07 +03:00
|
|
|
ifneq (,$(filter quiet,$(DEB_BUILD_OPTIONS)))
|
|
|
|
opt_quiet = --quiet
|
|
|
|
MAKEFLAGS += --quiet
|
|
|
|
endif
|
2010-04-05 06:45:12 +03:00
|
|
|
|
|
|
|
configure: configure.ac
|
|
|
|
AUTOMAKE="automake --foreign" autoreconf -is
|
|
|
|
|
|
|
|
firmware: configure
|
|
|
|
./configure --enable-firmware
|
|
|
|
$(MAKE) -C src ../xburst_stage1/xburst_stage1.bin \
|
|
|
|
../xburst_stage2/xburst_stage2.bin
|