From 38d88e649424cc8ecf1f0704b2af39f6a1a8ae3e Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Tue, 19 Oct 2004 23:23:34 +0000 Subject: 2004-10-19 Roland McGrath * debian/rules (DEB_BUILD_GNU_TYPE, CONFIG_OPTS): New variables. [$(DEB_HOST_GNU_TYPE) == s390-linux] (build64, HOST64, CC64): Set them. (build/Makefile): Use $(CONFIG_OPTS). (build64/Makefile): Pass --host as well as --build. From Steve Langasek . Fixes Debian bug #271500. --- debian/rules | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'debian/rules') diff --git a/debian/rules b/debian/rules index 1762430..633a5a6 100755 --- a/debian/rules +++ b/debian/rules @@ -3,6 +3,7 @@ # Debian package information package = strace +DEB_BUILD_GNU_TYPE := $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) DEB_HOST_GNU_TYPE := $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) ifeq ($(DEB_HOST_GNU_TYPE),sparc-linux) @@ -11,10 +12,22 @@ ifeq ($(DEB_HOST_GNU_TYPE),sparc-linux) CC64 = gcc -m64 endif +ifeq ($(DEB_HOST_GNU_TYPE),s390-linux) + build64 = yes + HOST64 = s390x-linux + CC64 = gcc -m64 +endif + ifeq ($(build64),yes) extra_build_targets += stamp-build64 endif +ifeq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE)) + CONFIG_OPTS = --build=$(DEB_BUILD_GNU_TYPE) +else + CONFIG_OPTS = --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE) +endif + all build: stamp-build stamp-%: %/Makefile @@ -23,11 +36,11 @@ stamp-%: %/Makefile build/Makefile: mkdir -p $(@D) - cd $(@D); sh ../configure --prefix=/usr + cd $(@D); sh ../configure --prefix=/usr $(CONFIG_OPTS) build64/Makefile: mkdir -p $(@D) - cd $(@D); CC="$(CC64)" sh ../configure --prefix=/usr --build=$(HOST64) + cd $(@D); CC="$(CC64)" sh ../configure --prefix=/usr --build=$(DEB_BUILD_GNU_TYPE) --host=$(HOST64) clean: rm -rf debian/tmp debian/substvars debian/files -- cgit v1.2.3