mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2024-11-22 17:39:53 +03:00
Merge PR #1182: CMake: specify "WIN32" for targets that have WinMain(), add manifest for all targets that have it in the MSBuild project
This commit is contained in:
commit
112b4c2c67
@ -1,16 +1,9 @@
|
||||
set(COMPONENT_NAME "Bridge")
|
||||
set(COMPONENT_INTERNAL_NAME "vpnbridge")
|
||||
|
||||
add_executable(vpnbridge vpnbridge.c)
|
||||
|
||||
set_target_properties(vpnbridge
|
||||
PROPERTIES
|
||||
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
LIBRARY_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
RUNTIME_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
add_executable(vpnbridge WIN32 vpnbridge.c)
|
||||
|
||||
set_target_properties(vpnbridge
|
||||
PROPERTIES
|
||||
PDB_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
@ -21,8 +14,23 @@ if(WIN32)
|
||||
|
||||
configure_file("${TOP_DIRECTORY}/src/BuildFiles/VerScript/ver.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
target_sources(vpnbridge PRIVATE "vpnbridge.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
|
||||
if(${COMPILER_ARCHITECTURE} STREQUAL "x64")
|
||||
target_sources(vpnbridge PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x64_user.manifest")
|
||||
else()
|
||||
target_sources(vpnbridge PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x86_user.manifest")
|
||||
endif()
|
||||
else()
|
||||
add_executable(vpnbridge vpnbridge.c)
|
||||
endif()
|
||||
|
||||
set_target_properties(vpnbridge
|
||||
PROPERTIES
|
||||
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
LIBRARY_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
RUNTIME_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
)
|
||||
|
||||
target_link_libraries(vpnbridge cedar mayaqua)
|
||||
|
||||
if(UNIX)
|
||||
|
@ -1,16 +1,9 @@
|
||||
set(COMPONENT_NAME "Client")
|
||||
set(COMPONENT_INTERNAL_NAME "vpnclient")
|
||||
|
||||
add_executable(vpnclient vpncsvc.c vpncsvc.h)
|
||||
|
||||
set_target_properties(vpnclient
|
||||
PROPERTIES
|
||||
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
LIBRARY_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
RUNTIME_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
add_executable(vpnclient WIN32 vpncsvc.c vpncsvc.h)
|
||||
|
||||
set_target_properties(vpnclient
|
||||
PROPERTIES
|
||||
PDB_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
@ -21,8 +14,23 @@ if(WIN32)
|
||||
|
||||
configure_file("${TOP_DIRECTORY}/src/BuildFiles/VerScript/ver.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
target_sources(vpnclient PRIVATE "vpnclient.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
|
||||
if(${COMPILER_ARCHITECTURE} STREQUAL "x64")
|
||||
target_sources(vpnclient PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x64_user.manifest")
|
||||
else()
|
||||
target_sources(vpnclient PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x86_user.manifest")
|
||||
endif()
|
||||
else()
|
||||
add_executable(vpnclient vpncsvc.c vpncsvc.h)
|
||||
endif()
|
||||
|
||||
set_target_properties(vpnclient
|
||||
PROPERTIES
|
||||
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
LIBRARY_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
RUNTIME_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
)
|
||||
|
||||
target_link_libraries(vpnclient cedar mayaqua)
|
||||
|
||||
if(UNIX)
|
||||
|
@ -21,6 +21,12 @@ if(WIN32)
|
||||
|
||||
configure_file("${TOP_DIRECTORY}/src/BuildFiles/VerScript/ver.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
target_sources(vpncmd PRIVATE "vpncmd.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
|
||||
if(${COMPILER_ARCHITECTURE} STREQUAL "x64")
|
||||
target_sources(vpncmd PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x64_user.manifest")
|
||||
else()
|
||||
target_sources(vpncmd PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x86_user.manifest")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
target_link_libraries(vpncmd cedar mayaqua)
|
||||
|
@ -1,16 +1,9 @@
|
||||
set(COMPONENT_NAME "Server")
|
||||
set(COMPONENT_INTERNAL_NAME "vpnserver")
|
||||
|
||||
add_executable(vpnserver vpnserver.c)
|
||||
|
||||
set_target_properties(vpnserver
|
||||
PROPERTIES
|
||||
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
LIBRARY_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
RUNTIME_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
)
|
||||
|
||||
if(WIN32)
|
||||
add_executable(vpnserver WIN32 vpnserver.c)
|
||||
|
||||
set_target_properties(vpnserver
|
||||
PROPERTIES
|
||||
PDB_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
@ -21,8 +14,23 @@ if(WIN32)
|
||||
|
||||
configure_file("${TOP_DIRECTORY}/src/BuildFiles/VerScript/ver.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
target_sources(vpnserver PRIVATE "vpnserver.rc" "${CMAKE_CURRENT_BINARY_DIR}/ver.rc")
|
||||
|
||||
if(${COMPILER_ARCHITECTURE} STREQUAL "x64")
|
||||
target_sources(vpnserver PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x64_user.manifest")
|
||||
else()
|
||||
target_sources(vpnserver PRIVATE "${TOP_DIRECTORY}/src/BuildFiles/Manifests/x86_user.manifest")
|
||||
endif()
|
||||
else()
|
||||
add_executable(vpnserver vpnserver.c)
|
||||
endif()
|
||||
|
||||
set_target_properties(vpnserver
|
||||
PROPERTIES
|
||||
ARCHIVE_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
LIBRARY_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
RUNTIME_OUTPUT_DIRECTORY "${BUILD_DIRECTORY}"
|
||||
)
|
||||
|
||||
target_link_libraries(vpnserver cedar mayaqua)
|
||||
|
||||
if(UNIX)
|
||||
|
Loading…
Reference in New Issue
Block a user