2014-10-27 20:05:40 -04:00
|
|
|
cmake_minimum_required (VERSION 2.8)
|
|
|
|
|
2015-02-22 23:02:39 -05:00
|
|
|
SET(CUBICSDR_VERSION_MAJOR "0")
|
|
|
|
SET(CUBICSDR_VERSION_MINOR "1")
|
2015-06-05 23:29:42 -04:00
|
|
|
SET(CUBICSDR_VERSION_PATCH "3")
|
2015-02-22 23:02:39 -05:00
|
|
|
SET(CUBICSDR_VERSION_REL "beta")
|
|
|
|
SET(CUBICSDR_VERSION "${CUBICSDR_VERSION_MAJOR}.${CUBICSDR_VERSION_MINOR}.${CUBICSDR_VERSION_PATCH}-${CUBICSDR_VERSION_REL}")
|
|
|
|
|
2015-03-04 22:58:50 -05:00
|
|
|
SET(CPACK_PACKAGE_VERSION "${CUBICSDR_VERSION_MAJOR}.${CUBICSDR_VERSION_MINOR}.${CUBICSDR_VERSION_PATCH}")
|
2015-02-22 23:02:39 -05:00
|
|
|
SET(CPACK_PACKAGE_VERSION_MAJOR ${CUBICSDR_VERSION_MAJOR})
|
|
|
|
SET(CPACK_PACKAGE_VERSION_MINOR ${CUBICSDR_VERSION_MINOR})
|
|
|
|
SET(CPACK_PACKAGE_VERSION_PATCH ${CUBICSDR_VERSION_PATCH})
|
|
|
|
|
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-DCUBICSDR_VERSION="${CUBICSDR_VERSION}"
|
|
|
|
)
|
|
|
|
|
2015-02-17 21:26:14 -05:00
|
|
|
IF (NOT APPLE)
|
2014-11-21 00:49:41 -05:00
|
|
|
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
|
2015-02-17 21:26:14 -05:00
|
|
|
ENDIF(NOT APPLE)
|
|
|
|
|
2014-11-21 00:49:41 -05:00
|
|
|
|
2014-12-07 21:06:05 -05:00
|
|
|
macro(configure_files srcDir destDir globStr)
|
|
|
|
message(STATUS "Copying ${srcDir}/${globStr} to directory ${destDir}")
|
2014-10-27 20:05:40 -04:00
|
|
|
make_directory(${destDir})
|
|
|
|
|
2014-12-07 21:06:05 -05:00
|
|
|
file(GLOB templateFiles RELATIVE ${srcDir} ${srcDir}/${globStr})
|
2014-10-27 20:05:40 -04:00
|
|
|
foreach(templateFile ${templateFiles})
|
|
|
|
set(srcTemplatePath ${srcDir}/${templateFile})
|
2014-12-07 21:06:05 -05:00
|
|
|
message(STATUS "Configuring file ${templateFile}")
|
2014-10-27 20:05:40 -04:00
|
|
|
if(NOT IS_DIRECTORY ${srcTemplatePath})
|
|
|
|
configure_file(
|
|
|
|
${srcTemplatePath}
|
|
|
|
${destDir}/${templateFile}
|
|
|
|
COPYONLY)
|
|
|
|
endif(NOT IS_DIRECTORY ${srcTemplatePath})
|
|
|
|
endforeach(templateFile)
|
|
|
|
endmacro(configure_files)
|
|
|
|
|
|
|
|
|
|
|
|
macro(configure_files_recurse srcDir destDir)
|
|
|
|
message(STATUS "Configuring directory ${destDir}")
|
|
|
|
make_directory(${destDir})
|
|
|
|
|
|
|
|
file(GLOB_RECURSE templateFiles RELATIVE ${srcDir} ${srcDir}/*)
|
|
|
|
foreach(templateFile ${templateFiles})
|
|
|
|
set(srcTemplatePath ${srcDir}/${templateFile})
|
2014-12-07 21:06:05 -05:00
|
|
|
message(STATUS "Configuring file ${templateFile}")
|
2014-10-27 20:05:40 -04:00
|
|
|
if(NOT IS_DIRECTORY ${srcTemplatePath})
|
|
|
|
configure_file(
|
|
|
|
${srcTemplatePath}
|
|
|
|
${destDir}/${templateFile}
|
|
|
|
COPYONLY)
|
|
|
|
endif(NOT IS_DIRECTORY ${srcTemplatePath})
|
|
|
|
endforeach(templateFile)
|
|
|
|
endmacro(configure_files_recurse)
|
|
|
|
|
|
|
|
project (CubicSDR)
|
|
|
|
|
2015-01-25 16:57:23 -05:00
|
|
|
if( CMAKE_SIZEOF_VOID_P EQUAL 8 )
|
|
|
|
MESSAGE( "64 bit compiler detected" )
|
|
|
|
SET( EX_PLATFORM 64 )
|
|
|
|
SET( EX_PLATFORM_NAME "x64" )
|
|
|
|
else( CMAKE_SIZEOF_VOID_P EQUAL 8 )
|
|
|
|
MESSAGE( "32 bit compiler detected" )
|
|
|
|
SET( EX_PLATFORM 32 )
|
|
|
|
SET( EX_PLATFORM_NAME "x86" )
|
|
|
|
endif( CMAKE_SIZEOF_VOID_P EQUAL 8 )
|
|
|
|
|
2015-02-20 00:34:32 -05:00
|
|
|
if ( WIN32 AND EX_PLATFORM EQUAL 64)
|
|
|
|
set(BUILD_X86 OFF CACHE BOOL "Copy & Build 32-bit files even if 64-bit compiler is detected.")
|
|
|
|
if (BUILD_X86)
|
|
|
|
SET( EX_PLATFORM 32 )
|
|
|
|
SET( EX_PLATFORM_NAME "x86" )
|
|
|
|
endif (BUILD_X86)
|
|
|
|
endif ( WIN32 AND EX_PLATFORM EQUAL 64)
|
|
|
|
|
2015-01-25 16:57:23 -05:00
|
|
|
SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/${EX_PLATFORM_NAME})
|
|
|
|
SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG ${PROJECT_BINARY_DIR}/${EX_PLATFORM_NAME})
|
|
|
|
SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE ${PROJECT_BINARY_DIR}/${EX_PLATFORM_NAME})
|
2014-10-27 20:05:40 -04:00
|
|
|
|
|
|
|
find_package(OpenGL REQUIRED)
|
|
|
|
|
2015-02-17 21:26:14 -05:00
|
|
|
find_package(wxWidgets COMPONENTS gl core base REQUIRED)
|
2014-10-27 20:05:40 -04:00
|
|
|
set(wxWidgets_CONFIGURATION mswu)
|
|
|
|
include(${wxWidgets_USE_FILE})
|
|
|
|
|
2015-01-25 16:57:23 -05:00
|
|
|
|
2014-12-07 21:06:05 -05:00
|
|
|
IF (WIN32)
|
2015-01-26 22:18:15 -05:00
|
|
|
set(wxWidgets_USE_STATIC ON)
|
2015-03-01 21:39:52 -05:00
|
|
|
|
|
|
|
set(BUILD_INSTALLER OFF CACHE BOOL "Build Installer")
|
2015-01-26 22:18:15 -05:00
|
|
|
|
|
|
|
# Audio device selection is not mandatory, dummy audio device is used if none are compiled in.
|
|
|
|
# Can also compile support for more than one simultaneously.
|
2015-02-04 18:10:42 -05:00
|
|
|
set(USE_AUDIO_DS ON CACHE BOOL "Include support for DirectSound")
|
|
|
|
set(USE_AUDIO_WASAPI OFF CACHE BOOL "Include support for WASAPI Audio")
|
2015-01-26 22:18:15 -05:00
|
|
|
# TODO:
|
|
|
|
# set(USE_AUDIO_ASIO OFF CACHE BOOL "Include support for ASIO Audio")
|
|
|
|
|
|
|
|
# WASAPI
|
|
|
|
IF(USE_AUDIO_WASAPI)
|
|
|
|
ADD_DEFINITIONS(-D__WINDOWS_WASAPI__)
|
|
|
|
IF (NOT MSVC)
|
|
|
|
SET(OTHER_LIBRARIES ${OTHER_LIBRARIES} -luuid -lksuser)
|
|
|
|
ENDIF(NOT MSVC)
|
|
|
|
ENDIF(USE_AUDIO_WASAPI)
|
|
|
|
|
|
|
|
# DirectSound
|
|
|
|
IF (USE_AUDIO_DS)
|
|
|
|
ADD_DEFINITIONS(-D__WINDOWS_DS__)
|
|
|
|
IF (MSVC)
|
|
|
|
SET(OTHER_LIBRARIES ${OTHER_LIBRARIES} dsound.lib)
|
|
|
|
ELSE (MSVC)
|
|
|
|
SET(OTHER_LIBRARIES ${OTHER_LIBRARIES} -ldsound)
|
|
|
|
ENDIF (MSVC)
|
|
|
|
ENDIF(USE_AUDIO_DS)
|
|
|
|
|
|
|
|
# ASIO?
|
|
|
|
#IF(USE_AUDIO_ASIO)
|
|
|
|
#ENDIF(USE_AUDIO_ASIO)
|
|
|
|
|
|
|
|
# FFTW
|
|
|
|
include_directories ( ${PROJECT_SOURCE_DIR}/external/fftw-3.3.4 ${PROJECT_SOURCE_DIR}/external/rtl-sdr-release )
|
|
|
|
set(FFTW_LIB libfftw3f-3)
|
|
|
|
link_directories ( ${PROJECT_SOURCE_DIR}/external/fftw-3.3.4/${EX_PLATFORM} )
|
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/external/fftw-3.3.4/${EX_PLATFORM} ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} "*.dll")
|
|
|
|
|
|
|
|
include_directories ( ${PROJECT_SOURCE_DIR}/external/liquid-dsp/include )
|
|
|
|
set(LIQUID_LIB libliquid)
|
|
|
|
|
|
|
|
# Haven't looked into why these are different, just explicitly including everything for now until it can be sorted neatly.
|
|
|
|
IF (MSVC)
|
|
|
|
# LIQUID
|
|
|
|
link_directories ( ${PROJECT_SOURCE_DIR}/external/liquid-dsp/msvc/${EX_PLATFORM} )
|
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/external/liquid-dsp/msvc/${EX_PLATFORM} ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME}/ "*.dll")
|
|
|
|
# RTL-SDR
|
|
|
|
link_directories ( ${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/msvc/${EX_PLATFORM} )
|
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/msvc/${EX_PLATFORM} ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} "*.dll")
|
|
|
|
ELSE (MSVC) # GCC
|
|
|
|
# LIQUID
|
|
|
|
link_directories ( ${PROJECT_SOURCE_DIR}/external/liquid-dsp/gcc/${EX_PLATFORM} )
|
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/external/liquid-dsp/gcc/${EX_PLATFORM} ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} "*.dll")
|
|
|
|
# RTL-SDR
|
|
|
|
link_directories ( ${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/gcc/${EX_PLATFORM} )
|
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/gcc/${EX_PLATFORM} ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} "*.dll")
|
|
|
|
ENDIF(MSVC)
|
2014-12-07 21:06:05 -05:00
|
|
|
|
|
|
|
# Copy DLL files to build dir
|
2015-01-25 16:57:23 -05:00
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/external/fftw-3.3.4/${EX_PLATFORM_NAME} ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} "*.dll")
|
2014-12-07 21:06:05 -05:00
|
|
|
|
|
|
|
ENDIF (WIN32)
|
2014-12-04 22:25:18 -05:00
|
|
|
|
2015-01-19 19:24:15 -05:00
|
|
|
IF (UNIX AND NOT APPLE)
|
2015-03-08 20:17:19 -04:00
|
|
|
set(BUILD_DEB OFF CACHE BOOL "Build DEB")
|
|
|
|
|
2015-01-18 01:36:28 -05:00
|
|
|
set(RTLSDR_INCLUDE "/usr/local/include" CACHE FILEPATH "RTL-SDR Include Path")
|
|
|
|
set(RTLSDR_LIB "/usr/local/lib" CACHE FILEPATH "RTL-SDR Lib Path")
|
|
|
|
set(USE_AUDIO_PULSE ON CACHE BOOL "Use Pulse Audio")
|
|
|
|
set(USE_AUDIO_JACK OFF CACHE BOOL "Use Jack Audio")
|
|
|
|
set(USE_AUDIO_ALSA OFF CACHE BOOL "Use ALSA Audio")
|
|
|
|
set(USE_AUDIO_OSS OFF CACHE BOOL "Use OSS Audio")
|
2014-12-04 22:25:18 -05:00
|
|
|
include_directories(${RTLSDR_INCLUDE})
|
|
|
|
link_directories(${RTLSDR_LIB})
|
2014-12-04 19:03:02 -05:00
|
|
|
|
2015-01-06 20:00:23 -05:00
|
|
|
set(FFTW_LIB fftw3f)
|
2015-02-11 20:41:13 -05:00
|
|
|
set(LIQUID_LIB liquid)
|
|
|
|
set(OTHER_LIBRARIES dl)
|
2014-12-04 22:25:18 -05:00
|
|
|
|
2015-01-18 01:36:28 -05:00
|
|
|
IF(USE_AUDIO_PULSE)
|
|
|
|
SET (OTHER_LIBRARIES ${OTHER_LIBRARIES} pulse-simple pulse)
|
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-D__LINUX_PULSE__
|
|
|
|
)
|
|
|
|
ENDIF(USE_AUDIO_PULSE)
|
|
|
|
|
|
|
|
IF(USE_AUDIO_JACK)
|
2015-03-22 20:47:07 -04:00
|
|
|
find_package(Jack)
|
|
|
|
SET (OTHER_LIBRARIES ${OTHER_LIBRARIES} ${JACK_LIBRARIES})
|
2015-01-18 01:36:28 -05:00
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-D__UNIX_JACK__
|
|
|
|
)
|
2015-03-22 20:47:07 -04:00
|
|
|
include_directories(${JACK_INCLUDE_DIRS})
|
2015-01-18 01:36:28 -05:00
|
|
|
ENDIF(USE_AUDIO_JACK)
|
|
|
|
|
|
|
|
IF(USE_AUDIO_ALSA)
|
|
|
|
SET (OTHER_LIBRARIES ${OTHER_LIBRARIES} asound)
|
|
|
|
set(ALSA_INCLUDE_DIR "/usr/include" CACHE FILEPATH "ALSA include path")
|
|
|
|
include_directories(${ALSA_INCLUDE_DIR})
|
|
|
|
set(ALSA_LIB_DIR "/usr/lib" CACHE FILEPATH "ALSA lib path")
|
|
|
|
link_directories(${ALSA_LIB_DIR})
|
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-D__LINUX_ALSA__
|
|
|
|
)
|
|
|
|
ENDIF(USE_AUDIO_ALSA)
|
|
|
|
|
|
|
|
IF(USE_AUDIO_OSS)
|
|
|
|
SET (OTHER_LIBRARIES ${OTHER_LIBRARIES} oss)
|
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-D__LINUX_OSS__
|
|
|
|
)
|
|
|
|
ENDIF(USE_AUDIO_OSS)
|
2015-01-19 19:24:15 -05:00
|
|
|
ENDIF(UNIX AND NOT APPLE)
|
2014-12-04 22:25:18 -05:00
|
|
|
|
|
|
|
IF (APPLE)
|
|
|
|
set(RTLSDR_INCLUDE "/opt/local/include" CACHE FILEPATH "RTL-SDR Include Path")
|
|
|
|
set(RTLSDR_LIB "/opt/local/lib" CACHE FILEPATH "RTL-SDR Lib Path")
|
|
|
|
include_directories(${RTLSDR_INCLUDE})
|
|
|
|
link_directories(${RTLSDR_LIB})
|
2015-02-17 21:26:14 -05:00
|
|
|
set(LIB_DIRS "${LIB_DIRS} ${RTLSDR_LIB}")
|
2014-11-06 21:30:47 -05:00
|
|
|
|
2015-01-06 20:00:23 -05:00
|
|
|
set(FFTW_LIB fftw3f)
|
2015-02-11 20:41:13 -05:00
|
|
|
set(LIQUID_LIB liquid)
|
2014-12-04 22:25:18 -05:00
|
|
|
|
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-D__MACOSX_CORE__
|
|
|
|
)
|
2014-10-27 23:52:25 -04:00
|
|
|
|
2014-12-04 22:25:18 -05:00
|
|
|
FIND_LIBRARY(COREAUDIO_LIBRARY CoreAudio)
|
2015-02-11 20:41:13 -05:00
|
|
|
SET (OTHER_LIBRARIES ${COREAUDIO_LIBRARY})
|
2015-02-17 21:26:14 -05:00
|
|
|
set(BUNDLE_APP OFF CACHE BOOL "Bundle Application")
|
|
|
|
|
2014-12-04 22:25:18 -05:00
|
|
|
ENDIF (APPLE)
|
2014-10-27 23:52:25 -04:00
|
|
|
|
2014-10-27 20:05:40 -04:00
|
|
|
|
|
|
|
SET (cubicsdr_sources
|
2015-07-27 22:30:25 -04:00
|
|
|
src/CubicSDR.cpp
|
2014-10-27 21:22:29 -04:00
|
|
|
src/AppFrame.cpp
|
2015-04-13 19:58:34 -04:00
|
|
|
src/AppConfig.cpp
|
2015-05-04 19:44:03 -04:00
|
|
|
src/FrequencyDialog.cpp
|
2015-07-29 18:34:58 -04:00
|
|
|
src/IOThread.cpp
|
2015-07-29 22:19:00 -04:00
|
|
|
src/sdr/SDRDeviceInfo.cpp
|
2014-11-17 21:29:27 -05:00
|
|
|
src/sdr/SDRThread.cpp
|
2014-11-29 13:58:20 -05:00
|
|
|
src/sdr/SDRPostThread.cpp
|
2014-12-16 18:27:02 -05:00
|
|
|
src/demod/DemodulatorPreThread.cpp
|
2014-11-17 21:29:27 -05:00
|
|
|
src/demod/DemodulatorThread.cpp
|
2014-11-30 23:33:55 -05:00
|
|
|
src/demod/DemodulatorWorkerThread.cpp
|
2014-12-11 23:35:06 -05:00
|
|
|
src/demod/DemodulatorInstance.cpp
|
2014-11-17 22:58:56 -05:00
|
|
|
src/demod/DemodulatorMgr.cpp
|
2014-11-17 21:29:27 -05:00
|
|
|
src/audio/AudioThread.cpp
|
|
|
|
src/util/Gradient.cpp
|
|
|
|
src/util/Timer.cpp
|
2014-11-25 21:07:13 -05:00
|
|
|
src/util/MouseTracker.cpp
|
2015-02-09 20:49:21 -05:00
|
|
|
src/util/GLExt.cpp
|
2014-12-07 21:06:05 -05:00
|
|
|
src/util/GLFont.cpp
|
2015-07-27 22:30:25 -04:00
|
|
|
src/util/DataTree.cpp
|
2015-08-09 12:51:01 -04:00
|
|
|
src/panel/ScopePanel.cpp
|
2015-08-09 23:00:51 -04:00
|
|
|
src/panel/SpectrumPanel.cpp
|
|
|
|
src/panel/WaterfallPanel.cpp
|
2015-01-14 22:14:57 -05:00
|
|
|
src/visual/ColorTheme.cpp
|
2014-11-17 21:29:27 -05:00
|
|
|
src/visual/PrimaryGLContext.cpp
|
2015-01-02 21:32:24 -05:00
|
|
|
src/visual/InteractiveCanvas.cpp
|
2014-12-31 19:45:01 -05:00
|
|
|
src/visual/MeterCanvas.cpp
|
|
|
|
src/visual/MeterContext.cpp
|
2015-01-04 17:11:20 -05:00
|
|
|
src/visual/TuningCanvas.cpp
|
|
|
|
src/visual/TuningContext.cpp
|
2015-01-04 19:50:05 -05:00
|
|
|
src/visual/ModeSelectorCanvas.cpp
|
|
|
|
src/visual/ModeSelectorContext.cpp
|
2014-11-12 21:55:11 -05:00
|
|
|
src/visual/ScopeCanvas.cpp
|
|
|
|
src/visual/ScopeContext.cpp
|
2014-11-15 23:41:41 -05:00
|
|
|
src/visual/SpectrumCanvas.cpp
|
|
|
|
src/visual/WaterfallCanvas.cpp
|
2015-07-27 22:30:25 -04:00
|
|
|
src/process/VisualProcessor.cpp
|
2015-07-28 21:56:39 -04:00
|
|
|
src/process/ScopeVisualProcessor.cpp
|
2015-07-27 22:30:25 -04:00
|
|
|
src/process/SpectrumVisualProcessor.cpp
|
2015-08-14 19:17:43 -04:00
|
|
|
src/process/FFTVisualDataThread.cpp
|
2015-08-16 18:12:12 -04:00
|
|
|
src/process/SpectrumVisualDataThread.cpp
|
2015-07-27 22:30:25 -04:00
|
|
|
src/ui/GLPanel.cpp
|
2014-12-04 19:03:02 -05:00
|
|
|
external/rtaudio/RtAudio.cpp
|
2014-12-07 21:06:05 -05:00
|
|
|
external/lodepng/lodepng.cpp
|
2015-07-27 22:30:25 -04:00
|
|
|
external/tinyxml/tinyxml.cpp
|
|
|
|
external/tinyxml/tinystr.cpp
|
|
|
|
external/tinyxml/tinyxmlparser.cpp
|
|
|
|
external/tinyxml/tinyxmlerror.cpp
|
|
|
|
external/cubicvr2/math/cubic_math.cpp
|
2014-10-27 20:05:40 -04:00
|
|
|
)
|
|
|
|
|
|
|
|
SET (cubicsdr_headers
|
2014-11-17 21:29:27 -05:00
|
|
|
src/CubicSDRDefs.h
|
2015-07-27 22:30:25 -04:00
|
|
|
src/CubicSDR.h
|
2014-10-27 21:22:29 -04:00
|
|
|
src/AppFrame.h
|
2015-04-13 19:58:34 -04:00
|
|
|
src/AppConfig.h
|
2015-05-04 19:44:03 -04:00
|
|
|
src/FrequencyDialog.h
|
2015-07-29 18:34:58 -04:00
|
|
|
src/IOThread.h
|
2015-07-29 22:19:00 -04:00
|
|
|
src/sdr/SDRDeviceInfo.h
|
2014-11-17 21:29:27 -05:00
|
|
|
src/sdr/SDRThread.h
|
2014-11-29 13:58:20 -05:00
|
|
|
src/sdr/SDRPostThread.h
|
2014-12-16 18:27:02 -05:00
|
|
|
src/demod/DemodulatorPreThread.h
|
2014-11-17 21:29:27 -05:00
|
|
|
src/demod/DemodulatorThread.h
|
2014-11-30 23:33:55 -05:00
|
|
|
src/demod/DemodulatorWorkerThread.h
|
2014-12-11 23:35:06 -05:00
|
|
|
src/demod/DemodulatorInstance.h
|
2014-11-17 22:58:56 -05:00
|
|
|
src/demod/DemodulatorMgr.h
|
2014-12-11 19:07:21 -05:00
|
|
|
src/demod/DemodDefs.h
|
2014-11-17 21:29:27 -05:00
|
|
|
src/audio/AudioThread.h
|
|
|
|
src/util/Gradient.h
|
|
|
|
src/util/Timer.h
|
2014-11-20 20:10:28 -05:00
|
|
|
src/util/ThreadQueue.h
|
2014-11-25 21:07:13 -05:00
|
|
|
src/util/MouseTracker.h
|
2015-02-09 20:49:21 -05:00
|
|
|
src/util/GLExt.h
|
2014-12-07 21:06:05 -05:00
|
|
|
src/util/GLFont.h
|
2015-07-27 22:30:25 -04:00
|
|
|
src/util/DataTree.h
|
2015-08-09 12:51:01 -04:00
|
|
|
src/panel/ScopePanel.h
|
2015-08-09 23:00:51 -04:00
|
|
|
src/panel/SpectrumPanel.h
|
|
|
|
src/panel/WaterfallPanel.h
|
2015-01-14 22:14:57 -05:00
|
|
|
src/visual/ColorTheme.h
|
2014-11-17 21:29:27 -05:00
|
|
|
src/visual/PrimaryGLContext.h
|
2015-01-02 21:32:24 -05:00
|
|
|
src/visual/InteractiveCanvas.h
|
2014-12-31 19:45:01 -05:00
|
|
|
src/visual/MeterCanvas.h
|
|
|
|
src/visual/MeterContext.h
|
2015-01-04 17:11:20 -05:00
|
|
|
src/visual/TuningCanvas.h
|
|
|
|
src/visual/TuningContext.h
|
2015-01-04 19:50:05 -05:00
|
|
|
src/visual/ModeSelectorCanvas.h
|
|
|
|
src/visual/ModeSelectorContext.h
|
2014-11-12 21:55:11 -05:00
|
|
|
src/visual/ScopeCanvas.h
|
|
|
|
src/visual/ScopeContext.h
|
2014-11-15 23:41:41 -05:00
|
|
|
src/visual/SpectrumCanvas.h
|
|
|
|
src/visual/WaterfallCanvas.h
|
2015-07-27 22:30:25 -04:00
|
|
|
src/process/VisualProcessor.h
|
2015-07-28 21:56:39 -04:00
|
|
|
src/process/ScopeVisualProcessor.h
|
2015-07-27 22:30:25 -04:00
|
|
|
src/process/SpectrumVisualProcessor.h
|
2015-08-14 19:17:43 -04:00
|
|
|
src/process/FFTVisualDataThread.h
|
2015-08-16 18:12:12 -04:00
|
|
|
src/process/SpectrumVisualDataThread.h
|
2015-07-27 22:30:25 -04:00
|
|
|
src/ui/GLPanel.h
|
|
|
|
src/ui/UITestCanvas.cpp
|
|
|
|
src/ui/UITestCanvas.h
|
|
|
|
src/ui/UITestContext.cpp
|
|
|
|
src/ui/UITestContext.h
|
2014-12-04 19:03:02 -05:00
|
|
|
external/rtaudio/RtAudio.h
|
2014-12-07 21:06:05 -05:00
|
|
|
external/lodepng/lodepng.h
|
2015-07-27 22:30:25 -04:00
|
|
|
external/tinyxml/tinyxml.h
|
|
|
|
external/tinyxml/tinystr.h
|
|
|
|
external/cubicvr2/math/aabb.h
|
|
|
|
external/cubicvr2/math/cubic_math.h
|
|
|
|
external/cubicvr2/math/cubic_types.h
|
|
|
|
external/cubicvr2/math/frustum.h
|
|
|
|
external/cubicvr2/math/mat3.h
|
|
|
|
external/cubicvr2/math/mat4.h
|
|
|
|
external/cubicvr2/math/plane.h
|
|
|
|
external/cubicvr2/math/quaternion.h
|
|
|
|
external/cubicvr2/math/sphere.h
|
|
|
|
external/cubicvr2/math/transform.h
|
|
|
|
external/cubicvr2/math/triangle.h
|
|
|
|
external/cubicvr2/math/vec2.h
|
|
|
|
external/cubicvr2/math/vec3.h
|
|
|
|
external/cubicvr2/math/vec4.h
|
2014-10-27 20:05:40 -04:00
|
|
|
)
|
2014-11-12 21:55:11 -05:00
|
|
|
|
2015-08-08 14:15:57 -04:00
|
|
|
set(REG_EXT "[^/]*([.]cpp|[.]c|[.]h|[.]hpp)$")
|
|
|
|
|
|
|
|
SOURCE_GROUP("Base" REGULAR_EXPRESSION src/${REG_EXT})
|
|
|
|
SOURCE_GROUP("SDR" REGULAR_EXPRESSION src/sdr/${REG_EXT})
|
|
|
|
SOURCE_GROUP("Demodulator" REGULAR_EXPRESSION src/demod/${REG_EXT})
|
|
|
|
SOURCE_GROUP("Audio" REGULAR_EXPRESSION src/audio/${REG_EXT})
|
|
|
|
SOURCE_GROUP("Utility" REGULAR_EXPRESSION src/util/${REG_EXT})
|
2015-08-09 12:51:01 -04:00
|
|
|
SOURCE_GROUP("Panel" REGULAR_EXPRESSION src/panel/${REG_EXT})
|
2015-08-08 14:15:57 -04:00
|
|
|
SOURCE_GROUP("Visual" REGULAR_EXPRESSION src/visual/${REG_EXT})
|
|
|
|
SOURCE_GROUP("Process" REGULAR_EXPRESSION src/process/${REG_EXT})
|
|
|
|
SOURCE_GROUP("UI" REGULAR_EXPRESSION src/ui/${REG_EXT})
|
|
|
|
SOURCE_GROUP("_ext-RTAudio" REGULAR_EXPRESSION external/rtaudio/.*${REG_EXT})
|
|
|
|
SOURCE_GROUP("_ext-LodePNG" REGULAR_EXPRESSION external/lodepng/.*${REG_EXT})
|
|
|
|
SOURCE_GROUP("_ext-TinyXML" REGULAR_EXPRESSION external/tinyxml/.*${REG_EXT})
|
|
|
|
SOURCE_GROUP("_ext-CubicVR2" REGULAR_EXPRESSION external/cubicvr2/.*${REG_EXT})
|
|
|
|
|
2014-12-07 21:06:05 -05:00
|
|
|
include_directories (
|
|
|
|
${PROJECT_SOURCE_DIR}/src/sdr
|
|
|
|
${PROJECT_SOURCE_DIR}/src/demod
|
|
|
|
${PROJECT_SOURCE_DIR}/src/audio
|
|
|
|
${PROJECT_SOURCE_DIR}/src/util
|
2015-08-09 12:51:01 -04:00
|
|
|
${PROJECT_SOURCE_DIR}/src/panel
|
2015-07-27 22:30:25 -04:00
|
|
|
${PROJECT_SOURCE_DIR}/src/visual
|
|
|
|
${PROJECT_SOURCE_DIR}/src/process
|
2015-06-20 20:19:52 -04:00
|
|
|
${PROJECT_SOURCE_DIR}/src/ui
|
2014-12-07 21:06:05 -05:00
|
|
|
${PROJECT_SOURCE_DIR}/src
|
|
|
|
${PROJECT_SOURCE_DIR}/external/rtaudio
|
|
|
|
${PROJECT_SOURCE_DIR}/external/lodepng
|
2015-01-07 20:23:15 -05:00
|
|
|
${PROJECT_SOURCE_DIR}/external/tinyxml
|
2015-06-26 22:04:16 -04:00
|
|
|
${PROJECT_SOURCE_DIR}/external/cubicvr2/math
|
2014-12-07 21:06:05 -05:00
|
|
|
)
|
2015-02-09 22:01:33 -05:00
|
|
|
|
|
|
|
IF (MSVC)
|
|
|
|
include_directories (
|
|
|
|
${PROJECT_SOURCE_DIR}/external/wglext
|
|
|
|
)
|
|
|
|
|
|
|
|
ELSE (MSVC)
|
2015-01-25 16:57:23 -05:00
|
|
|
ADD_DEFINITIONS(
|
2015-02-17 21:26:14 -05:00
|
|
|
-std=c++0x
|
2015-01-25 16:57:23 -05:00
|
|
|
-pthread
|
|
|
|
)
|
2015-02-09 22:01:33 -05:00
|
|
|
ENDIF(MSVC)
|
2014-11-12 21:55:11 -05:00
|
|
|
|
2015-03-05 21:02:38 -05:00
|
|
|
set(RES_FILES "")
|
2015-03-11 20:28:14 -04:00
|
|
|
if(MINGW OR MSVC)
|
2015-03-05 21:02:38 -05:00
|
|
|
set(RES_FILES ${PROJECT_SOURCE_DIR}/cubicsdr.rc)
|
|
|
|
set(CMAKE_RC_COMPILER_INIT windres)
|
|
|
|
ENABLE_LANGUAGE(RC)
|
|
|
|
IF(EX_PLATFORM EQUAL 64)
|
|
|
|
SET(RC_TARGET "pe-x86-64")
|
|
|
|
ELSE(EX_PLATFORM EQUAL 64)
|
|
|
|
SET(RC_TARGET "pe-i386")
|
|
|
|
ENDIF(EX_PLATFORM EQUAL 64)
|
|
|
|
|
|
|
|
SET(CMAKE_RC_COMPILE_OBJECT "<CMAKE_RC_COMPILER> -O coff <DEFINES> -i <SOURCE> -o <OBJECT>")
|
2015-03-11 20:28:14 -04:00
|
|
|
endif(MINGW OR MSVC)
|
2014-10-27 20:05:40 -04:00
|
|
|
|
2015-02-17 21:26:14 -05:00
|
|
|
IF (NOT BUNDLE_APP)
|
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/font ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} "*.fnt")
|
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/font ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} "*.png")
|
2015-03-07 20:29:25 -05:00
|
|
|
configure_files(${PROJECT_SOURCE_DIR}/icon ${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME} CubicSDR.ico)
|
2015-03-05 21:02:38 -05:00
|
|
|
add_executable(CubicSDR ${cubicsdr_sources} ${cubicsdr_headers} ${RES_FILES})
|
2015-02-17 21:26:14 -05:00
|
|
|
target_link_libraries(CubicSDR rtlsdr ${LIQUID_LIB} ${FFTW_LIB} ${wxWidgets_LIBRARIES} ${OPENGL_LIBRARIES} ${OTHER_LIBRARIES})
|
|
|
|
ENDIF (NOT BUNDLE_APP)
|
2014-12-07 21:06:05 -05:00
|
|
|
|
2015-01-26 22:18:15 -05:00
|
|
|
IF (MSVC)
|
|
|
|
set_target_properties(CubicSDR PROPERTIES LINK_FLAGS_DEBUG "/SUBSYSTEM:WINDOWS")
|
|
|
|
set_target_properties(CubicSDR PROPERTIES COMPILE_DEFINITIONS_DEBUG "_WINDOWS")
|
|
|
|
set_target_properties(CubicSDR PROPERTIES LINK_FLAGS_RELWITHDEBINFO "/SUBSYSTEM:WINDOWS")
|
|
|
|
set_target_properties(CubicSDR PROPERTIES COMPILE_DEFINITIONS_RELWITHDEBINFO "_WINDOWS")
|
2015-01-25 16:57:23 -05:00
|
|
|
set_target_properties(CubicSDR PROPERTIES LINK_FLAGS_RELEASE "/SUBSYSTEM:WINDOWS")
|
2015-01-26 22:18:15 -05:00
|
|
|
set_target_properties(CubicSDR PROPERTIES COMPILE_DEFINITIONS_RELEASE "_WINDOWS")
|
2015-01-25 16:57:23 -05:00
|
|
|
set_target_properties(CubicSDR PROPERTIES LINK_FLAGS_MINSIZEREL "/SUBSYSTEM:WINDOWS")
|
2015-01-26 22:18:15 -05:00
|
|
|
set_target_properties(CubicSDR PROPERTIES COMPILE_DEFINITIONS_MINSIZEREL "_WINDOWS")
|
|
|
|
set(CMAKE_CREATE_WIN32_EXE "/SUBSYSTEM:WINDOWS /ENTRY:\"mainCRTStartup\"")
|
|
|
|
ENDIF(MSVC)
|
2014-12-07 21:06:05 -05:00
|
|
|
|
2015-02-17 21:26:14 -05:00
|
|
|
IF (APPLE AND BUNDLE_APP)
|
|
|
|
PROJECT(CubicSDR)
|
|
|
|
SET(MACOSX_BUNDLE_BUNDLE_NAME CubicSDR)
|
|
|
|
|
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-std=c++0x
|
|
|
|
-pthread
|
|
|
|
-D_OSX_APP_
|
|
|
|
-DHAVE_TYPE_TRAITS=1
|
|
|
|
-mmacosx-version-min=10.9
|
|
|
|
)
|
|
|
|
|
|
|
|
ADD_EXECUTABLE(CubicSDR
|
|
|
|
MACOSX_BUNDLE
|
|
|
|
${cubicsdr_sources}
|
|
|
|
${cubicsdr_headers}
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48_0.png
|
2015-02-21 23:08:08 -05:00
|
|
|
${PROJECT_SOURCE_DIR}/icon/CubicSDR.icns
|
2015-02-17 21:26:14 -05:00
|
|
|
)
|
|
|
|
|
|
|
|
SET_SOURCE_FILES_PROPERTIES(
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48_0.png
|
2015-02-21 23:08:08 -05:00
|
|
|
${PROJECT_SOURCE_DIR}/icon/CubicSDR.icns
|
2015-02-17 21:26:14 -05:00
|
|
|
PROPERTIES
|
|
|
|
MACOSX_PACKAGE_LOCATION Resources
|
|
|
|
)
|
|
|
|
|
|
|
|
target_link_libraries(CubicSDR rtlsdr ${LIQUID_LIB} ${FFTW_LIB} ${wxWidgets_LIBRARIES} ${OPENGL_LIBRARIES} ${OTHER_LIBRARIES})
|
|
|
|
SET_TARGET_PROPERTIES(CubicSDR PROPERTIES MACOSX_BUNDLE TRUE)
|
2015-02-21 23:08:08 -05:00
|
|
|
|
|
|
|
SET_TARGET_PROPERTIES(CubicSDR PROPERTIES
|
|
|
|
MACOSX_BUNDLE_BUNDLE_NAME "CubicSDR"
|
|
|
|
# MACOSX_BUNDLE_BUNDLE_VERSION ${PROJECT_VERSION}
|
|
|
|
# MACOSX_BUNDLE_LONG_VERSION_STRING "${PROJECT_VERSION}"
|
|
|
|
# MACOSX_BUNDLE_SHORT_VERSION_STRING "${PROJECT_VERSION}"
|
|
|
|
MACOSX_BUNDLE_GUI_IDENTIFIER "com.cubicproductions.cubicsdr"
|
|
|
|
MACOSX_BUNDLE_ICON_FILE CubicSDR.icns
|
|
|
|
)
|
2015-02-17 21:26:14 -05:00
|
|
|
|
|
|
|
SET(APPS "${CMAKE_BINARY_DIR}/${EX_PLATFORM_NAME}/CubicSDR.app")
|
|
|
|
# SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH FALSE)
|
|
|
|
# SET(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE)
|
|
|
|
|
|
|
|
INSTALL(CODE "
|
|
|
|
SET(BU_COPY_FULL_FRAMEWORK_CONTENTS ON)
|
|
|
|
include(BundleUtilities)
|
|
|
|
fixup_bundle(\"${APPS}\" \"\" \"${RTLSDR_LIB}\")
|
|
|
|
VERIFY_APP(\"${APPS}\")
|
|
|
|
" COMPONENT Runtime)
|
2015-02-21 23:08:08 -05:00
|
|
|
|
|
|
|
INSTALL(TARGETS CubicSDR
|
|
|
|
BUNDLE DESTINATION . COMPONENT Runtime
|
|
|
|
)
|
|
|
|
|
2015-02-17 21:26:14 -05:00
|
|
|
set(CPACK_BINARY_DRAGNDROP ON)
|
|
|
|
include(CPack)
|
|
|
|
ENDIF (APPLE AND BUNDLE_APP)
|
2015-03-01 21:39:52 -05:00
|
|
|
|
|
|
|
IF (WIN32 AND BUILD_INSTALLER)
|
2015-03-04 22:58:50 -05:00
|
|
|
set(CPACK_GENERATOR NSIS)
|
2015-03-01 21:39:52 -05:00
|
|
|
set(CPACK_PACKAGE_NAME "CubicSDR")
|
|
|
|
set(CPACK_PACKAGE_VENDOR "cubicsdr.com")
|
|
|
|
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "CubicSDR ${CUBICSDR_VERSION} Installer")
|
|
|
|
set(CPACK_PACKAGE_INSTALL_DIRECTORY "CubicSDR")
|
2015-03-04 22:58:50 -05:00
|
|
|
SET(CPACK_NSIS_INSTALLED_ICON_NAME "CubicSDR.ico")
|
|
|
|
SET(CPACK_RESOURCE_FILE_LICENSE "${PROJECT_SOURCE_DIR}/LICENSE")
|
2015-03-05 21:02:38 -05:00
|
|
|
set(CPACK_PACKAGE_ICON "${PROJECT_SOURCE_DIR}/icon\\\\NSIS_Header.bmp")
|
2015-03-04 22:58:50 -05:00
|
|
|
IF(EX_PLATFORM EQUAL 64)
|
|
|
|
SET(CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES64")
|
|
|
|
SET(CPACK_NSIS_PACKAGE_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY}")
|
|
|
|
SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${CPACK_PACKAGE_NAME} ${CPACK_PACKAGE_VERSION}")
|
|
|
|
set(CMAKE_CL_64 TRUE) # This gets around a bug in the CPack installer name generation for MinGW 64-bit since 2.8
|
|
|
|
ELSE(EX_PLATFORM EQUAL 64)
|
|
|
|
SET(CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES")
|
|
|
|
SET(CPACK_NSIS_PACKAGE_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY} (x86)")
|
|
|
|
SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${CPACK_PACKAGE_NAME} ${CPACK_PACKAGE_VERSION} (x86)")
|
|
|
|
set(CMAKE_CL_64 FALSE)
|
|
|
|
ENDIF(EX_PLATFORM EQUAL 64)
|
2015-03-01 21:39:52 -05:00
|
|
|
|
2015-03-04 22:58:50 -05:00
|
|
|
set(CPACK_NSIS_EXECUTABLES_DIRECTORY ".")
|
|
|
|
install(TARGETS CubicSDR RUNTIME DESTINATION .)
|
|
|
|
install(FILES
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/icon/CubicSDR.ico
|
|
|
|
${PROJECT_SOURCE_DIR}/external/fftw-3.3.4/${EX_PLATFORM}/libfftw3f-3.dll
|
|
|
|
DESTINATION .)
|
|
|
|
IF (MSVC)
|
|
|
|
install(FILES
|
|
|
|
${PROJECT_SOURCE_DIR}/external/liquid-dsp/msvc/${EX_PLATFORM}/libliquid.dll
|
|
|
|
${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/msvc/${EX_PLATFORM}/rtlsdr.dll
|
|
|
|
${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/msvc/${EX_PLATFORM}/libusb-1.0.dll
|
|
|
|
DESTINATION .)
|
|
|
|
ELSE (MSVC)
|
|
|
|
install(FILES
|
|
|
|
${PROJECT_SOURCE_DIR}/external/liquid-dsp/gcc/${EX_PLATFORM}/libliquid.dll
|
|
|
|
${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/gcc/${EX_PLATFORM}/librtlsdr.dll
|
|
|
|
${PROJECT_SOURCE_DIR}/external/rtl-sdr-release/gcc/${EX_PLATFORM}/libusb-1.0.dll
|
|
|
|
DESTINATION .)
|
|
|
|
ENDIF(MSVC)
|
2015-03-11 20:28:14 -04:00
|
|
|
|
|
|
|
IF(MSVC AND EX_PLATFORM EQUAL 32)
|
|
|
|
install(FILES
|
|
|
|
${PROJECT_SOURCE_DIR}/external/msvc/${EX_PLATFORM_NAME}/libgcc_s_dw2-1.dll
|
|
|
|
DESTINATION .)
|
|
|
|
ENDIF(MSVC AND EX_PLATFORM EQUAL 32)
|
2015-03-04 22:58:50 -05:00
|
|
|
|
|
|
|
set(CPACK_PACKAGE_EXECUTABLES CubicSDR "CubicSDR")
|
|
|
|
|
|
|
|
IF (MSVC)
|
|
|
|
install(PROGRAMS ${CMAKE_CURRENT_SOURCE_DIR}/external/msvc/${EX_PLATFORM_NAME}/vcredist_${EX_PLATFORM_NAME}.exe DESTINATION vc_redist)
|
|
|
|
set(CPACK_NSIS_EXTRA_INSTALL_COMMANDS "ExecWait '\\\"$INSTDIR\\\\vc_redist\\\\vcredist_${EX_PLATFORM_NAME}.exe\\\" /q:a'")
|
|
|
|
ENDIF (MSVC)
|
|
|
|
|
2015-03-05 21:02:38 -05:00
|
|
|
|
2015-03-04 22:58:50 -05:00
|
|
|
INCLUDE(CPack)
|
2015-03-08 20:17:19 -04:00
|
|
|
ENDIF (WIN32 AND BUILD_INSTALLER)
|
|
|
|
|
|
|
|
|
|
|
|
IF (UNIX AND BUILD_DEB)
|
|
|
|
|
|
|
|
set(CPACK_GENERATOR DEB)
|
|
|
|
set(CPACK_PACKAGE_NAME "CubicSDR")
|
|
|
|
SET(CPACK_DEBIAN_PACKAGE_DEPENDS " librtlsdr0, libfftw3-single3, libwxgtk3.0-0, libpulse0")
|
|
|
|
SET(CPACK_DEBIAN_PACKAGE_MAINTAINER "Charles J. Cliffe <cj@cubicproductions.com>")
|
|
|
|
SET(CPACK_DEBIAN_PACKAGE_DESCRIPTION "CubicSDR Software Defined Radio application v${CUBICSDR_VERSION}")
|
|
|
|
SET(CPACK_DEBIAN_PACKAGE_SECTION "comm")
|
|
|
|
SET(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/LICENSE")
|
|
|
|
SET(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}-${EX_PLATFORM_NAME}")
|
|
|
|
|
|
|
|
ADD_DEFINITIONS(
|
|
|
|
-DRES_FOLDER="/usr/share/cubicsdr/"
|
|
|
|
-D_FORTIFY_SOURCE=2
|
|
|
|
)
|
|
|
|
|
|
|
|
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,-z,relro")
|
|
|
|
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,-z,relro")
|
|
|
|
|
|
|
|
CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/external/deb/deb_post.sh.in" "${CMAKE_CURRENT_BINARY_DIR}/deb_post.sh" @ONLY IMMEDIATE)
|
|
|
|
|
|
|
|
INSTALL(TARGETS CubicSDR DESTINATION bin)
|
|
|
|
install(FILES
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48.fnt
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono12_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono16_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono18_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono24_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono32_0.png
|
|
|
|
${PROJECT_SOURCE_DIR}/font/vera_sans_mono48_0.png
|
2015-07-26 19:47:43 -04:00
|
|
|
${PROJECT_SOURCE_DIR}/src/CubicSDR.png
|
2015-03-08 20:17:19 -04:00
|
|
|
DESTINATION share/cubicsdr)
|
2015-07-26 19:47:43 -04:00
|
|
|
INSTALL(FILES CubicSDR.desktop
|
|
|
|
DESTINATION share/applications)
|
2015-03-08 20:17:19 -04:00
|
|
|
INCLUDE(CPack)
|
|
|
|
ENDIF (UNIX AND BUILD_DEB)
|