nod/lib/CMakeLists.txt

55 lines
1.2 KiB
CMake
Raw Normal View History

2016-03-04 23:04:30 +00:00
add_library(nod
aes.cpp
sha1.c
DirectoryEnumerator.cpp
DiscBase.cpp
DiscGCN.cpp
DiscIOISO.cpp
2019-11-24 03:24:33 +00:00
DiscIONFS.cpp
DiscIOWBFS.cpp
DiscWii.cpp
nod.cpp
OSUTF.c
Util.cpp
../include/nod/aes.hpp
../include/nod/DirectoryEnumerator.hpp
../include/nod/DiscBase.hpp
../include/nod/DiscGCN.hpp
../include/nod/DiscWii.hpp
../include/nod/IDiscIO.hpp
../include/nod/IFileIO.hpp
../include/nod/nod.hpp
../include/nod/OSUTF.h
../include/nod/sha1.h
../include/nod/Util.hpp
)
target_include_directories(nod PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/../include>
)
target_link_libraries(nod PUBLIC $<BUILD_INTERFACE:logvisor>)
if(WIN32)
target_sources(nod PRIVATE FileIOWin32.cpp)
else()
target_compile_options(nod PRIVATE -Wno-multichar)
target_sources(nod PRIVATE FileIOFILE.cpp)
endif()
if(NOT MSVC AND ${CMAKE_SYSTEM_PROCESSOR} STREQUAL x86_64)
set_source_files_properties(aes.cpp PROPERTIES COMPILE_FLAGS -maes)
2015-07-22 19:01:28 +00:00
endif()
# Associate target with export
install(
TARGETS nod
EXPORT nodTargets
ARCHIVE DESTINATION "lib"
INCLUDES DESTINATION include # This sets the INTERFACE_INCLUDE_DIRECTORIES property of the target.
)
install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/../include/nod DESTINATION include)