diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2012-10-26 01:16:45 +0400 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2012-10-26 01:16:45 +0400 |
commit | 2b6b17c646c7dd75bb46b228e5290b9f4de92d88 (patch) | |
tree | 1ba5070dd5a5c378d9c64d94f34284ebf2e76bf7 | |
parent | df9ea046dafa287e80391b76efa6d71ba8c9d148 (diff) | |
download | dh-illumos-2b6b17c646c7dd75bb46b228e5290b9f4de92d88.tar.gz |
Append $($(MACH)_AS_XARCH) to $(COMPILE.s)
-rw-r--r-- | debian/changelog | 8 | ||||
-rwxr-xr-x | dh_illumos_gate | 11 |
2 files changed, 15 insertions, 4 deletions
diff --git a/debian/changelog b/debian/changelog index 8170866..5032678 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +dh-illumos (9.4) UNRELEASED; urgency=low + + * Append $($(MACH)_AS_XARCH) to $(COMPILE.s) + to make sure macros like __amd64 are undefined + for pure assembler too. + + -- Igor Pashev <pashev.igor@gmail.com> Fri, 26 Oct 2012 01:09:24 +0400 + dh-illumos (9.3) unstable; urgency=low * dh_illumos_gate: diff --git a/dh_illumos_gate b/dh_illumos_gate index 3516d8c..c750688 100755 --- a/dh_illumos_gate +++ b/dh_illumos_gate @@ -165,13 +165,15 @@ Remove option C<-s> (strip) from install command for directories and files. This options does not make sense for directories and GNU L<install(1)> is not tolerant here. Also replace option C<-f> with C<-t>. -Set C<i386_XARCH> to C<-m32> since native host compiler can produce 64-bit +Append C<i386_XARCH> with C<-m32> since native host compiler can produce 64-bit code by default. Explicitly undefine some CPP macros related to amd64 for building 32-bit -objects, e. i. options like C<-U__amd64__> are appended to C<i386_XARCH> +objects, e. i. options like C<-U__amd64> are appended to C<i386_XARCH> and C<i386_AS_XARCH>. +C<i386_AS_XARCH> flags are appended to C<COMPILE.s> command. + =cut my $multiarch = `dpkg-architecture -qDEB_HOST_MULTIARCH`; @@ -206,8 +208,9 @@ if (-f $Makefile_master) { doit('sed', '-r', '-i', ' /^INS\.(file|dir)/ s, -s,,; /^INS\.file/ s, -f, -t,; - s,^i386_XARCH\s*=.*,i386_XARCH= -m32 ' . $i386_undef . ',; - s,^i386_AS_XARCH\s*=.*,i386_AS_XARCH= ' . $i386_undef . ',; + /^i386_XARCH\s*=/s,$, -m32 ' . $i386_undef . ',; + /^i386_AS_XARCH\s*=/s,$, ' . $i386_undef . ',; + /^COMPILE\.s/s,$, $($(MACH)_AS_XARCH),; ', $Makefile_master ); } |