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

Bug#471479: Generate 32bit library pacakge on amd64



Sorry,
I forgot the attachment...


_________________________________________________________________
Need to know the score, the latest news, or you need your Hotmail®-get your "fix".
http://www.msnmobilefix.com/Default.aspx
diff -Naur debian.orig/control debian/control
--- debian.orig/control	2008-03-18 10:08:29.000000000 +0100
+++ debian/control	2008-03-18 08:59:28.000000000 +0100
@@ -24,6 +24,22 @@
  <URL:http://xorg.freedesktop.org>
  <URL:http://lists.freedesktop.org/mailman/listinfo/xorg>
 
+Package: lib32xss1
+Architecture: amd64
+Section: libs
+Depends: ${shlibs:Depends}, ${bilib:depends}
+Description: X11 Screen Saver extension library (32 bit)
+ libXss (32 bit) provides an X Window System client interface to the MIT-SCREEN-SAVER
+ extension to the X protocol.
+ .
+ The Screen Saver extension allows clients behaving as screen savers to
+ register themselves with the X server, to better integrate themselves with
+ the running session.
+ .
+ More information about X.Org can be found at:
+ <URL:http://xorg.freedesktop.org>
+ <URL:http://lists.freedesktop.org/mailman/listinfo/xorg>
+
 Package: libxss1-dbg
 Section: libdevel
 Priority: extra
diff -Naur debian.orig/lib32xss1.install debian/lib32xss1.install
--- debian.orig/lib32xss1.install	1970-01-01 01:00:00.000000000 +0100
+++ debian/lib32xss1.install	2008-03-18 12:02:10.000000000 +0100
@@ -0,0 +1 @@
+emul/ia32-linux/usr/lib/libXss.so.1*
diff -Naur debian.orig/rules debian/rules
--- debian.orig/rules	2008-03-18 10:08:29.000000000 +0100
+++ debian/rules	2008-03-18 13:36:38.000000000 +0100
@@ -31,24 +31,43 @@
 	confflags += --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE)
 endif
 
+ifneq (,$(findstring /$(DEB_HOST_ARCH)/,/amd64/))
+	build32-stamp := build32-stamp
+	CROSS_CC = gcc -m32
+	lib32 := emul/ia32-linux/usr/lib
+endif
+
 
 build: patch build-stamp
-build-stamp:
+build-stamp: $(build32-stamp)
 	dh_testdir
 
 	mkdir obj-$(DEB_BUILD_GNU_TYPE)
-	cd obj-$(DEB_BUILD_GNU_TYPE) && \
-	../configure --prefix=/usr --mandir=\$${prefix}/share/man \
-	             --infodir=\$${prefix}/share/info $(confflags) \
-	             CFLAGS="$(CFLAGS)" 
+	cd obj-$(DEB_BUILD_GNU_TYPE) && ../configure \
+			--prefix=/usr --mandir=\$${prefix}/share/man \
+			--infodir=\$${prefix}/share/info $(confflags) \
+			CFLAGS="$(CFLAGS)" 
 	cd obj-$(DEB_BUILD_GNU_TYPE) && $(MAKE)
 
 	touch build-stamp
 
+build32-stamp:
+	dh_testdir
+
+	mkdir obj-$(DEB_BUILD_GNU_TYPE)-32
+	cd obj-$(DEB_BUILD_GNU_TYPE)-32 && CC="$(CROSS_CC)" ../configure \
+			--prefix=/usr --mandir=\$${prefix}/share/man \
+			--infodir=\$${prefix}/share/info $(confflags) \
+			CFLAGS="$(CFLAGS)" 
+	cd obj-$(DEB_BUILD_GNU_TYPE)-32 && $(MAKE)
+
+	touch build32-stamp
+
 clean: xsfclean
 	dh_testdir
 	dh_testroot
 	rm -f build-stamp
+	rm -f build32-stamp
 
 	rm -f config.cache config.log config.status
 	rm -f */config.cache */config.log */config.status
@@ -66,6 +85,11 @@
 
 	cd obj-$(DEB_BUILD_GNU_TYPE) && $(MAKE) DESTDIR=$(CURDIR)/debian/tmp install
 
+ifneq (,$(build32-stamp))
+	install -d debian/tmp/$(lib32)/
+	cp -a obj-$(DEB_BUILD_GNU_TYPE)-32/src/.libs/libXss.so.1* debian/tmp/$(lib32)/
+endif
+
 # Build architecture-dependent files here.
 binary-arch: build install
 	dh_testdir

Reply to: