Skip to content

Commit

Permalink
Core/Common: Generalize platform specific includes in common/Platform
Browse files Browse the repository at this point in the history
  • Loading branch information
Naios committed Mar 11, 2016
1 parent 5c91586 commit 30517cb
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 11 deletions.
Expand Up @@ -261,4 +261,3 @@ bool WinServiceRun()
return true;
}
#endif

Expand Up @@ -26,4 +26,3 @@ bool WinServiceRun();

#endif // _WIN32_SERVICE_
#endif // _WIN32

12 changes: 8 additions & 4 deletions src/server/CMakeLists.txt
Expand Up @@ -16,11 +16,15 @@ if(CMAKE_COMPILER_IS_GNUCXX AND NOT MINGW)
add_definitions(-fno-delete-null-pointer-checks)
endif()

if(WIN32)
set(sources_windows
${CMAKE_SOURCE_DIR}/src/common/Debugging/WheatyExceptionReport.cpp
${CMAKE_SOURCE_DIR}/src/common/Debugging/WheatyExceptionReport.h
${CMAKE_SOURCE_DIR}/src/common/Platform/ServiceWin32.cpp
${CMAKE_SOURCE_DIR}/src/common/Platform/ServiceWin32.h
)
endif(WIN32)

set(sources_windows_Debugging
${CMAKE_SOURCE_DIR}/src/common/Debugging/WheatyExceptionReport.cpp
${CMAKE_SOURCE_DIR}/src/common/Debugging/WheatyExceptionReport.h
)
add_subdirectory(database)
add_subdirectory(shared)
add_subdirectory(game)
Expand Down
3 changes: 2 additions & 1 deletion src/server/bnetserver/CMakeLists.txt
Expand Up @@ -33,7 +33,7 @@ set(bnetserver_SRCS
if( WIN32 )
set(bnetserver_SRCS
${bnetserver_SRCS}
${sources_windows_Debugging}
${sources_windows}
)
if ( MSVC )
set(bnetserver_SRCS
Expand All @@ -59,6 +59,7 @@ include_directories(
${CMAKE_SOURCE_DIR}/src/common/Logging
${CMAKE_SOURCE_DIR}/src/common/Threading
${CMAKE_SOURCE_DIR}/src/common/Utilities
${CMAKE_SOURCE_DIR}/src/common/Platform
${CMAKE_SOURCE_DIR}/src/server/database
${CMAKE_SOURCE_DIR}/src/server/database/Database
${CMAKE_SOURCE_DIR}/src/server/database/Logging
Expand Down
3 changes: 0 additions & 3 deletions src/server/shared/CMakeLists.txt
Expand Up @@ -18,9 +18,6 @@ file(GLOB_RECURSE sources_Dynamic Dynamic/*.cpp Dynamic/*.h)
file(GLOB_RECURSE sources_Networking Networking/*.cpp Networking/*.h)
file(GLOB_RECURSE sources_Packets Packets/*.cpp Packets/*.h)
file(GLOB_RECURSE sources_Realm Realm/*.cpp Realm/*.h)
if(WIN32)
file(GLOB_RECURSE sources_Service Service/*.cpp Service/*.h)
endif(WIN32)

file(GLOB sources_localdir *.cpp *.h)

Expand Down
3 changes: 2 additions & 1 deletion src/server/worldserver/CMakeLists.txt
Expand Up @@ -29,7 +29,7 @@ set(worldserver_SRCS
if( WIN32 )
set(worldserver_SRCS
${worldserver_SRCS}
${sources_windows_Debugging}
${sources_windows}
)
if ( MSVC )
set(worldserver_SRCS
Expand Down Expand Up @@ -60,6 +60,7 @@ include_directories(
${CMAKE_SOURCE_DIR}/src/common/Logging
${CMAKE_SOURCE_DIR}/src/common/Threading
${CMAKE_SOURCE_DIR}/src/common/Utilities
${CMAKE_SOURCE_DIR}/src/common/Platform
${CMAKE_SOURCE_DIR}/src/server/authserver/Realms
${CMAKE_SOURCE_DIR}/src/server/database/
${CMAKE_SOURCE_DIR}/src/server/database/Database
Expand Down

0 comments on commit 30517cb

Please sign in to comment.