using PCH results in:
[ 11%] Building CXX object dep/g3dlite/CMakeFiles/g3dlib.dir/source/Vector3.cpp.o
[ 11%] Building CXX object dep/g3dlite/CMakeFiles/g3dlib.dir/source/Vector4.cpp.o
Linking CXX static library libg3dlib.a
[ 11%] Built target g3dlib
make: *** [all] Error 2
without PCH results in (at -j4):
[ 25%] Building CXX object src/server/scripts/CMakeFiles/scripts.dir/Commands/cs_server.cpp.o
/usr/local/src/.git/TrinityCore/src/server/scripts/Commands/cs_server.cpp: In static member function 'static bool server_commandscript::HandleServerInfoCommand(ChatHandler*, const char*)':
/usr/local/src/.git/TrinityCore/src/server/scripts/Commands/cs_server.cpp:118:33: error: expected ')' before '_BUILD_DIRECTIVE'
make[2]: *** [src/server/scripts/CMakeFiles/scripts.dir/Commands/cs_server.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[ 25%] Building CXX object src/server/game/CMakeFiles/game.dir/DungeonFinding/LFGQueue.cpp.o
make[1]: *** [src/server/scripts/CMakeFiles/scripts.dir/all] Error 2
...
[ 30%] Building CXX object src/server/game/CMakeFiles/game.dir/Handlers/VoiceChatHandler.cpp.o
/usr/local/src/.git/TrinityCore/src/server/game/Handlers/CharacterHandler.cpp: In member function 'void WorldSession::HandlePlayerLogin(LoginQueryHolder*)':
/usr/local/src/.git/TrinityCore/src/server/game/Handlers/CharacterHandler.cpp:851:33: error: expected ')' before '_BUILD_DIRECTIVE'
make[2]: *** [src/server/game/CMakeFiles/game.dir/Handlers/CharacterHandler.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [src/server/game/CMakeFiles/game.dir/all] Error 2
make: *** [all] Error 2
gentoo: gcc-4.6.3, openssl-1.0.1c. ACE-6.0.3 installed systemwide as per How-to:Linux guide.
I've tried using previous versions of cmake/compiler/gcc/settings.cmake for this line
add_definitions(-D_BUILD_DIRECTIVE='"${CMAKE_BUILD_TYPE}"')
but I still get the BUILD_DIRECTIVE error.
cmake command and output:
# cmake /usr/local/src/.git/TrinityCore/ -DPREFIX=/usr/local/games/trinity -DCONF_DIR=/usr/local/etc/trinity -DLIBSDIR=/usr/local/lib64/trinity -DTOOLS=1 -DUSE_SCRIPTPCH=0 -DUSE_COREPCH=0 -DWITH_WARNINGS=1
-- The C compiler identification is GNU 4.6.3
-- The CXX compiler identification is GNU 4.6.3
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detected 64-bit platform
-- UNIX: Using jemalloc
-- UNIX: Configuring uninstall target
-- UNIX: Created uninstall target
-- Found ACE library: /usr/local/lib64/libACE.so
-- Found ACE headers: /usr/local/include
-- Found OpenSSL: /usr/lib64/libssl.so;/usr/lib64/libcrypto.so
-- Using mysql-config: /usr/bin/mysql_config
-- Found MySQL library: /usr/lib64/mysql/libmysqlclient_r.so
-- Found MySQL headers: /usr/include/mysql
-- Found Readline library: /usr/lib64/libreadline.so
-- Include dir is: /usr/include
-- Found ZLIB: /usr/lib64/libz.so (found version "1.2.7")
-- Found BZip2: /usr/lib64/libbz2.so (found version "1.0.6")
-- Looking for BZ2_bzCompressInit in /usr/lib64/libbz2.so
-- Looking for BZ2_bzCompressInit in /usr/lib64/libbz2.so - found
* TrinityCore rev. hash : cdf105f548b0+
* TrinityCore rev. date : 2013-01-03 22:53:44 +0100
* TrinityCore buildtype : Release
* Install core to : /usr/local/games/trinity
* Install libraries to : /usr/local/lib64/trinity
* Install configs to : /usr/local/etc/trinity
* Build world/auth : Yes (default)
* Build with scripts : Yes (default)
* Build map/vmap tools : Yes
* Build core w/PCH : No
* Build scripts w/PCH : No
* Show all warnings : Yes
* Use coreside debug : No (default)
-- SCRIPT PREPARATIONS
-> Prepared: Spells
-> Prepared: Commands
-> Prepared: Examples
-> Prepared: Custom
-> Prepared: World
-> Prepared: Outdoor PVP Zones
-> Prepared: Eastern Kingdoms
-> Prepared: Kalimdor
-> Prepared: Outland
-> Prepared: Northrend
-> Prepared: Events
-- SCRIPT PREPARATION COMPLETE
-- Configuring done
-- Generating done
-- Build files have been written to: /var/tmp/gtmp/trinity