From 4ca8e5445697e76fd3c9cf01d761ff1fa5e43c00 Mon Sep 17 00:00:00 2001 From: hobbes1069 Date: Tue, 4 Aug 2015 19:00:03 +0000 Subject: [PATCH] Build configuration updates to support win32 build. git-svn-id: https://svn.code.sf.net/p/freetel/code@2254 01035d8c-6547-0410-b346-abe4f91aad63 --- fdmdv2-dev/CMakeLists.txt | 2 ++ fdmdv2-dev/cmake/BuildSox.cmake | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/fdmdv2-dev/CMakeLists.txt b/fdmdv2-dev/CMakeLists.txt index 49c664d1..8b17821f 100644 --- a/fdmdv2-dev/CMakeLists.txt +++ b/fdmdv2-dev/CMakeLists.txt @@ -126,6 +126,8 @@ else(BOOTSTRAP_WXWIDGETS AND NOT EXISTS ${WXCONFIG}) # if(MINGW) message(STATUS "System is MinGW.") + # Setup HOST variable. + include(cmake/MinGW.cmake) # This sets up the exe icon for windows under mingw. set(RES_FILES "") set(RES_FILES "${CMAKE_SOURCE_DIR}/contrib/freedv.rc") diff --git a/fdmdv2-dev/cmake/BuildSox.cmake b/fdmdv2-dev/cmake/BuildSox.cmake index adfd5a1d..d54488b3 100644 --- a/fdmdv2-dev/cmake/BuildSox.cmake +++ b/fdmdv2-dev/cmake/BuildSox.cmake @@ -3,6 +3,7 @@ set(SOX_TARBALL "sox-14.4.1") # required linking libraries on linux. Not sure about windows. find_library(ALSA_LIBRARIES asound) find_library(AO_LIBRARIES ao) +find_library(GSM_LIBRARIES gsm) if(UNIX AND NOT ALSA_LIBRARIES) message(ERROR "Could not find alsa library. @@ -21,7 +22,7 @@ On Linux systems try installing: endif(UNIX AND NOT AO_LIBRARIES) if(MINGW AND CMAKE_CROSSCOMPILING) - set(CONFIGURE_COMMAND ./configure --build=${HOST} --host=${HOST} --target=${HOST} --enable-shared=no --without-id3tag --without-png --disable-gomp --with-oggvorbis=no --with-oss=no --with-flac=no --with-amrnb=no --with-amrwb=no --with-mp3=no --with-wavpack=no --disable-dl-sndfile --with-pulseaudio=no --without-magic --with-gsm --prefix=${CMAKE_BINARY_DIR}/external/dist) + set(CONFIGURE_COMMAND ./configure --host=${HOST} --enable-shared=no --without-id3tag --without-png --disable-gomp --with-oggvorbis=no --with-oss=no --with-flac=no --with-amrnb=no --with-amrwb=no --with-mp3=no --with-wavpack=no --disable-dl-sndfile --with-pulseaudio=no --without-magic --with-gsm --prefix=${CMAKE_BINARY_DIR}/external/dist) else() set(CONFIGURE_COMMAND ./configure --enable-shared=no --without-id3tag --without-png --disable-gomp --with-oggvorbis=no --with-oss=no --with-flac=no --with-amrnb=no --with-amrwb=no --with-mp3=no --with-wavpack=no --disable-dl-sndfile --with-pulseaudio=no --without-magic --with-gsm --prefix=${CMAKE_BINARY_DIR}/external/dist) endif() @@ -37,7 +38,7 @@ ExternalProject_Add(sox ) set(SOX_LIBRARIES ${CMAKE_BINARY_DIR}/external/dist/lib/libsox.a) if(UNIX) - list(APPEND SOX_LIBRARIES ${ALSA_LIBRARIES} ${AO_LIBRARIES}) + list(APPEND SOX_LIBRARIES ${ALSA_LIBRARIES} ${AO_LIBRARIES} ${GSM_LIBRARIES}) endif() if(MINGW) list(APPEND SOX_LIBRARIES winmm) -- 2.25.1