<div dir="ltr"><div>Hello guys,<br></div><div><br></div>I found a problem when compiling openal to Mac OS X. I was searching for the examples and decided to compile openal from the source to get them. I got a problem to compile some examples that were using SDL2.<br><br><span style="font-family:monospace,monospace">/usr/bin/cc  -std=c99  -O2 -g -D_DEBUG -Wl,-search_paths_first -Wl,-headerpad_max_install_names   CMakeFiles/allatency.dir/examples/allatency.c.o  -o allatency  libex-common.a /opt/local/lib/libSDL_sound.dylib <b>/opt/local/lib/libSDL2main.a /opt/local/lib/libSDL2.dylib</b> -framework Cocoa libopenal.1.16.0.dylib libcommon.a -framework AudioToolbox -framework ApplicationServices -framework AudioUnit -framework CoreAudio -lpthread -ldl -lm -pthread<br>clang: warning: argument unused during compilation: '-pthread'<br>Undefined symbols for architecture x86_64:<br>  "_main", referenced from:<br>     implicit entry/start for main executable<br>     (maybe you meant: _SDL_main)<br>ld: symbol(s) not found for architecture x86_64<br>clang: error: linker command failed with exit code 1 (use -v to see invocation)</span><br clear="all"><div><div><div><div><div><br></div><div>I wrote a patch to fix this problem but now the build needs SDL and SDL2, maybe there is a better solution for this problem. All the outputs and the patch can be found bellow:<br><br><a href="http://adrianomelo.com/wp-content/uploads/2014/12/cmake.txt">http://adrianomelo.com/wp-content/uploads/2014/12/cmake.txt</a><br></div><div><a href="http://adrianomelo.com/wp-content/uploads/2014/12/make.txt">http://adrianomelo.com/wp-content/uploads/2014/12/make.txt</a><br><a href="http://adrianomelo.com/wp-content/uploads/2014/12/0001-Using-SDL2-only-where-it-s-needed.patch_.txt">http://adrianomelo.com/wp-content/uploads/2014/12/0001-Using-SDL2-only-where-it-s-needed.patch_.txt</a><br><br></div><div>Cheers,<br></div><div><div class="gmail_signature"><div dir="ltr">Adriano Melo<br><a href="http://adrianomelo.com" target="_blank">adrianomelo.com</a><br></div></div>
</div></div></div></div></div></div>