#21261 closed defect (invalid)
Can't unset -arch x86_64 in portfile in Snow Leopard
Reported by: | njbutko@… | Owned by: | macports-tickets@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 1.8.0 |
Keywords: | snowleopard | Cc: | |
Port: |
Description
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@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"
Change History (3)
comment:1 follow-up: 2 Changed 15 years ago by tobypeterson
Resolution: | → invalid |
---|---|
Status: | new → closed |
comment:2 Changed 14 years ago by aaron@…
Replying to toby@…:
configure.build_arch
Okay - so I have the same problem. I am trying to build code-blocks, but it fails because it wants to create x86_64, and the dependency wxWidgets is only i386. So I just want to modify the port, or simply tell macports -- to IGNORE x86_64. I don't even have a 64 bit computer!
So, where do I fiddle with configure.build_arch? Can you point me in the right direction?
comment:3 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Keywords: | snowleopard added; snow leopard build_arch arch x86_64 i386 removed |
---|
configure.build_arch