Tweaks for MinGW. Still a work in progress.
authorhobbes1069 <hobbes1069@01035d8c-6547-0410-b346-abe4f91aad63>
Thu, 26 Jan 2017 18:51:42 +0000 (18:51 +0000)
committerhobbes1069 <hobbes1069@01035d8c-6547-0410-b346-abe4f91aad63>
Thu, 26 Jan 2017 18:51:42 +0000 (18:51 +0000)
git-svn-id: https://svn.code.sf.net/p/freetel/code@2999 01035d8c-6547-0410-b346-abe4f91aad63

codec2-dev/CMakeLists.txt
codec2-dev/cmake/GetDependencies.cmake.in
freedv-dev/CMakeLists.txt
freedv-dev/cmake/GetDependencies.cmake.in

index dd39b4485d1595bdbaf3484e8728cae3cbb4c936..e43e79f482bf9e8946b9041b32ba8653eb7038ea 100644 (file)
@@ -69,7 +69,7 @@ endif()
 
 message(STATUS "Build type is: " ${CMAKE_BUILD_TYPE})
 string(TOUPPER ${CMAKE_BUILD_TYPE} _FLAGS)
-if(NOT "_FLAGS" STREQUAL "NONE")
+if(NOT _FLAGS STREQUAL "NONE")
     set(BUILD_FLAGS "${CMAKE_C_FLAGS_${_FLAGS}}")
 endif()
 message(STATUS "Compiler Flags: " ${BUILD_FLAGS})
@@ -186,7 +186,6 @@ if(WIN32)
     if(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
         set(CMAKE_CL_64 TRUE)
     endif()
-
     configure_file(cmake/GetDependencies.cmake.in cmake/GetDependencies.cmake
         @ONLY
     )
@@ -216,7 +215,8 @@ endif(WIN32)
 configure_file(
     ${CMAKE_CURRENT_SOURCE_DIR}/codec2.pc.in
     ${CMAKE_CURRENT_BINARY_DIR}/codec2.pc
-@ONLY)
+    @ONLY
+)
 
 install(
     FILES ${CMAKE_CURRENT_BINARY_DIR}/codec2.pc
index 067ad5e840a860e2d3996dbfb4d05cdb4946ca7b..0d25f670527981341ebaa845e4da0b5c01787561 100644 (file)
@@ -11,8 +11,8 @@ set(CMAKE_SYSTEM_LIBRARY_PATH @CMAKE_SYSTEM_LIBRARY_PATH@)
 set(CMAKE_FIND_ROOT_PATH @CMAKE_FIND_ROOT_PATH@)
 set(CODEC2_DLL ${CMAKE_BINARY_DIR}/src/libcodec2.dll)
 
-include(GetPrerequisites)
-get_prerequisites(${CODEC2_DLL} _deps 1 1 "" "")
+include(${CMAKE_SOURCE_DIR}/cmake/GetPrerequisites.cmake)
+get_prerequisites(${CODEC2_DLL} _deps 1 0 "" "")
 foreach(_runtime ${_deps})
     message("Looking for ${_runtime}")
     find_library(RUNTIME_${_runtime} ${_runtime})
index 4e26437ec8863d549213e8131a8ff9b6ff237111..5f575797a8c15c283ff3dc9c41bcff5cbfc5609c 100644 (file)
@@ -137,51 +137,6 @@ if(MINGW)
     enable_language(RC)
     set(CMAKE_RC_COMPILE_OBJECT
         "<CMAKE_RC_COMPILER> <FLAGS> -O coff <DEFINES> -i <SOURCE> -o <OBJECT>")
-    # These are DLOPEN'ed and can't be automatically pulled in by dependency.
-    foreach(RUNTIME
-        hamlib-adat.dll
-        hamlib-alinco.dll
-        hamlib-amsat.dll
-        hamlib-aor.dll
-        hamlib-ars.dll
-        hamlib-celestron.dll
-        hamlib-drake.dll
-        hamlib-dummy.dll
-        hamlib-easycomm.dll
-        hamlib-flexradio.dll
-        hamlib-fodtrack.dll
-        hamlib-gs232a.dll
-        hamlib-heathkit.dll
-        hamlib-icom.dll
-        hamlib-jrc.dll
-        hamlib-kachina.dll
-        hamlib-kenwood.dll
-        hamlib-kit.dll
-        hamlib-lowe.dll
-        hamlib-m2.dll
-        hamlib-pcr.dll
-        hamlib-prm80.dll
-        hamlib-racal.dll
-        hamlib-rft.dll
-        hamlib-rotorez.dll
-        hamlib-rs.dll
-        hamlib-sartek.dll
-        hamlib-skanti.dll
-        hamlib-spid.dll
-        hamlib-tapr.dll
-        hamlib-tentec.dll
-        hamlib-ts7400.dll
-        hamlib-tuner.dll
-        hamlib-uniden.dll
-        hamlib-winradio.dll
-        hamlib-wj.dll
-        hamlib-yaesu.dll)
-        message(STATUS "Checking for ${RUNTIME}")
-        find_library(${RUNTIME}_LIB ${RUNTIME}
-            PATH_SUFFIXES hamlib)
-        message(STATUS "runtime found: ${${RUNTIME}_LIB}")
-        list(APPEND CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS ${${RUNTIME}_LIB})
-    endforeach()
     include(InstallRequiredSystemLibraries)
 endif(MINGW)
 
@@ -423,7 +378,7 @@ endif(wxWidgets_FOUND)
 #
 if(NOT USE_STATIC_SPEEXDSP)
     message(STATUS "Looking for Speex DSP library.")
-    find_path(SPEEXDSP_INCLUDE_DIR speex/speex.h)
+    find_path(SPEEXDSP_INCLUDE_DIR NAMES speex/speex.h speex/speexdsp_types.h)
     find_library(SPEEXDSP_LIBRARY speexdsp)
     message(STATUS "  Speex DSP headers: ${SPEEXDSP_INCLUDE_DIR}")
     message(STATUS "  Speex DSP library: ${SPEEXDSP_LIBRARY}")
index 93204dd723640908aba573ff9301216ecaf0bf24..a0767601a9f2955d3ea7420ec91a1cdb36b02814 100644 (file)
@@ -13,7 +13,7 @@ set(CMAKE_FIND_ROOT_PATH @CMAKE_FIND_ROOT_PATH@)
 set(FREEDV_EXE ${CMAKE_BINARY_DIR}/src/freedv.exe)
 
 include(GetPrerequisites)
-get_prerequisites("${FREEDV_EXE}" _deps 1 1 "" "${CMAKE_SYSTEM_LIBRARY_PATH}")
+get_prerequisites("${FREEDV_EXE}" _deps 1 0 "" "")
 foreach(_runtime ${_deps})
     message("Looking for ${_runtime}")
     find_library(RUNTIME_${_runtime} ${_runtime})