Skip to content

Commit

Permalink
Merge pull request #533 from davidonete/upstream-playerbots
Browse files Browse the repository at this point in the history
Upstream playerbots
  • Loading branch information
davidonete authored Mar 5, 2024
2 parents 7e77a0d + aedaa1c commit 469e3dd
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
12 changes: 6 additions & 6 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ if(BUILD_PLAYERBOTS)
include(FetchContent)

FetchContent_Declare(
PlayerBots
SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/modules/PlayerBots"
playerbots
SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/modules/playerbots"
GIT_REPOSITORY "https://github.com/cmangos/playerbots.git"
GIT_TAG "master"
)

FetchContent_GetProperties(PlayerBots)
FetchContent_GetProperties(playerbots)
if (NOT playerbots_POPULATED)
FetchContent_Populate(PlayerBots)
FetchContent_Populate(playerbots)
message(STATUS "Playerbots module source dir: ${playerbots_SOURCE_DIR}")
else()
message(STATUS "Playerbots module already populated: ${playerbots_POPULATED}")
Expand All @@ -48,8 +48,8 @@ if(BUILD_PLAYERBOTS)
add_subdirectory(${playerbots_SOURCE_DIR})

else()
# if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/modules/PlayerBots)
# file(REMOVE_RECURSE ${CMAKE_CURRENT_SOURCE_DIR}/modules/PlayerBots)
# if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/modules/playerbots)
# file(REMOVE_RECURSE ${CMAKE_CURRENT_SOURCE_DIR}/modules/playerbots)
# endif()
endif()

Expand Down
4 changes: 2 additions & 2 deletions src/game/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ endif()

if(NOT BUILD_PLAYERBOTS)
# exclude Playerbots folder
set (EXCLUDE_DIR "Bots/")
set (EXCLUDE_DIR "playerbots/")
foreach (TMP_PATH ${LIBRARY_SRCS})
string (FIND ${TMP_PATH} ${EXCLUDE_DIR} EXCLUDE_DIR_FOUND)
if (NOT ${EXCLUDE_DIR_FOUND} EQUAL -1)
Expand Down Expand Up @@ -125,7 +125,7 @@ target_include_directories(${LIBRARY_NAME}

if(BUILD_PLAYERBOTS)
target_link_libraries(${LIBRARY_NAME} PUBLIC playerbots)
target_include_directories(${LIBRARY_NAME} PUBLIC ${CMAKE_SOURCE_DIR}/src/modules/PlayerBots)
target_include_directories(${LIBRARY_NAME} PUBLIC ${CMAKE_SOURCE_DIR}/src/modules/playerbots)
add_dependencies(${LIBRARY_NAME} playerbots)
endif()

Expand Down
1 change: 1 addition & 0 deletions src/realmd/RealmList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "Util/Util.h" // for Tokens typedef
#include "Policies/Singleton.h"
#include "Database/DatabaseEnv.h"
#include "Log/Log.h"

INSTANTIATE_SINGLETON_1(RealmList);

Expand Down

0 comments on commit 469e3dd

Please sign in to comment.