Imported external libraries
This commit is contained in:
parent
4b88be8299
commit
0bd2c64f73
@ -15,6 +15,17 @@ if(DEFINED ENV{MS_COMPATIBLE})
|
||||
endif()
|
||||
|
||||
|
||||
# Import needed packages and references their include path
|
||||
find_package(RSPModel 2.2 REQUIRED)
|
||||
include_directories(${RSPModel_INCLUDE_DIR})
|
||||
find_package(RSPTerrain 2.0 REQUIRED)
|
||||
include_directories(${RSPTerrain_INCLUDE_DIR})
|
||||
find_package(RSPTexture 2.1 REQUIRED)
|
||||
include_directories(${RSPTexture_INCLUDE_DIR})
|
||||
find_package(Boost 1.80.0 EXACT REQUIRED)
|
||||
include_directories(${Boost_INCLUDE_DIR})
|
||||
|
||||
|
||||
# Project definition
|
||||
if(DEFINED ENV{CI}) # Jenkins CI integration mode
|
||||
project(rdi VERSION $ENV{CI_VERSION}.$ENV{CI_BUILD_NUMBER} DESCRIPTION "Rogue Data Interface" LANGUAGES C CXX)
|
||||
@ -72,6 +83,13 @@ if(RDI_SHARED)
|
||||
|
||||
set_target_properties(rdi-lib PROPERTIES OUTPUT_NAME "${RDI_LIB_NAME}")
|
||||
|
||||
target_link_libraries(rdi-lib PRIVATE
|
||||
${RSPModel_LIBRARIES}
|
||||
${RSPTerrain_LIBRARIES}
|
||||
${RSPTexture_LIBRARIES}
|
||||
${Boost_LIBRARIES}
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
# remove lib prefix on windows system when building dll file
|
||||
set_target_properties(rdi-lib PROPERTIES PREFIX "")
|
||||
@ -95,6 +113,13 @@ if(RDI_STATIC)
|
||||
|
||||
target_include_directories(rdi-libstatic PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include)
|
||||
|
||||
target_link_libraries(rdi-libstatic PRIVATE
|
||||
${RSPModel_LIBRARIES}
|
||||
${RSPTerrain_LIBRARIES}
|
||||
${RSPTexture_LIBRARIES}
|
||||
${Boost_LIBRARIES}
|
||||
)
|
||||
|
||||
list(APPEND RDI_TARGETS_LIST rdi-libstatic)
|
||||
|
||||
# MSVC doesn't use a different file extension for shared vs. static
|
||||
|
@ -1,16 +1,14 @@
|
||||
[requires]
|
||||
zlib/1.2.12
|
||||
libpng/1.6.37
|
||||
rspmodellib/2.0.0
|
||||
rspmodellib/2.2.0
|
||||
rspterrainlib/2.0.4
|
||||
rsptexturelib/2.1.0
|
||||
boost/1.80.0
|
||||
|
||||
[generators]
|
||||
cmake
|
||||
cmake_find_package
|
||||
|
||||
[options]
|
||||
libpng:shared=True
|
||||
|
||||
[imports]
|
||||
bin, *.dll -> ./bin
|
@ -10,6 +10,10 @@
|
||||
#include <stdlib.h>
|
||||
#include <iostream>
|
||||
#include <fstream>
|
||||
#include <boost/filesystem.hpp>
|
||||
#include <RSPModel.h>
|
||||
#include <RSPTerrain.h>
|
||||
#include <RSPTexture.h>
|
||||
#include "data_struct.h"
|
||||
#include "RDat.h"
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user