don't build barrierd for non-windows platforms; removed some synergy-related legacy checks

This commit is contained in:
walker0643 2018-03-11 12:48:59 -04:00
parent ed05dc2b2e
commit b9a59c014f
7 changed files with 17 additions and 34 deletions

View File

@ -18,9 +18,8 @@
cmake_minimum_required (VERSION 3.4) cmake_minimum_required (VERSION 3.4)
project (barrier C CXX) project (barrier C CXX)
option (BARRIER_BUILD_LEGACY_GUI "Build the legacy GUI" ON) option (BARRIER_BUILD_GUI "Build the GUI" ON)
option (BARRIER_BUILD_LEGACY_SERVICE "Build the legacy service (barrierd)" ON) option (BARRIER_BUILD_INSTALLER "Build the installer" ON)
option (BARRIER_BUILD_LEGACY_INSTALLER "Build the legacy installer" ON)
set (CMAKE_CXX_STANDARD 14) set (CMAKE_CXX_STANDARD 14)
set (CMAKE_CXX_EXTENSIONS OFF) set (CMAKE_CXX_EXTENSIONS OFF)
@ -355,7 +354,7 @@ macro (configure_files srcDir destDir)
endforeach (templateFile) endforeach (templateFile)
endmacro (configure_files) endmacro (configure_files)
if (${BARRIER_BUILD_LEGACY_INSTALLER}) if (${BARRIER_BUILD_INSTALLER})
# #
# macOS app Bundle # macOS app Bundle
# #
@ -393,6 +392,6 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
endif() endif()
else() else()
message (STATUS "NOT configuring the v1 installer") message (STATUS "NOT configuring the installer")
endif() endif()
add_subdirectory (src) add_subdirectory (src)

View File

@ -31,12 +31,6 @@
<Property Id="ARPPRODUCTICON" Value="barrier.ico"/> <Property Id="ARPPRODUCTICON" Value="barrier.ico"/>
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER"/> <Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER"/>
<Property Id="MSIRESTARTMANAGERCONTROL" Value="Disable"/> <Property Id="MSIRESTARTMANAGERCONTROL" Value="Disable"/>
<Property Id="LEGACY_UNINSTALL_EXISTS">
<RegistrySearch Id="LegacyRegistrySearch" Key="SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\Barrier" Name="UninstallString" Root="HKLM" Type="file" Win64="no">
<FileSearch Id="LegacyFileSearch" Name="uninstall.exe"/>
</RegistrySearch>
</Property>
<Condition Message="An existing installation of $(var.Name) was detected, please uninstall it before continuing.">NOT LEGACY_UNINSTALL_EXISTS
</Condition> </Condition>
<CustomAction ExeCommand="" FileKey="GuiProgram" Id="StartGui" Return="asyncNoWait"/> <CustomAction ExeCommand="" FileKey="GuiProgram" Id="StartGui" Return="asyncNoWait"/>
<UI> <UI>

View File

@ -19,6 +19,7 @@ include_directories (${CMAKE_CURRENT_BINARY_DIR}/lib)
add_subdirectory(lib) add_subdirectory(lib)
add_subdirectory(cmd) add_subdirectory(cmd)
if (BARRIER_BUILD_LEGACY_GUI)
if (BARRIER_BUILD_GUI)
add_subdirectory(gui) add_subdirectory(gui)
endif (BARRIER_BUILD_LEGACY_GUI) endif()

View File

@ -18,7 +18,7 @@ add_subdirectory(barrierc)
add_subdirectory(barriers) add_subdirectory(barriers)
add_subdirectory(syntool) add_subdirectory(syntool)
if (BARRIER_BUILD_LEGACY_SERVICE) if (WIN32)
add_subdirectory(barrierd) add_subdirectory(barrierd)
endif (BARRIER_BUILD_LEGACY_SERVICE) endif()

View File

@ -6,17 +6,17 @@ set (CMAKE_AUTORCC ON)
set (CMAKE_AUTOUIC ON) set (CMAKE_AUTOUIC ON)
set (CMAKE_INCLUDE_CURRENT_DIR ON) set (CMAKE_INCLUDE_CURRENT_DIR ON)
file (GLOB LEGACY_GUI_SOURCE_FILES src/*.cpp src/*.h) file (GLOB GUI_SOURCE_FILES src/*.cpp src/*.h)
file (GLOB LEGACY_GUI_UI_FILES src/*.ui) file (GLOB GUI_UI_FILES src/*.ui)
if (WIN32) if (WIN32)
set (LEGACY_GUI_RC_FILES res/win/Barrier.rc) set (GUI_RC_FILES res/win/Barrier.rc)
endif() endif()
add_executable (barrier WIN32 add_executable (barrier WIN32
${LEGACY_GUI_SOURCE_FILES} ${GUI_SOURCE_FILES}
${LEGACY_GUI_UI_FILES} ${GUI_UI_FILES}
${LEGACY_GUI_RC_FILES} ${GUI_RC_FILES}
res/Barrier.qrc res/Barrier.qrc
) )

View File

@ -697,15 +697,7 @@ ArchDaemonWindows::installDaemon()
void void
ArchDaemonWindows::uninstallDaemon() ArchDaemonWindows::uninstallDaemon()
{ {
// remove legacy services if installed. // remove service if installed.
if (isDaemonInstalled(LEGACY_SERVER_DAEMON_NAME)) {
uninstallDaemon(LEGACY_SERVER_DAEMON_NAME);
}
if (isDaemonInstalled(LEGACY_CLIENT_DAEMON_NAME)) {
uninstallDaemon(LEGACY_CLIENT_DAEMON_NAME);
}
// remove new service if installed.
if (isDaemonInstalled(DEFAULT_DAEMON_NAME)) { if (isDaemonInstalled(DEFAULT_DAEMON_NAME)) {
uninstallDaemon(DEFAULT_DAEMON_NAME); uninstallDaemon(DEFAULT_DAEMON_NAME);
} }

View File

@ -142,9 +142,6 @@ private:
#define DEFAULT_DAEMON_NAME _T("Barrier") #define DEFAULT_DAEMON_NAME _T("Barrier")
#define DEFAULT_DAEMON_INFO _T("Manages the Barrier foreground processes.") #define DEFAULT_DAEMON_INFO _T("Manages the Barrier foreground processes.")
#define LEGACY_SERVER_DAEMON_NAME _T("Barrier Server")
#define LEGACY_CLIENT_DAEMON_NAME _T("Barrier Client")
static const TCHAR* const g_daemonKeyPath[] = { static const TCHAR* const g_daemonKeyPath[] = {
_T("SOFTWARE"), _T("SOFTWARE"),
_T("The Barrier Project"), _T("The Barrier Project"),