Commit 1cda776e authored by deuce's avatar deuce
Browse files

Attempt to use the "system" xpdev, and fall back to the one in the magical

path only if needed.
parent ed2de923
...@@ -2,12 +2,12 @@ project (ConIOLib C) ...@@ -2,12 +2,12 @@ project (ConIOLib C)
cmake_minimum_required(VERSION 2.8.11) cmake_minimum_required(VERSION 2.8.11)
INCLUDE(../build/SynchronetMacros.cmake)
INCLUDE (CheckFunctionExists) INCLUDE (CheckFunctionExists)
INCLUDE (FindSDL) INCLUDE (FindSDL)
INCLUDE (FindX11) INCLUDE (FindX11)
INCLUDE (FindCurses) INCLUDE (FindCurses)
INCLUDE (FindThreads) INCLUDE (FindThreads)
find_package(XPDev QUIET CONFIG PATHS lib/cmake/XPDev)
set(SOURCE set(SOURCE
ansi_cio.c ansi_cio.c
...@@ -50,7 +50,12 @@ if(NEED_BITMAP) ...@@ -50,7 +50,12 @@ if(NEED_BITMAP)
endif() endif()
add_library(ciolib SHARED ${SOURCE}) add_library(ciolib SHARED ${SOURCE})
require_lib(ciolib xpdev) if(XPDev_FOUND)
target_link_libraries(ciolib xpdev)
else()
INCLUDE(../build/SynchronetMacros.cmake)
require_lib(ciolib xpdev)
endif()
target_compile_definitions(ciolib PRIVATE CIOLIB_EXPORTS) target_compile_definitions(ciolib PRIVATE CIOLIB_EXPORTS)
target_compile_definitions(ciolib INTERFACE CIOLIB_IMPORTS) target_compile_definitions(ciolib INTERFACE CIOLIB_IMPORTS)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment