Change the way that ${MULTILIB_SUPPORTED} is used.
Three situations need it be handled: 1) Multilib support is unknowen, i.e. there is nothing in the options.mk file to appropriately set ${MULTILIB_SUPPORTED} (currently all platforms except Linux/x86_64). In this situation nothing should be done. 2) Multilib _is_ supported, in this situation the 'gcc-multilib' option should be made available and the CONFIGURE_ARGS modified accordingly. 3) Multilib _is not_ supported, in this situation CONFIGURE_ARGS need to be modified.
This commit is contained in:
parent
2ae1dd615b
commit
c1593c8a8d
1 changed files with 12 additions and 7 deletions
|
@ -1,4 +1,4 @@
|
|||
# $NetBSD: options.mk,v 1.2 2012/04/18 07:10:40 obache Exp $
|
||||
# $NetBSD: options.mk,v 1.3 2012/04/22 08:14:22 sbd Exp $
|
||||
|
||||
PKG_OPTIONS_VAR= PKG_OPTIONS.${GCC_PKGNAME}
|
||||
PKG_SUPPORTED_OPTIONS= nls gcc-inplace-math gcc-c++ gcc-fortran gcc-java \
|
||||
|
@ -16,13 +16,16 @@ PKG_SUGGESTED_OPTIONS+= gcc-java
|
|||
###
|
||||
### Determine if multilib is avalible.
|
||||
###
|
||||
MULTILIB_SUPPORTED?= Yes
|
||||
.if !empty(MACHINE_PLATFORM:MLinux-*-x86_64) && \
|
||||
exists(/usr/include/gnu/stubs-64.h) && \
|
||||
!exists(/usr/include/gnu/stubs-32.h)
|
||||
MULTILIB_SUPPORTED?= unknowen
|
||||
.if !empty(MACHINE_PLATFORM:MLinux-*-x86_64)
|
||||
. if exists(/usr/include/gnu/stubs-64.h) && \
|
||||
!exists(/usr/include/gnu/stubs-32.h)
|
||||
MULTILIB_SUPPORTED=No
|
||||
. else
|
||||
MULTILIB_SUPPORTED=Yes
|
||||
. endif
|
||||
.endif
|
||||
.if empty(MULTILIB_SUPPORTED:M[Nn][Oo])
|
||||
.if !empty(MULTILIB_SUPPORTED:M[Yy][Ee][Ss])
|
||||
PKG_SUPPORTED_OPTIONS+= gcc-multilib
|
||||
PKG_SUGGESTED_OPTIONS+= gcc-multilib
|
||||
.endif
|
||||
|
@ -46,7 +49,9 @@ CONFIGURE_ARGS+= --disable-nls
|
|||
###
|
||||
### Multilib Support
|
||||
###
|
||||
.if empty(PKG_OPTIONS:Mgcc-multilib)
|
||||
.if (!empty(MULTILIB_SUPPORTED:M[Yy][Ee][Ss]) && \
|
||||
empty(PKG_OPTIONS:Mgcc-multilib) ) || \
|
||||
!empty(MULTILIB_SUPPORTED:M[Nn][Oo])
|
||||
CONFIGURE_ARGS+= --disable-multilib
|
||||
.endif
|
||||
|
||||
|
|
Loading…
Reference in a new issue