[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#475333: FTBFS on parallel build (dpkg-buildpackage -j)

Package: qt-x11-free
Version: 3.3.8b-5
Severity: important
Tags: patch

Fails to build from source on parallel build (dpkg-buildpackage -j2) due to
a race condition in debian/rules.

The first hunk fixes that, the rest fixes improper use of "make" that discards
make flags, making -j parameter useless.

-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.18-6-amd64 (SMP w/2 CPU cores)
Locale: LANG=ca_AD.UTF-8, LC_CTYPE=ca_AD.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
diff -ur qt-x11-free-3.3.8b/debian/rules qt-x11-free-3.3.8b.new/debian/rules
--- qt-x11-free-3.3.8b/debian/rules	2008-04-09 20:08:24.000000000 +0200
+++ qt-x11-free-3.3.8b.new/debian/rules	2008-04-09 20:48:24.000000000 +0200
@@ -109,11 +109,11 @@
-build: $(QUILT_STAMPFN) libqt-thread-stamp
+build: libqt-thread-stamp
 	touch build-stamp
+libqt-thread-stamp: $(QUILT_STAMPFN)
 	@echo "QTDIR is ${QTDIR}"
@@ -127,10 +127,10 @@
 	ln -s ../src/inputmethod/qinputcontextplugin.h include/qinputcontextplugin.h
 	# proceed
-	make sub-src sub-plugins sub-tools
-	make -C src INSTALL_ROOT=$(TMP_INSTALL) install_target
-	make INSTALL_ROOT=$(TMP_INSTALL) install
-	make INSTALL_ROOT=$(TMP_INSTALL) plugins-install
+	$(MAKE) sub-src sub-plugins sub-tools
+	$(MAKE) -C src INSTALL_ROOT=$(TMP_INSTALL) install_target
+	$(MAKE) INSTALL_ROOT=$(TMP_INSTALL) plugins-install
 	# archives get accidentally stripped by make install. Copy over unstripped ones for now.
 	cp lib/lib*.a $(TMP_INSTALL)/usr/lib/
@@ -140,11 +140,11 @@
 	cp bin/findtr $(TMP_INSTALL)/usr/bin/
 	# build conv2ui
-	cd tools/designer/tools/conv2ui && make
+	cd tools/designer/tools/conv2ui && $(MAKE)
 	cp bin/conv2ui $(TMP_INSTALL)/usr/bin/conv2ui
 	# build qvfb
-	cd tools/qvfb/ && make
+	cd tools/qvfb/ && $(MAKE)
 	cp tools/qvfb/qvfb $(TMP_INSTALL)/usr/bin/qvfb
 	# install qmake.cache file
@@ -172,12 +172,12 @@
 	-chmod a-x doc/html/layout?.png
 	if [ -f "src/Makefile" ]; then \
-		make -C src clean; make -C plugins/src distclean; make -C tools distclean; \
-		make -C tools/makeqpf distclean; make -C tools/qconfig distclean; make -C tools/qvfb distclean; \
-		make -C tools/msg2qm distclean; make -C tools/mergetr distclean; make -C tools/qembed distclean; \
-		make -C tools/designer/tools/conv2ui distclean; make -C tools/designer/tools/createcw distclean; \
-		make -C tools/designer/plugins/glade distclean; make -C tools/designer/plugins/qglwidget distclean; \
-		make -C config.tests/unix/largefile distclean; make -C qmake distclean; \
+		$(MAKE) -C src clean; $(MAKE) -C plugins/src distclean; $(MAKE) -C tools distclean; \
+		$(MAKE) -C tools/makeqpf distclean; $(MAKE) -C tools/qconfig distclean; $(MAKE) -C tools/qvfb distclean; \
+		$(MAKE) -C tools/msg2qm distclean; $(MAKE) -C tools/mergetr distclean; $(MAKE) -C tools/qembed distclean; \
+		$(MAKE) -C tools/designer/tools/conv2ui distclean; $(MAKE) -C tools/designer/tools/createcw distclean; \
+		$(MAKE) -C tools/designer/plugins/glade distclean; $(MAKE) -C tools/designer/plugins/qglwidget distclean; \
+		$(MAKE) -C config.tests/unix/largefile distclean; $(MAKE) -C qmake distclean; \
 	-rm -rf .qmake.cache src/.qmake.internal.cache tools/designer/designer/.qmake.internal.cache qmake/GNUmakefile \

Reply to: