Package: mono-gmcs Version: 1.1.13.8-1 Severity: normal Steps to reproduce: 1) sudo apt-get build-dep mono-gmcs 2) DEB_BUILD_OPTIONS="nostrip debug noopt" fakeroot apt-get --build source mono-gmcs
Expected results: 2) mono-gmcs should build without any optimization. Actual results: 2) mono-gmcs is built using the GCC optmization option -O2. Here's an example of how gcc is called: gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I../../mono -I../../libgc/include -pthread -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -DMONO_ASSEMBLIES=\"/usr/lib\" -DMONO_CFG_DIR=\"/etc\" -DGC_LINUX_THREADS -D_GNU_SOURCE -D_REENTRANT -DUSE_MMAP -DUSE_MUNMAP -D_FILE_OFFSET_BITS=64 -O -g -O2 -fno-strict-aliasing -Wdeclaration-after-statement -g -Wall -Wunused -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wno-cast-qual -Wcast-align -Wwrite-strings -mno-tls-direct-seg-refs -MT metadata.lo -MD -MP -MF .deps/metadata.Tpo -c metadata.c -o metadata.o >/dev/null 2>&1 Proposed fix: I suggest the following modification to debian/rules: --- debian/rules.orig 2006-07-31 11:44:32.000000000 +0000 +++ debian/rules 2006-07-31 11:44:37.000000000 +0000 @@ -32,6 +32,10 @@ GC = --with-gc=included endif +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) +CFLAGS += -O0 +endif + # Include dpatch stuff. include /usr/share/dpatch/dpatch.make @@ -41,7 +45,7 @@ build: patch build-stamp build-stamp: cli-wrapper dh_testdir - ./configure $(confflags) --prefix=/usr \ + CFLAGS=$(CFLAGS) ./configure $(confflags) --prefix=/usr \ --mandir=\$${prefix}/share/man \ --infodir=\$${prefix}/share/info --sysconfdir=/etc \ --with-sigaltstack=no $(GC) --with-static_mono=no \ Here's an example of how gcc gets called after this change: gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I../../mono -I../../libgc/include -pthread -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -DMONO_ASSEMBLIES=\"/usr/lib\" -DMONO_CFG_DIR=\"/etc\" -DGC_LINUX_THREADS -D_GNU_SOURCE -D_REENTRANT -DUSE_MMAP -DUSE_MUNMAP -D_FILE_OFFSET_BITS=64 -O -O0 -fno-strict-aliasing -Wdeclaration-after-statement -g -Wall -Wunused -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wno-cast-qual -Wcast-align -Wwrite-strings -mno-tls-direct-seg-refs -MT metadata.lo -MD -MP -MF .deps/metadata.Tpo -c metadata.c -o metadata.o >/dev/null 2>&1 Btw, during testing I had to constantly rm mcs/class/lib/net_2_0/mono-api-info.exe mcs/class/lib/default/mono-api-info.exe mcs/class/Managed.Windows.Forms/resources/System.Windows.Forms.resources mcs/class/Managed.Windows.Forms/resources/System.Windows.Forms.en.resources mcs/class/Managed.Windows.Forms/resources/System.Windows.Forms.de.resources mcs/class/Managed.Windows.Forms/resources/keyboards.resources mcs/class/Novell.Directory.Ldap/Novell.Directory.Ldap.Utilclass/ResultCodeMessages.resources since the clean target did not remove those files and dpkg-buildpackage complained about "unrepresentable changes". Maybe this rm command should be added to debian/rules as well? -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]