Opened 11 years ago

Closed 8 years ago

#42331 closed defect (worksforme)

crack-attack won't build/install on OS X Mavericks

Reported by: hugo-ribeiro (Hugo Ribeiro) Owned by: raimue (Rainer Müller)
Priority: Normal Milestone:
Component: ports Version: 2.2.1
Keywords: Cc: jeremyhu (Jeremy Huddleston Sequoia)
Port: crack-attack mesa

Description

Not sure what's wrong here. I've attached the config.log and main.log. Here's the relevant error:

:info:build mv -f .deps/obj_block.Tpo .deps/obj_block.Po
:info:build make[3]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_games_crack-attack/crack-attack/work/crack-attack-1.1.14/src'
:info:build make[2]: *** [all-recursive] Error 1
:info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_games_crack-attack/crack-attack/work/crack-attack-1.1.14/src'
:info:build make[1]: *** [all] Error 2
:info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_games_crack-attack/crack-attack/work/crack-attack-1.1.14/src'
:info:build make: *** [all-recursive] Error 1
:info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_games_crack-attack/crack-attack/work/crack-attack-1.1.14'
:info:build Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_games_crack-attack/crack-attack/work/crack-attack-1.1.14" && /usr/bin/make -j8 -w all
:info:build Exit code: 2
:error:build org.macports.build for port crack-attack returned: command execution failed
:debug:build Error code: CHILDSTATUS 8909 2
:debug:build Backtrace: command execution failed
    while executing
"system -nice 0 $fullcmdstring"
    ("eval" body line 1)
    invoked from within
"eval system $notty $nice \$fullcmdstring"
    invoked from within
"command_exec build"
    (procedure "portbuild::build_main" line 8)
    invoked from within
"$procedure $targetname"

Attachments (3)

main.log (201.8 KB) - added by hugo-ribeiro (Hugo Ribeiro) 11 years ago.
config.log (42.8 KB) - added by hugo-ribeiro (Hugo Ribeiro) 11 years ago.
mesa-darwin13.diff (1.5 KB) - added by raimue (Rainer Müller) 11 years ago.
Proposed patch, leads to build errors

Download all attachments as: .zip

Change History (7)

Changed 11 years ago by hugo-ribeiro (Hugo Ribeiro)

Attachment: main.log added

Changed 11 years ago by hugo-ribeiro (Hugo Ribeiro)

Attachment: config.log added

comment:1 Changed 11 years ago by raimue (Rainer Müller)

Cc: jeremyhu@… added; raimue@… removed
Owner: changed from macports-tickets@… to raimue@…
Port: mesa added
Status: newassigned

Thank you for this bug report. Indeed I had not tried yet to build crack-attack on Mavericks.

The problem is a type declared differently in mesa than in the OpenGL framework header:

In file included from DrawGarbage.cxx:32:
/opt/local/include/GL/glext.h:5340:22: error: typedef redefinition with different types ('unsigned int' vs 'void *')
typedef unsigned int GLhandleARB;
                     ^
/System/Library/Frameworks/OpenGL.framework/Headers/gltypes.h:65:15: note: previous definition is here
typedef void *GLhandleARB;
              ^

Newer versions of GL/glext.h use the following declaration instead, in mesa upstream available as of version 9.2:

#ifdef __APPLE__
typedef void *GLhandleARB;
#else
typedef unsigned int GLhandleARB;
#endif

With the change applied locally in GL/glext.h, crack-attack builds and works fine for me on Mavericks.

Jeremy, could we just backport this type declaration only for Mavericks, while other reasons are holding back a newer mesa (see #41349)?

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

Status: assignednew

Please go ahead and commit this change to the mesa port. A newer mesa is likely vaporware at this point.

comment:3 Changed 11 years ago by raimue (Rainer Müller)

I tried to apply a patch to the mesa port, but apparently this type is actually used internally and is expected to be unsigned int.

make[3]: Entering directory `/opt/local/var/macports/build/_Users_raimue_src_macports_trunk_dports_x11_mesa/mesa/work/Mesa-8.0.4/src/mapi/glapi'
/usr/bin/clang  -c -I../../../include -I../../../src/mapi -I../../../src/mesa -DMAPI_MODE_UTIL -std=c99 -fvisibility=hidden -g3 -gdwarf-2 -Os -ffast-math -fno-strict-aliasing -Wall -Wmissing-prototypes -I/opt/local/include -I/opt/local/include -fPIC -arch x86_64  -D_DARWIN_C_SOURCE -DPTHREADS -D_GNU_SOURCE -DGLX_ALIAS_UNSUPPORTED -DGLX_DIRECT_RENDERING -DGLX_USE_APPLEGL  glapi_dispatch.c -o glapi_dispatch.o
In file included from glapi_dispatch.c:90:
../../../src/mapi/glapi/glapitemp.h:4189:32: warning: incompatible integer to pointer conversion passing 'GLuint' (aka 'unsigned int') to parameter of type 'GLhandleARB' (aka 'void *') [-Wint-conversion]
   DISPATCH(CompileShaderARB, (shader), (F, "glCompileShader(%d);\n", shader));
                               ^~~~~~
glapi_dispatch.c:74:25: note: expanded from macro 'DISPATCH'
   GET_DISPATCH()->FUNC ARGS
                        ^
In file included from glapi_dispatch.c:90:
../../../src/mapi/glapi/glapitemp.h:4224:35: warning: incompatible integer to pointer conversion passing 'GLuint' (aka 'unsigned int') to parameter of type 'GLhandleARB' (aka 'void *') [-Wint-conversion]
   DISPATCH(GetActiveUniformARB, (program, index, bufSize, length, size, type, name), (F, "glGetActiveUniform(%d, %d, %d, %p, %p, %p, %p);\n", program, index, bufSize, (const void *) length, (const void *) size, (const void *) type, (const void *) name));
                                  ^~~~~~~
glapi_dispatch.c:74:25: note: expanded from macro 'DISPATCH'
   GET_DISPATCH()->FUNC ARGS
                        ^
In file included from glapi_dispatch.c:90:
../../../src/mapi/glapi/glapitemp.h:4266:34: warning: incompatible integer to pointer conversion passing 'GLuint' (aka 'unsigned int') to parameter of type 'GLhandleARB' (aka 'void *') [-Wint-conversion]
   DISPATCH(GetShaderSourceARB, (shader, bufSize, length, source), (F, "glGetShaderSource(%d, %d, %p, %p);\n", shader, bufSize, (const void *) length, (const void *) source));
                                 ^~~~~~
glapi_dispatch.c:74:25: note: expanded from macro 'DISPATCH'
   GET_DISPATCH()->FUNC ARGS
                        ^
...

Might need some more patching in other places to be compatible with OpenGL.framework again, but I don't have time for a deeper look right now.

Changed 11 years ago by raimue (Rainer Müller)

Attachment: mesa-darwin13.diff added

Proposed patch, leads to build errors

comment:4 Changed 8 years ago by raimue (Rainer Müller)

Resolution: worksforme
Status: newclosed

This seems to be long resolved by a newer mesa.

Note: See TracTickets for help on using tickets.