2020-06-10 04:13:56 +02:00
|
|
|
cmake_minimum_required(VERSION 3.9)
|
|
|
|
project(sdrpp)
|
|
|
|
|
2020-07-09 16:02:58 +02:00
|
|
|
set(CMAKE_BUILD_TYPE "RelWithDebInfo")
|
|
|
|
|
2020-06-10 04:13:56 +02:00
|
|
|
# Compiler config
|
2020-06-22 16:45:57 +02:00
|
|
|
set(CMAKE_CXX_FLAGS "-O2 /std:c++17")
|
2020-06-10 04:13:56 +02:00
|
|
|
|
2020-07-19 21:26:37 +02:00
|
|
|
# PothosSDR
|
|
|
|
link_directories(sdrpp "C:/Program Files/PothosSDR/lib/")
|
|
|
|
|
2020-06-22 16:45:57 +02:00
|
|
|
# Volk
|
|
|
|
include_directories(sdrpp "C:/Program Files/PothosSDR/include/volk/")
|
|
|
|
link_libraries(volk)
|
|
|
|
|
|
|
|
# SoapySDR
|
|
|
|
include_directories(sdrpp "C:/Program Files/PothosSDR/include/")
|
|
|
|
link_libraries(SoapySDR)
|
|
|
|
|
2020-06-10 04:13:56 +02:00
|
|
|
# Main code
|
|
|
|
include_directories(sdrpp "src/")
|
|
|
|
include_directories(sdrpp "src/imgui")
|
|
|
|
file(GLOB SRC "src/*.cpp")
|
|
|
|
file(GLOB IMGUI "src/imgui/*.cpp")
|
|
|
|
add_executable(sdrpp ${SRC} ${IMGUI})
|
|
|
|
|
|
|
|
# Glew
|
|
|
|
find_package(GLEW REQUIRED)
|
|
|
|
target_link_libraries(sdrpp PRIVATE GLEW::GLEW)
|
|
|
|
|
|
|
|
# GLFW3
|
|
|
|
find_package(glfw3 CONFIG REQUIRED)
|
|
|
|
target_link_libraries(sdrpp PRIVATE glfw)
|
|
|
|
|
|
|
|
# FFTW3
|
|
|
|
find_package(FFTW3 CONFIG REQUIRED)
|
|
|
|
target_link_libraries(sdrpp PRIVATE FFTW3::fftw3)
|
|
|
|
find_package(FFTW3f CONFIG REQUIRED)
|
|
|
|
target_link_libraries(sdrpp PRIVATE FFTW3::fftw3f)
|
|
|
|
find_package(FFTW3l CONFIG REQUIRED)
|
2020-06-10 18:52:07 +02:00
|
|
|
target_link_libraries(sdrpp PRIVATE FFTW3::fftw3l)
|
|
|
|
|
|
|
|
# PortAudio
|
|
|
|
find_package(portaudio CONFIG REQUIRED)
|
2020-07-19 15:59:44 +02:00
|
|
|
target_link_libraries(sdrpp PRIVATE portaudio portaudio_static)
|
|
|
|
|
|
|
|
|
|
|
|
# cmake .. "-DCMAKE_TOOLCHAIN_FILE=C:/Users/Alex/vcpkg/scripts/buildsystems/vcpkg.cmake" -G "Visual Studio 15 2017 Win64"
|