Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

#18132 closed defect (fixed)

mesa 7.2: build fails on install

Reported by: dbevans (David B. Evans) Owned by: jeremyhu (Jeremy Huddleston Sequoia)
Priority: Normal Milestone:
Component: ports Version: 1.8.0
Keywords: Cc: andrea.damore@…, pgijnxn02@…, jakecdouglas@…, christoph@…
Port: mesa

Description

Mac OS 10.4.11 PPC, XCode 2.5, MacPorts 1.8.0 (trunk)

After updating mesa port to svn r45750 build fails on install as follows

$ sudo port install mesa
...
gcc -c -I. -I../../../include -I../../../include/GL/internal -I../../../src/mesa/main -I../../../src/mesa/glapi   -ggdb3 -Os -Wall -Wmissing-prototypes -std=c99 -ffast-math -fno-strict-aliasing -I/opt/local/include -I/usr/X11R6/include  -fPIC   -D_DARWIN_C_SOURCE -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_BSD_SOURCE -D_SVID_SOURCE -D_GNU_SOURCE -DPTHREADS -DGLX_ALIAS_UNSUPPORTED -DGLX_INDIRECT_RENDERING -DXF86VIDMODE -D_REENTRANT -UIN_DRI_DRIVER -DDEFAULT_DRIVER_DIR=\"/opt/local/lib/dri\" ../../../src/mesa/glapi/glthread.c -o ../../../src/mesa/glapi/glthread.o
/bin/sh ../../../bin/mklib -o GL -linker 'gcc' -ldflags '' \
        -major 1 -minor 2  \
        -install ../../../lib -id /opt/local/lib/libGL.1.dylib \
        -L/opt/local/lib -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread glcontextmodes.o clientattrib.o compsize.o eval.o glxcmds.o glxcurrent.o glxext.o glxextensions.o indirect.o indirect_init.o indirect_size.o indirect_window_pos.o indirect_texture_compression.o indirect_transpose_matrix.o indirect_vertex_array.o indirect_vertex_program.o pixel.o pixelstore.o render2.o renderpix.o single2.o singlepix.o vertarr.o xfont.o glx_pbuffer.o glx_query.o drisw_glx.o dri_common.o dri_glx.o XF86dri.o glxhash.o ../../../src/mesa/main/dispatch.o ../../../src/mesa/glapi/glapi.o ../../../src/mesa/glapi/glthread.o
mklib: Making Darwin shared library:  libGL.1.2.dylib
ld: common symbols not allowed with MH_DYLIB output format with the -multi_module option
../../../src/mesa/glapi/glapi.o definition of common __gl_DispatchTSD (size 8)
/usr/libexec/gcc/powerpc-apple-darwin8/4.0.1/libtool: internal link edit command failed
mklib: Installing libGL.1.2.dylib libGL.1.dylib libGL.dylib in ../../../lib
mv: rename libGL.1.2.dylib to ../../../lib/libGL.1.2.dylib: No such file or directory
make[2]: *** [../../../lib/libGL.dylib] Error 1
make[1]: *** [subdirs] Error 1
make: *** [default] Error 1

Full debug log file attached

Attachments (3)

build.log (55.0 KB) - added by dbevans (David B. Evans) 16 years ago.
mesa build log
mesa-7.2-Os.patch (784 bytes) - added by blb@… 16 years ago.
new mesa-7.2-Os.patch
mesa-7.2-x11dir.patch (2.1 KB) - added by blb@… 16 years ago.
updated mesa-7.2-x11dir.patch

Download all attachments as: .zip

Change History (29)

Changed 16 years ago by dbevans (David B. Evans)

Attachment: build.log added

mesa build log

comment:1 Changed 16 years ago by pgijnxn02@…

Cc: pgijnxn02@… added

Cc Me!

comment:2 Changed 16 years ago by dbevans (David B. Evans)

Problem remains unchanged after Portfile changes in r45779.

comment:3 Changed 16 years ago by jakecdouglas@…

