I can't compile on OSX (i installed macports, brew, the libs and compilers etc, the object code compiles, won't link)

Installed Mac Ports on OSX High Sierra

sudo port install gcc11 libsdl2 openssl glfw libsdl2_gfx libsdl2_image libsdl2_mixer libsdl2_net libsdl2_ttf

and added the libs to the compile options: and that made the object code finally compile and not error out:

CPUOPTIMIZATIONS?=-fcommon -fno-math-errno -ffinite-math-only -fno-rounding-math -fno-signaling-nans -fno-trapping-math -D_THREAD_SAFE -I/opt/local/include/SDL2 -L/opt/local/lib -lSDL2

But it won’t produce a binary:

Build more but didn’t link:

“_volume”, referenced from:
_M_Draw in menu.o
_M_Menu_Options_AdjustSliders in menu.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [darkplaces-sdl] Error 1
make[1]: *** [bin-debug] Error 2
make: *** [sdl-debug] Error 2

Errors:

apples-Mac-mini:buildforapple r00t$ ./all compileengineonly sdlCompiling - Pastebin.com

Won’t link and won’t thusly create the binary.

This is the makefile.inc:

apples-Mac-mini:buildforapple r00t$ apples-Mac-mini:buildforapple r00t$ appl - Pastebin.com

this is the makefile (no extension)

apples-Mac-mini:buildforapple r00t$ apples-Mac-mini:buildforapple r00t$ appl - Pastebin.com

Can someone help? (Please don’t suggest upgrading the OS, nor buying a new mac)

1 Like

Corresponding tweet for this thread:

Share link for this tweet.

1 Like