Skip to content

Commit

Permalink
remove if cmake_cxx_compiler
Browse files Browse the repository at this point in the history
  • Loading branch information
camila314 committed Jan 16, 2025
1 parent da5d6ac commit f735693
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
cmake_minimum_required(VERSION 3.25 FATAL_ERROR)
project(geode-ipc VERSION 0.1.0 LANGUAGES C CXX)

add_library(${PROJECT_NAME} STATIC src/geode-ipc.c)
target_include_directories(${PROJECT_NAME} PUBLIC include/)

add_library(${PROJECT_NAME} STATIC src/geode-ipc.c src/geode-ipc.cpp)

if(CMAKE_CXX_COMPILER)
target_sources(${PROJECT_NAME} PRIVATE src/geode-ipc.cpp)
target_include_directories(${PROJECT_NAME} PUBLIC include/)

include(CPM.cmake)
CPMAddPackage("gh:geode-sdk/json#main")
include(CPM.cmake)
CPMAddPackage("gh:geode-sdk/json#main")

target_link_libraries(${PROJECT_NAME} PUBLIC mat-json)
endif()
target_link_libraries(${PROJECT_NAME} PUBLIC mat-json)

if(APPLE)
target_link_libraries(${PROJECT_NAME} PRIVATE "-framework Foundation")
Expand Down

0 comments on commit f735693

Please sign in to comment.