[Python-modules-commits] r3339 - in /packages/pynxt/trunk/debian: control rules

danderson-guest at users.alioth.debian.org danderson-guest at users.alioth.debian.org
Sun Sep 30 14:51:47 UTC 2007


Author: danderson-guest
Date: Sun Sep 30 14:51:47 2007
New Revision: 3339

URL: http://svn.debian.org/wsvn/python-modules/?sc=1&rev=3339
Log:
Change debian/rules to build the firmware blob from scratch only if explicitely requested.


Modified:
    packages/pynxt/trunk/debian/control
    packages/pynxt/trunk/debian/rules

Modified: packages/pynxt/trunk/debian/control
URL: http://svn.debian.org/wsvn/python-modules/packages/pynxt/trunk/debian/control?rev=3339&op=diff
==============================================================================
--- packages/pynxt/trunk/debian/control (original)
+++ packages/pynxt/trunk/debian/control Sun Sep 30 14:51:47 2007
@@ -3,8 +3,7 @@
 Priority: optional
 Maintainer: David Anderson <dave at natulte.net>
 Uploaders: Debian Python Modules Team <python-modules-team at lists.alioth.debian.org>, Bernd Zeimetz <bernd at bzed.de>
-Build-Depends: debhelper (>= 5), python-all, python-support (>= 0.3),
- python-pynxt | binutils-source, python-pynxt | gcc-4.2-source
+Build-Depends: debhelper (>= 5), python-all, python-support (>= 0.3)
 Standards-Version: 3.7.2
 XS-Vcs-Svn: svn://svn.debian.org/python-modules/packages/pynxt/trunk/
 XS-Vcs-Browser: http://svn.debian.org/wsvn/python-modules/packages/pynxt/trunk/

Modified: packages/pynxt/trunk/debian/rules
URL: http://svn.debian.org/wsvn/python-modules/packages/pynxt/trunk/debian/rules?rev=3339&op=diff
==============================================================================
--- packages/pynxt/trunk/debian/rules (original)
+++ packages/pynxt/trunk/debian/rules Sun Sep 30 14:51:47 2007
@@ -7,11 +7,10 @@
 PKGNAME := python-pynxt
 PYVERS := $(shell pyversions -r)
 
-# location of the firmware in the old package, if available
-OLD_FIRMWARE := /usr/share/python-support/python-pynxt/nxt/flash_driver.bin
-
-#we need to build the firmware if we don't have it...
-ifeq "$(wildcard $(OLD_FIRMWARE))" ""
+# Setting the rebuild_flash_driver option will do a complete rebuild of
+# the flash driver blob, which includes building the appropriate
+# cross-compiler.
+ifneq (,$(findstring rebuild_flash_driver,$(DEB_BUILD_OPTIONS)))
 
 #first find our build dependencies:
 GCC_SOURCE = $(shell dpkg -L gcc-4.2-source | grep "/usr/src/gcc-4.2/gcc-4.2.*.tar.bz2")
@@ -53,11 +52,16 @@
 	    $(MAKE) all-gcc install-gcc
 	touch $@
 
+clean_flash_driver.bin:
+	rm -f flash_driver.bin
+
 else
 
-flash_driver.bin: 
-	cp $(OLD_FIRMWARE) .
+flash_driver.bin:
+# Nothing to do here.
 
+clean_flash_driver.bin:
+# Nothing to do here.
 endif
 
 build: build-stamp
@@ -71,10 +75,7 @@
 
 	touch $@
 
-clean_flash_driver.bin:
-	rm -f flash_driver.bin
-
-ifeq "$(wildcard $(OLD_FIRMWARE))" ""
+ifneq (,$(findstring rebuild_flash_driver,$(DEB_BUILD_OPTIONS)))
 clean_toolchain:
 	for dir in $(TOOLCHAIN_DIR) $(GCC_DIR) $(BINUTILS_DIR); do \
 	    [ ! -d "$$dir" ] || rm -rf $$dir ;\
@@ -82,7 +83,7 @@
 .PHONY: clean_toolchain
 clean: clean_flash_driver.bin clean_toolchain
 else
-clean: clean_flash_driver.bin
+clean:
 endif
 	dh_testdir
 	dh_testroot
@@ -92,7 +93,7 @@
 	find . -name \*.pyc | xargs rm -f
 	rm -rf build
 	rm -f install-stamp build-stamp
-	dh_clean 
+	dh_clean
 
 install: install-stamp
 install-stamp:




More information about the Python-modules-commits mailing list