mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2025-07-07 16:25:01 +03:00
CMake: build targets with versioning info on Windows
This commit is contained in:
@ -1,10 +1,7 @@
|
||||
set(VPNCLIENT_SOURCES vpncsvc.c vpncsvc.h)
|
||||
set(COMPONENT_NAME "Client")
|
||||
set(COMPONENT_INTERNAL_NAME "vpnclient")
|
||||
|
||||
if(WIN32)
|
||||
set(VPNCLIENT_SOURCES ${VPNCLIENT_SOURCES} vpnclient.rc)
|
||||
endif()
|
||||
|
||||
add_executable(vpnclient ${VPNCLIENT_SOURCES})
|
||||
add_executable(vpnclient vpncsvc.c vpncsvc.h)
|
||||
|
||||
set_target_properties(vpnclient
|
||||
PROPERTIES
|
||||
@ -18,6 +15,12 @@ if(WIN32)
|
||||
PROPERTIES
|
||||
PDB_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
)
|
||||
|
||||
get_filename_component(COMPONENT_FILE_NAME vpnclient NAME)
|
||||
set(COMPONENT_FILE_NAME "${COMPONENT_FILE_NAME}.exe")
|
||||
|
||||
configure_file("${TOP_DIRECTORY}/src/BuildFiles/VerScript/ver.rc" "${CMAKE_BINARY_DIR}/VerScript/vpnclient.rc")
|
||||
target_sources(vpnclient PRIVATE vpnclient.rc "${CMAKE_BINARY_DIR}/VerScript/vpnclient.rc")
|
||||
endif()
|
||||
|
||||
target_link_libraries(vpnclient cedar mayaqua)
|
||||
|
Reference in New Issue
Block a user