#21424 closed defect (fixed)
mesa: can't build i386 on Snow Leopard
Reported by: | ryandesign (Ryan Carsten Schmidt) | Owned by: | jeremyhu (Jeremy Huddleston Sequoia) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 1.8.0 |
Keywords: | Cc: | srm@…, nerdling (Jeremy Lavergne) | |
Port: | mesa |
Description
When setting build_arch to i386 on a Snow Leopard machine, mesa still tries to build x86_64, which then fails when it can't link with the 32-bit libX11 and libXext that are installed.
ld: warning: in /32mp/lib/libX11.dylib, file is not of required architecture ld: warning: in /32mp/lib/libXext.dylib, file is not of required architecture
$ lipo -info /32mp/lib/{libX11,libXext}.dylib Non-fat file: /32mp/lib/libX11.dylib is architecture: i386 Non-fat file: /32mp/lib/libXext.dylib is architecture: i386
Attachments (1)
Change History (13)
Changed 15 years ago by ryandesign (Ryan Carsten Schmidt)
comment:1 follow-up: 3 Changed 15 years ago by srm@…
comment:3 Changed 15 years ago by srm@…
snip
I've added the following lines to the Portfile's post_patch section
snap
Given that these lines are quite specific to my system (at least to this apple system, see the paths) it is at least a hint for other stressed fellows.
comment:4 Changed 15 years ago by srm@…
another line has probably to be changed:
#This is used for building the tests. #The tests don't require installation. $(TEST_BUILD_DIR)/libGL.dylib: $(OBJECTS) -if ! test -d $(TEST_BUILD_DIR); then $(MKDIR) $(TEST_BUILD_DIR); fi $(CC) -O0 -ggdb3 -o $@ -dynamiclib -lXplugin -framework ApplicationServices -framework CoreFoundation -L$(X11_DIR)/lib -lX11 -lXext -W$
add -arch i386
behind $(CC)
comment:5 Changed 15 years ago by srm@…
sorry for the mess I'm producing in this worklog, just wanted to mention that it's file
${worksrcpath}/../AppleSGLX-57/Makefile
for the snippet above
*out*
comment:6 Changed 15 years ago by nerdling (Jeremy Lavergne)
Cc: | snc@… added |
---|
I feel we can always do these changes by simply inserting configure.build_arch
if we're doing a non-universal build.
This built for me (on an x86_64) with build_arch set to i386 after completing the aforementioned patches.
comment:7 Changed 15 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Resolution: | → worksforme |
---|---|
Status: | new → closed |
comment:8 Changed 15 years ago by jeremyhu (Jeremy Huddleston Sequoia)
It builds fine for me on a 32bit SL
comment:9 Changed 15 years ago by nerdling (Jeremy Lavergne)
Did you build as i386 on an x86_64 arch?
comment:10 Changed 15 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Resolution: | worksforme |
---|---|
Status: | closed → reopened |
Ah, sorry for the confusion. It works +universal for me, but I'll try your configuration in a bit...
comment:11 Changed 15 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | reopened → closed |
Fixed in r61548.
comment:12 Changed 15 years ago by jeremyhu (Jeremy Huddleston Sequoia)
Thanks Ryan! I've been swamped.
I had the same problem here on Snow Leopard. Set build_arch to i386 in macports.conf and it didn't work. I've added the following lines to the Portfile's post_patch section
It works now. Probably due to "use_config no" there's no hope using normal configure._.append and the different build's didn't use the correct C/XXFlags