-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
41 lines (31 loc) · 1.03 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
cmake_minimum_required(VERSION 3.11)
# Name of the project, also is the name of the file
project(SGD2FreeClassicMenu)
# Define requirements for C
set(CMAKE_C_STANDARD 90)
set(CMAKE_C_STANDARD_REQUIRED ON)
# Enable NASM
set(CMAKE_ASM_NASM_OBJECT_FORMAT win32)
enable_language(ASM_NASM)
# Remove MinGW compiled binary "lib" prefix
if (MINGW)
set(CMAKE_IMPORT_LIBRARY_PREFIX "")
set(CMAKE_SHARED_LIBRARY_PREFIX "")
set(CMAKE_STATIC_LIBRARY_PREFIX "")
endif (MINGW)
add_subdirectory("third_party")
# Output DLL
add_library(${PROJECT_NAME} SHARED)
add_subdirectory("src")
add_subdirectory("include")
add_subdirectory("resource")
target_compile_definitions(${PROJECT_NAME} PRIVATE NOMINMAX)
target_include_directories(${PROJECT_NAME}
PRIVATE
"${CMAKE_SOURCE_DIR}/src"
PUBLIC
"${CMAKE_SOURCE_DIR}/include")
target_link_libraries(${PROJECT_NAME} libSGD2MAPIc libMDCc)
add_dependencies(${PROJECT_NAME} libSGD2MAPIc libMDCc)
# Project source listing
source_group(TREE ${CMAKE_CURRENT_SOURCE_DIR} FILES ${SOURCE_FILES})