Cc: jakecdouglas@… added

Cc Me!

comment:4 Changed 16 years ago by dbevans (David B. Evans)

Ping. Any idea what the problem is here? Without this there is no working libGL (at least on Tiger) under the new xorg-* system. The system libGL worked originally but is incompatible with the xorg libs and +system_x11 fails to yield a working option (problem with cairo I think) either.

Help!

comment:5 Changed 16 years ago by blb@…

Can you try the attached replacement of mesa-7.2-Os.patch (putting in files/ of course), and try building anew?

Changed 16 years ago by blb@…

Attachment: mesa-7.2-Os.patch added

new mesa-7.2-Os.patch

comment:6 Changed 16 years ago by dbevans (David B. Evans)

that patches OK but then mesa-7.2-x11dir.patch fails. (Subsequent patch on configs/darwin doesn't see what it expects.)

comment:7 Changed 16 years ago by blb@…

Oops, that's what I get for not trying a 'port patch'; attaching an updated mesa-7.2-x11dir.patch as well.

Changed 16 years ago by blb@…

Attachment: mesa-7.2-x11dir.patch added

updated mesa-7.2-x11dir.patch

comment:8 Changed 16 years ago by dbevans (David B. Evans)

Yes, that fixes it (for me). Builds correctly with the two updated patch files.

comment:9 Changed 16 years ago by dbevans (David B. Evans)

And thanks, that's a real life saver.

comment:10 Changed 16 years ago by dbevans (David B. Evans)

Any reason these new files should not be committed?

comment:11 Changed 16 years ago by jeremyhu (Jeremy Huddleston Sequoia)

blb: Go ahead and push 'em...

comment:12 Changed 16 years ago by blb@…

Resolution: fixed
Status: newclosed

Patches updated in r46218.

comment:13 Changed 16 years ago by christoph@…

I think I am running into the same problem and I am assuming this patch has not made it into a release yet.

How would I go about applying the patch. It seems to be in an XML format. Also where do I apply it?

Thanks!

comment:14 Changed 16 years ago by christoph@…

Cc: christoph@… added

Cc Me!

comment:15 in reply to:  13 ; Changed 16 years ago by blb@…

Replying to christoph@…:

I think I am running into the same problem and I am assuming this patch has not made it into a release yet.

It's been in the mesa port for a month now, make sure you've done a sudo port selfupdate first.

comment:16 in reply to:  15 Changed 16 years ago by christoph@…

It's been in the mesa port for a month now, make sure you've done a sudo port selfupdate first.

I did run a selfupdate.

Here is my error log:

---> Building mesa DEBUG: Executing proc-pre-org.macports.build-build-0 DEBUG: Executing org.macports.build (mesa) DEBUG: port allows a parallel build DEBUG: Environment: MACOSX_DEPLOYMENT_TARGET='10.4' DEBUG: Assembled command: 'cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_x11_mesa/work/Mesa-7.2" && make default INSTALL_DIR=/opt/local' Making sources for darwin make[2]: Nothing to be done for `default'. (cd drivers && make) /bin/sh ../../../../bin/mklib -o OSMesa -linker 'gcc' -ldflags \

-major 7 -minor 2 -patch 0 \ -install ../../../../lib \ -id /opt/local/lib/libOSMesa.7.dylib \ -L../../../../lib -lGL osmesa.o ../../../../src/mesa/libmesa.a ../../../../src/mesa/libglapi.a

mklib: Making Darwin shared library: libOSMesa.7.2.dylib mklib: Installing libOSMesa.7.2.dylib libOSMesa.7.dylib libOSMesa.dylib in ../../../../lib make[4]: `../../../lib/libGLU.dylib' is up to date. make[2]: Nothing to be done for `default'. Making programs for darwin DEBUG: Executing proc-post-org.macports.build-build-0 tclsh8.5 gen_code.tcl make: tclsh8.5: Command not found make: * [apple_xgl_api.h] Error 127 Error: Target org.macports.build returned: shell command "cd /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_x11_mesa/work/Mesa-7.2/../AppleSGLX-53 && make builds/libGL.1.2.dylib INSTALL_DIR=/opt/local LDFLAGS='-L/opt/local/lib' CFLAGS='-I/opt/local/include -O2' INSTALL_DIR='/opt/local'" returned error 2 Command output: tclsh8.5 gen_code.tcl make: tclsh8.5: Command not found make: * [apple_xgl_api.h] Error 127

Warning: the following items did not execute (for mesa): org.macports.activate org.macports.build org.macports.destroot org.macports.install Error: Status 1 encountered during processing.

comment:17 Changed 16 years ago by jeremyhu (Jeremy Huddleston Sequoia)

Did you do a 'sudo port upgrade outdated' ? You're missing tclsh8.5 which is in the tcl port. I'm guessing you have tcl 8.4 installed...

comment:18 Changed 16 years ago by christoph@…

That was the missing step. It is compiled now. Thanks! Where is this documented so I can find it in future?

Now I get the following when trying to run kcachegrind (X11 App started):

macbook$ kcachegrind _X11TransSocketUNIXConnect: Cannot connect to non-local host ? XIO: fatal IO error 22 (Unknown error: 0) on X server ":0.0"

after 86 requests (85 known processed) with 0 events remaining.

Any ideas?

comment:19 Changed 16 years ago by jeremyhu (Jeremy Huddleston Sequoia)

You may have some rogue libs linking against your system X11 instead of the macports one (possibly because you didn't do the sudo port -v upgrade outdated). Run this to find them:

cd /opt/local/lib
for f in *dylib; do otool -L $f | grep -q /usr/X11 && echo $f; done

cd /opt/local/bin
for f in *; do otool -L $f | grep -q /usr/X11 && echo $f; done

Then 'sudo port -v -f uninstall' the ports that made those files, then reinstall the ports.

comment:20 Changed 16 years ago by christoph@…

The first command yields 118 libs, the second 47. How do I know if a lib is rogue?

One says: otool: can't open file: python-config2.5 (No such file or directory)

comment:21 in reply to:  20 Changed 16 years ago by anddam@…

Replying to christoph@…:

The first command yields 118 libs, the second 47. How do I know if a lib is rogue?

If it has been outputted it should be rogue i.e. linking against /usr/X11/* rather than libraries in ports.

One says: otool: can't open file: python-config2.5 (No such file or directory)

It's probably a script rather than an object file, still it shouldn't say "no such file". Mine is called python2.5-config rather than python-config2.5, try a

ls -l /opt/local/bin/python-config*

comment:22 Changed 16 years ago by jeremyhu (Jeremy Huddleston Sequoia)

you can figure out which ports they are by modifying my suggestion slightly:

sudo port -v -f uninstall inactive

cd /opt/local/var/macports/software
for f in */*/opt/local/{lib/*dylib,bin/*}; do otool -L $f | grep -q /usr/X11 && echo $f; done | cut -f1 -d/ | uniq

comment:23 Changed 16 years ago by christoph@…

I don't seem to be able to fix the linking issues.

Thanks for all the help. I am going to try this again on a fresh install of Leopard when I upgrade in a couple of weeks.

comment:24 Changed 16 years ago by jeremyhu (Jeremy Huddleston Sequoia)

chris: Just do a 'sudo port -v -f uninstall <list of the ports that have bad linking>' then 'sudo port -v install <list of those ports to reinstall>'. If after this process, they STILL have bad linking, then please report those ports as buggy, and I'll look into fixing them.

comment:25 Changed 16 years ago by christoph@…

jeremy: I am pretty sure I had everything uninstalled.

I'll try again when I have some time towards the end of the month. Maybe I can catch you on IRC while I do it to make sure I am doing everything right.

Thanks again for your help and genuine interest in getting this working for me.

comment:26 Changed 16 years ago by (none)

Milestone: Port Bugs

Milestone Port Bugs deleted

Note: See TracTickets for help on using tickets.