diff --git a/CMakeLists.txt b/CMakeLists.txt index 74762470ce..c73f950a7c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -24,11 +24,14 @@ set (ORCT2_RESOURCE_DIR ${CMAKE_INSTALL_PREFIX}/share/${PROJECT}/) project(${PROJECT}) add_definitions(-DORCT2_RESOURCE_DIR="${ORCT2_RESOURCE_DIR}") +add_definitions(-DHAVE_CONFIG_H) # include lodepng header include_directories("lodepng/") +# include speex header +include_directories("libspeex/") # add source files -file(GLOB_RECURSE ORCT2_SOURCES "src/*.c" "lodepng/*.c") +file(GLOB_RECURSE ORCT2_SOURCES "src/*.c" "src/*.cpp" "libspeex/*.c" "lodepng/*.c") if (UNIX) # force 32bit build for now and set necessary flags to compile code as is diff --git a/src/config.h b/src/config.h index 43c9b25585..1c200ec09c 100644 --- a/src/config.h +++ b/src/config.h @@ -133,7 +133,7 @@ typedef struct general_configuration { uint16 language; } general_configuration_t; -static const struct { char *key; int value; } _currencyLookupTable[] = { +static const struct { const char *key; int value; } _currencyLookupTable[] = { { "GBP", CURRENCY_POUNDS }, { "USD", CURRENCY_DOLLARS }, { "FRF", CURRENCY_FRANC }, diff --git a/src/mixer.cpp b/src/mixer.cpp index a7959e34cf..f7541c12ad 100644 --- a/src/mixer.cpp +++ b/src/mixer.cpp @@ -362,7 +362,7 @@ void Mixer::MixChannel(Channel& channel, Uint8* data, int length) } channel.offset = 0; } - } while(loaded < length || (loaded < length && channel.loop != 0 && channel.offset == 0)); + } while(loaded < length && channel.loop != 0); } }