I have updated the patch so that it uses DEB_BUILD_OPTIONS to set the flag to compile the static form of gcc. The option will now be enabled if the user specifies the option 'static' as one of the DEB_BUILD_OPTIONS. This can be done on the command line for dpkg-buildpackage as follows:

DEB_CROSS_NO_BIARCH=yes GCC_TARGET=armel DEB_CROSS=yes DEB_BUILD_OPTIONS="static" dpkg-buildpackage -us -uc -rfakeroot


--- gcc-4.4-4.4.4/debian/rules2.orig	2010-07-26 13:39:49.000000000 -0400
+++ gcc-4.4-4.4.4/debian/rules2	2010-07-26 13:39:07.000000000 -0400
@@ -119,6 +119,10 @@
   CFLAGS	= -g -O2
 endif
 
+ifneq (,$(findstring static,$(DEB_BUILD_OPTIONS)))
+  LDFLAGS	+= -static
+endif
+
 CFLAGS_TO_PASS = \
 	$(if $(CFLAGS),CFLAGS="$(CFLAGS)") \
 	$(if $(BOOT_CFLAGS),BOOT_CFLAGS="$(BOOT_CFLAGS)") \

Reply via email to