diff --git a/dCommon/CMakeLists.txt b/dCommon/CMakeLists.txt index 13ffc6c97..1354c051b 100644 --- a/dCommon/CMakeLists.txt +++ b/dCommon/CMakeLists.txt @@ -31,12 +31,6 @@ add_library(dCommon STATIC ${DCOMMON_SOURCES}) target_link_libraries(dCommon bcrypt dDatabase tinyxml2) -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DCOMMON_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() - -# Handle zlib dependency if (UNIX) find_package(ZLIB REQUIRED) elseif (WIN32) diff --git a/dDatabase/CMakeLists.txt b/dDatabase/CMakeLists.txt index 8bdcea341..20f37becf 100644 --- a/dDatabase/CMakeLists.txt +++ b/dDatabase/CMakeLists.txt @@ -14,8 +14,3 @@ endforeach() add_library(dDatabase STATIC ${DDATABASE_SOURCES}) target_link_libraries(dDatabase sqlite3 mariadbConnCpp) - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DDATABASE_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dGame/CMakeLists.txt b/dGame/CMakeLists.txt index 59588b4ab..80f160426 100644 --- a/dGame/CMakeLists.txt +++ b/dGame/CMakeLists.txt @@ -63,8 +63,3 @@ endforeach() add_library(dGame STATIC ${DGAME_SOURCES}) target_link_libraries(dGame dDatabase Recast Detour) - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DGAME_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dMasterServer/CMakeLists.txt b/dMasterServer/CMakeLists.txt index ddba5c49a..2161681f8 100644 --- a/dMasterServer/CMakeLists.txt +++ b/dMasterServer/CMakeLists.txt @@ -12,8 +12,3 @@ target_link_libraries(MasterServer ${COMMON_LIBRARIES} dMasterServer) if(WIN32) add_dependencies(MasterServer WorldServer AuthServer ChatServer) endif() - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DMASTERSERVER_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dNavigation/CMakeLists.txt b/dNavigation/CMakeLists.txt index f94ae4932..4c03d24b2 100644 --- a/dNavigation/CMakeLists.txt +++ b/dNavigation/CMakeLists.txt @@ -8,8 +8,3 @@ endforeach() add_library(dNavigation STATIC ${DNAVIGATION_SOURCES}) target_link_libraries(dNavigation Detour Recast) - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DNAVIGATION_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dNet/CMakeLists.txt b/dNet/CMakeLists.txt index 6fb830361..938c04493 100644 --- a/dNet/CMakeLists.txt +++ b/dNet/CMakeLists.txt @@ -9,8 +9,3 @@ set(DNET_SOURCES "AuthPackets.cpp" add_library(dNet STATIC ${DNET_SOURCES}) target_link_libraries(dNet dCommon dDatabase) - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DNET_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dPhysics/CMakeLists.txt b/dPhysics/CMakeLists.txt index 0db387821..5fe6adaae 100644 --- a/dPhysics/CMakeLists.txt +++ b/dPhysics/CMakeLists.txt @@ -8,8 +8,3 @@ set(DPHYSICS_SOURCES "dpCollisionChecks.cpp" add_library(dPhysics STATIC ${DPHYSICS_SOURCES}) target_link_libraries(dPhysics Recast Detour) - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DPHYSICS_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dScripts/CMakeLists.txt b/dScripts/CMakeLists.txt index a1d5ed44e..ac600dbc2 100644 --- a/dScripts/CMakeLists.txt +++ b/dScripts/CMakeLists.txt @@ -52,8 +52,3 @@ foreach(file ${DSCRIPTS_SOURCES_ZONE}) endforeach() set(DSCRIPTS_SOURCES ${DSCRIPTS_SOURCES} PARENT_SCOPE) - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DSCRIPTS_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dWorldServer/CMakeLists.txt b/dWorldServer/CMakeLists.txt index f227fbd4a..c616da878 100644 --- a/dWorldServer/CMakeLists.txt +++ b/dWorldServer/CMakeLists.txt @@ -9,7 +9,3 @@ add_executable(WorldServer "WorldServer.cpp") target_link_libraries(dWorldServer ${COMMON_LIBRARIES}) target_link_libraries(WorldServer ${COMMON_LIBRARIES} dChatFilter dGame dZoneManager dPhysics Detour Recast tinyxml2 dWorldServer dNavigation) -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DWORLDSERVER_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif() diff --git a/dZoneManager/CMakeLists.txt b/dZoneManager/CMakeLists.txt index cbddc4f3e..bbb22ba7d 100644 --- a/dZoneManager/CMakeLists.txt +++ b/dZoneManager/CMakeLists.txt @@ -5,8 +5,3 @@ set(DZONEMANAGER_SOURCES "dZoneManager.cpp" add_library(dZoneManager STATIC ${DZONEMANAGER_SOURCES}) target_link_libraries(dZoneManager dPhysics) - -# If using gcc, warn on old-style C casts -if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") - set_source_files_properties(${DZONEMANAGER_SOURCES} PROPERTIES COMPILE_FLAGS "-Wold-style-cast") -endif()