[MacPorts] #21261: Can't unset -arch x86_64 in portfile in Snow Leopard
MacPorts
noreply at macports.org
Wed Sep 9 17:49:49 PDT 2009
#21261: Can't unset -arch x86_64 in portfile in Snow Leopard
----------------------------------------------------------+-----------------
Reporter: njbutko@… | Owner: macports-tickets@…
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 1.8.0
Keywords: snow leopard, build_arch, arch, x86_64, i386 | Port:
----------------------------------------------------------+-----------------
I'm trying to create a -arch i386 variant of a port, but as far as I can
tell from the Guide and all my valiant attempts, there's no way to delete
-arch x86_64 from the make flags.
My variant looks something like
{{{
variant SL_32bit description {Build in 32-bit mode on Snow Leopard.} {
configure.args-delete "-arch x86_64"
configure.cxxflags-append "-arch i386"
}
}}}
which leads to the following output:
{{{
/usr/bin/g++-4.2 -DHAVE_CONFIG_H -I. -I. -I../.. -I.
-I../../cxcore/include -I../.. -DNDEBUG -I/opt/local/include -Wall -fno-
rtti -pipe -O3 -g -march=prescott -ffast-math -fomit-frame-pointer -O2
-I/opt/local/include -L/opt/local/lib -arch i386 -arch x86_64 -MT
cxalloc.lo -MD -MP -MF .deps/cxalloc.Tpo -c cxalloc.cpp -fno-common -DPIC
-o .libs/cxalloc.o
g++-4.2: -E, -S, -save-temps and -M options are not allowed with multiple
-arch flags
}}}
where the bug is "-arch i386 -arch x86_64". I have tried deleting from
every known configure and build flag in the guide, and none of them works.
That the "-arch x86_64" is there at all seems amiss. I do not have
build_arch set in macports.conf, and g++ builds in 64-bit mode by default
in Snow Leopard, so at best it is redundant. I don't want to set
"build_arch" in macports.conf because it is not needed for all ports, and
breaks many of them. I simply want to turn it on in this variant in this
portfile. In searching the documentation and other tickets, I can't find a
good answer for how to do so.
The portfile in question never touches build_arch or sets -arch (except
for my variant):
{{{
# $Id: Portfile 50984 2009-05-14 21:08:43Z and.damore at macports.org $
PortSystem 1.0
name opencv
version 1.0.0
categories graphics science
platforms darwin
maintainers gmail.com:stante
description Intel(R) Open Source Computer Vision
Library
long_description opencv is a library that is mainly aimed at real
time \
computer vision. Some example
areas would be \
Human-Computer Interaction (HCI),
Object Identification, \
Segmentation and Recognition, Face
Recognition, Gesture \
Recognition, Motion Tracking, Ego
Motion, Motion \
Understanding, Structure From
Motion (SFM), and Mobile \
Robotics.
homepage
http://www.intel.com/technology/computing/opencv/
master_sites sourceforge:opencvlibrary
checksums md5 146a05005f2d2c16c4ee10ebd7f1dd58
depends_lib port:gtk2 port:zlib port:jpeg \
port:libpng port:tiff
configure.env CPATH="${prefix}/include" \
LIBRARY_PATH="${prefix}/lib"
configure.cxxflags-append "-I${prefix}/include -L${prefix}/lib"
}}}
--
Ticket URL: <http://trac.macports.org/ticket/21261>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list