summaryrefslogtreecommitdiff
path: root/mk/compiler
diff options
context:
space:
mode:
authortnn <tnn>2015-04-27 10:33:49 +0000
committertnn <tnn>2015-04-27 10:33:49 +0000
commitc2b2f834185256ef4154cd081d8a9b351270e925 (patch)
tree771c99373e13fe9ca49373c9325def548cdcf2db /mk/compiler
parent0d652be94b49fcabeb5cfe2c3c6d200e2978e3f4 (diff)
downloadpkgsrc-c2b2f834185256ef4154cd081d8a9b351270e925.tar.gz
correct MACHINE_ARCH and compiler flags for HP-UX 64-bit ABI
Diffstat (limited to 'mk/compiler')
-rw-r--r--mk/compiler/gcc.mk13
1 files changed, 10 insertions, 3 deletions
diff --git a/mk/compiler/gcc.mk b/mk/compiler/gcc.mk
index 61ad5e6c7e0..4d2592634f2 100644
--- a/mk/compiler/gcc.mk
+++ b/mk/compiler/gcc.mk
@@ -1,4 +1,4 @@
-# $NetBSD: gcc.mk,v 1.160 2015/04/25 10:33:29 wiz Exp $
+# $NetBSD: gcc.mk,v 1.161 2015/04/27 10:33:49 tnn Exp $
#
# This is the compiler definition for the GNU Compiler Collection.
#
@@ -786,8 +786,15 @@ _COMPILER_STRIP_VARS+= ${_GCC_VARS}
IMAKEOPTS+= -DHasGcc2=YES -DHasGcc2ForCplusplus=YES
.endif
-_COMPILER_ABI_FLAG.32= -m32
-_COMPILER_ABI_FLAG.64= -m64
+# On HP-UX the GCC toolchain must be specifically targeted to an ABI,
+# -m32 or -m64 are not recognized.
+.if ${OPSYS} == "HPUX"
+_COMPILER_ABI_FLAG.32= # empty
+_COMPILER_ABI_FLAG.64= # empty
+.else
+_COMPILER_ABI_FLAG.32= -m32
+_COMPILER_ABI_FLAG.64= -m64
+.endif
.if !empty(_USE_PKGSRC_GCC:M[yY][eE][sS])
. if exists(${CCPATH})