Lazarus + OSX 10.6 + SDL [SOLVED] lazarus / 33-macOS - Mac OS X ---------------------------------------------------------------------- leniad2 · 2013-04-07 23:06 Hi everyone! I'm trying to compile DSP Emulator with Lazarus and OSX 10.6 32bits (works fine with Windows and Linux) but I allways get this error: Undefined symbols for architecture i386:   "_Mix_OpenAudio", referenced from:       _SOUND_ENGINE_INICIAR_AUDIO$BOOLEAN$$BOOLEAN in sound_engine.o   "_Mix_AllocateChannels", referenced from:       _SOUND_ENGINE_INICIAR_AUDIO$BOOLEAN$$BOOLEAN in sound_engine.o   "_Mix_CloseAudio", referenced from:       _SOUND_ENGINE_CLOSE_AUDIO in sound_engine.o   "_Mix_LoadWAV_RW", referenced from:       _SDL_MIXER_NOSMPEG_MIX_LOADWAV$PCHAR$$PMIX_CHUNK in sdl_mixer_nosmpeg.o   "_Mix_PlayChannelTimed", referenced from:       _SDL_MIXER_NOSMPEG_MIX_PLAYCHANNEL$LONGINT$PMIX_CHUNK$LONGINT$$LONGINT in sdl_mixer_nosmpeg.o   "_Mix_FadeInChannelTimed", referenced from:       _SDL_MIXER_NOSMPEG_MIX_FADEINCHANNEL$LONGINT$PMIX_CHUNK$LONGINT$ LONGINT$$LONGINT in sdl_mixer_nosmpeg.o ld: symbol(s) not found for architecture i386 An error occurred while linking dsp.lpr(34,40) Error: Error while linking dsp.lpr(34,40) Fatal: There were 1 errors compiling module, stopping Any idea? Thanks in advance ---------------------------------------------------------------------- Jonas Maebe · 2013-04-08 12:29 It looks like you are not linking against the SDL mixer library (I don't know its name by heart, probably SDL_mixer or so). ---------------------------------------------------------------------- leniad2 · 2013-04-08 17:12 Thanks for your reply, It's my first time using OSX... Let me explain what I do... I download SDL source and SDL mixer source, compiled and installed ('configure & make & make install') both. In directory 'usr/local/lib' there are 'libSDL-1.2.0.dylib' and 'libSDL_mixer-1.2.0.dylib' (and many others). Then, in Lazarus proyect, I've added those paths in compiler path '/usr/local/lib;/usr/X11/lib' in proyect options. After reading your post I make a test, I uninstall SDL mixer library ('make uninstall') and surprise! without this library installed I've got the same errors. So, I think you are right! How can I link this library in Lazarus proyect? It's not enought give to Lazarus the path? Thanks in advance again... ---------------------------------------------------------------------- Jonas Maebe · 2013-04-08 19:30 Add {$linklib SDL_mixer} to your program source code. The SDL unit probably only links to the main SDL library. ---------------------------------------------------------------------- leniad2 · 2013-04-08 21:43 Yes! It works! Thank you very much!!!!! Now I can compile my source.