From 61181f2c49b823f691b42c6de63a5f9f130e18d6 Mon Sep 17 00:00:00 2001 From: myd7349 Date: Fri, 5 Apr 2019 10:56:47 +0800 Subject: Fix CMake support on Win32 --- src/CMakeLists.txt | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index c65a4996..c24853a1 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -188,6 +188,11 @@ if(SHARED) PUBLIC ${GRAPHICS} ) + target_compile_definitions(raylib + PRIVATE $ + INTERFACE $ + ) + set(PKG_CONFIG_LIBS_EXTRA "") set_property(TARGET raylib PROPERTY POSITION_INDEPENDENT_CODE ON) @@ -214,7 +219,9 @@ if(SHARED) if (WIN32) install( TARGETS raylib - RUNTIME DESTINATION "lib" + ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" + LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" PUBLIC_HEADER DESTINATION "include" ) else() -- cgit v1.2.3 From 148eefb9bb67a4b72bb90ea9a740db3cc3c081d3 Mon Sep 17 00:00:00 2001 From: myd7349 Date: Tue, 9 Apr 2019 20:41:40 +0800 Subject: Resolve CI failure with MinGW --- src/CMakeLists.txt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index c24853a1..7b69e0f9 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -188,10 +188,12 @@ if(SHARED) PUBLIC ${GRAPHICS} ) - target_compile_definitions(raylib + if(MSVC) + target_compile_definitions(raylib PRIVATE $ INTERFACE $ - ) + ) + endif() set(PKG_CONFIG_LIBS_EXTRA "") -- cgit v1.2.3