Can't compile on Linux


#1

Tried to compile using the default Makefile provided in the extras/the jucer/build/linux directory and received the following output:

==== Building Jucer ====
jucer_Main.cpp
juce_LibrarySource.cpp
In file included from ../../src/juce_LibrarySource.cpp:14:
../../src/../../../juce_amalgamated.cpp:254382:27: warning: extra tokens at end of #ifdef directive
In file included from ../../src/juce_LibrarySource.cpp:14:
../../src/../../../juce_amalgamated.cpp:254386: error: variable or field ‘getDeviceSampleRates’ declared void
../../src/../../../juce_amalgamated.cpp:254386: error: ‘snd_pcm_t’ was not declared in this scope
../../src/../../../juce_amalgamated.cpp:254386: error: ‘handle’ was not declared in this scope
../../src/../../../juce_amalgamated.cpp:254386: error: expected primary-expression before ‘&’ token
../../src/../../../juce_amalgamated.cpp:254386: error: ‘rates’ was not declared in this scope
../../src/../../../juce_amalgamated.cpp:255965: error: expected `}' at end of input
make[1]: *** [build/intermediate/Debug/juce_LibrarySource.o] Error 1
make: *** [Jucer] Error 2

Any idea what I’m doing wrong? I already had the juce libs built but hadn’t done anything afterwards.


#2

I should add that I built the juce demo without problems (and with working audio).


#3

Did you run the premake script? The default makefile might not be quite right for your setup, so you’d need to use premake to update it.


#4

Cleaned all the intermediate files with make clean and premake --clean and then ran the runpremake script that’s inside the the jucer/build/linux directory but still no luck. Seems like an ALSA lib issue of some sort.


#5

It just looks like you’ve not included alsa correctly, or are somehow including a version that’s too old or new… Try getting the latest alsa library and trying again.