build(cmd/deskflowc): Explicit Sources

This commit is contained in:
sithlord48 2024-10-23 21:17:57 -04:00 committed by Chris Rizzitello
parent 1b13c843aa
commit 04d6895990

View file

@ -1,4 +1,5 @@
# Deskflow -- mouse and keyboard sharing utility # Deskflow -- mouse and keyboard sharing utility
# Copyright (C) 2024 Chris Rizzitello <sithlord48@gmail.com>
# Copyright (C) 2012-2024 Symless Ltd. # Copyright (C) 2012-2024 Symless Ltd.
# Copyright (C) 2009-2012 Nick Bolton # Copyright (C) 2009-2012 Nick Bolton
# #
@ -16,39 +17,35 @@
set(client_source_name "deskflowc") set(client_source_name "deskflowc")
set(target ${CLIENT_BINARY_NAME}) set(target ${CLIENT_BINARY_NAME})
set(sources ${client_source_name}.cpp)
if(WIN32) if(WIN32)
file(GLOB arch_headers "MSWindows*.h") set(PLATFORM_SOURCES
file(GLOB arch_sources "MSWindows*.cpp") ${client_source_name}.exe.manifest
list(
APPEND
sources
resource.h
${client_source_name}.ico ${client_source_name}.ico
${client_source_name}.rc ${client_source_name}.rc
MSWindowsClientTaskBarReceiver.cpp
MSWindowsClientTaskBarReceiver.h
resource.h
tb_error.ico tb_error.ico
tb_idle.ico tb_idle.ico
tb_run.ico tb_run.ico
tb_wait.ico tb_wait.ico
${client_source_name}.exe.manifest ${PROJECT_BINARY_DIR}/src/version.rc
${PROJECT_BINARY_DIR}/src/version.rc) )
elseif(APPLE) elseif(APPLE)
file(GLOB arch_headers "OSX*.h") set(PLATFORM_SOURCES
file(GLOB arch_sources "OSX*.cpp") OSXClientTaskBarReceiver.cpp
OSXClientTaskBarReceiver.h
)
elseif(UNIX) elseif(UNIX)
file(GLOB arch_headers "XWindows*.h") set(PLATFORM_SOURCES
file(GLOB arch_sources "XWindows*.cpp") XWindowsClientTaskBarReceiver.cpp
XWindowsClientTaskBarReceiver.h
)
endif() endif()
list(APPEND sources ${arch_sources}) add_executable(${target} ${PLATFORM_SOURCES} "${client_source_name}.cpp")
list(APPEND headers ${arch_headers})
if(ADD_HEADERS_TO_SOURCES)
list(APPEND sources ${headers})
endif()
add_executable(${target} ${sources})
target_link_libraries( target_link_libraries(
${target} ${target}
arch arch