Welcome to mirror list, hosted at ThFree Co, Russian Federation.

CMakeLists.txt « ArcWelder - github.com/FormerLurker/ArcWelderLib.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 738983c92c398a958ba7bfb5b515a5115d3481ef (plain)
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
project(ArcWelder C CXX)

# add definitions from the GcodeProcessorLib project
add_definitions(${GcodeProcessorLib_DEFINITIONS})

# Include the GcodeProcessorLib's directories
include_directories(${GcodeProcessorLib_INCLUDE_DIRS})

# include sourcelist.cmake, which contains our source list and exposes it as the
# ArcWelderSources variable
include(sourcelist.cmake)

# Add a library using our ArcWelderSources variable from our sourcelist file
add_library(${PROJECT_NAME} STATIC ${ArcWelderSources})

install(
    TARGETS ${PROJECT_NAME}
    ARCHIVE DESTINATION lib
    LIBRARY DESTINATION lib  # <-- Add this line
    COMPONENT library
)

# Link the GcodeProcessorLib
target_link_libraries(${PROJECT_NAME} GcodeProcessorLib)

# Expose the GcodeProcessorLib's Definitions
set(${PROJECT_NAME}_DEFINITIONS ${GcodeProcessorLib_DEFINITIONS}
    CACHE INTERNAL "${PROJECT_NAME}: Definitions" FORCE)

# Expose both the ArcWelder and GcodeProcessorLib's public includes
set(${PROJECT_NAME}_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/
                                 ${GcodeProcessorLib_INCLUDE_DIRS}
    CACHE INTERNAL "${PROJECT_NAME}: Include Directories" FORCE)