build: remove SYSAPI_UNIX define
This commit is contained in:
committed by
Chris Rizzitello
parent
90e79dad75
commit
fce1a37e97
@ -163,9 +163,6 @@ macro(configure_unix_libs)
|
||||
message(WARNING "pkg-config not found, skipping wayland libraries")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_definitions(-DSYSAPI_UNIX=1)
|
||||
|
||||
endmacro()
|
||||
|
||||
#
|
||||
|
||||
@ -157,7 +157,7 @@ int DaemonApp::daemonLoop()
|
||||
#if SYSAPI_WIN32
|
||||
// Runs the daemon through the Windows service controller, which controls the program lifecycle.
|
||||
return ArchDaemonWindows::runDaemon([this]() { return mainLoop(); });
|
||||
#elif SYSAPI_UNIX
|
||||
#else
|
||||
return mainLoop();
|
||||
#endif
|
||||
}
|
||||
|
||||
@ -32,7 +32,7 @@
|
||||
#include "arch/win32/ArchMultithreadWindows.h"
|
||||
#include "arch/win32/ArchNetworkWinsock.h"
|
||||
|
||||
#elif SYSAPI_UNIX
|
||||
#else
|
||||
|
||||
#include "arch/ArchDaemonNone.h"
|
||||
#include "arch/unix/ArchLogUnix.h"
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
|
||||
#if SYSAPI_WIN32
|
||||
#include "deskflow/win32/AppUtilWindows.h"
|
||||
#elif SYSAPI_UNIX
|
||||
#else
|
||||
#include "deskflow/unix/AppUtilUnix.h"
|
||||
#endif
|
||||
|
||||
|
||||
@ -660,7 +660,7 @@ ISocketMultiplexerJob *SecureSocket::serviceConnect(ISocketMultiplexerJob *const
|
||||
int status = 0;
|
||||
#ifdef SYSAPI_WIN32
|
||||
status = secureConnect(static_cast<int>(getSocket()->m_socket));
|
||||
#elif SYSAPI_UNIX
|
||||
#else
|
||||
status = secureConnect(getSocket()->m_fd);
|
||||
#endif
|
||||
|
||||
@ -688,7 +688,7 @@ ISocketMultiplexerJob *SecureSocket::serviceAccept(ISocketMultiplexerJob *const,
|
||||
int status = 0;
|
||||
#ifdef SYSAPI_WIN32
|
||||
status = secureAccept(static_cast<int>(getSocket()->m_socket));
|
||||
#elif SYSAPI_UNIX
|
||||
#else
|
||||
status = secureAccept(getSocket()->m_fd);
|
||||
#endif
|
||||
// If status < 0, error happened
|
||||
|
||||
@ -54,7 +54,7 @@ void TCPListenSocket::bind(const NetworkAddress &addr)
|
||||
try {
|
||||
std::scoped_lock lock{m_mutex};
|
||||
|
||||
#if SYSAPI_UNIX
|
||||
#if defined(Q_OS_UNIX)
|
||||
// Only reuse socket addr on Unix so we can restart the server quickly (Unix holds the port
|
||||
// in TIME_WAIT for a few mins after close). This is not needed on Windows and can cause issues
|
||||
// because binding to a re-use port makes it look like the server is listening when it is not.
|
||||
|
||||
Reference in New Issue
Block a user