diff options
-rw-r--r-- | .github/workflows/core_build.yml | 14 | ||||
-rw-r--r-- | apps/ci/ci-conf.sh | 6 | ||||
-rw-r--r-- | apps/compiler/includes/functions.sh | 2 | ||||
-rw-r--r-- | conf/dist/config.sh | 2 | ||||
-rw-r--r-- | src/server/game/Warden/WardenMac.cpp | 10 | ||||
-rw-r--r-- | src/server/game/Warden/WardenWin.cpp | 10 |
6 files changed, 32 insertions, 12 deletions
diff --git a/.github/workflows/core_build.yml b/.github/workflows/core_build.yml index ae78caa266..1be5d9168d 100644 --- a/.github/workflows/core_build.yml +++ b/.github/workflows/core_build.yml @@ -15,30 +15,42 @@ jobs: os: [ubuntu-20.04] compiler: [clang] modules: [with, without] + extra_logs: [false] # we can include specific combinations here include: - os: ubuntu-20.04 compiler: clang11 modules: without + extra_logs: true + - os: ubuntu-20.04 + compiler: clang11 + modules: without + extra_logs: false - os: ubuntu-20.04 compiler: clang9 modules: without + extra_logs: false - os: ubuntu-18.04 compiler: clang # default in 18.04 is clang 6 modules: without + extra_logs: false - os: ubuntu-18.04 compiler: gcc8 modules: without + extra_logs: false - os: ubuntu-20.04 compiler: gcc # default in 20.04 is gcc 9 modules: without + extra_logs: false - os: ubuntu-20.04 compiler: gcc10 modules: without + extra_logs: false runs-on: ${{ matrix.os }} - name: ${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.modules }}-modules + name: ${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.modules }}-modules-extra_logs-${{ matrix.extra_logs }} env: COMPILER: ${{ matrix.compiler }} + EXTRA_LOGS: ${{ matrix.extra_logs }} if: github.repository == 'azerothcore/azerothcore-wotlk' steps: - uses: actions/checkout@v2 diff --git a/apps/ci/ci-conf.sh b/apps/ci/ci-conf.sh index 3fb0eae9e3..0d06410dc3 100644 --- a/apps/ci/ci-conf.sh +++ b/apps/ci/ci-conf.sh @@ -76,3 +76,9 @@ case $COMPILER in exit 1 ;; esac + +if [[ $EXTRA_LOGS ]]; then + echo "CEXTRA_LOGS=1" >> ./conf/config.sh +else + echo "CEXTRA_LOGS=0" >> ./conf/config.sh +fi diff --git a/apps/compiler/includes/functions.sh b/apps/compiler/includes/functions.sh index 6c1a842dde..7d4bf5176a 100644 --- a/apps/compiler/includes/functions.sh +++ b/apps/compiler/includes/functions.sh @@ -37,7 +37,7 @@ function comp_configure() { -DSCRIPTS=$CSCRIPTS \ -DBUILD_TESTING=$CBUILD_TESTING \ -DTOOLS=$CTOOLS -DUSE_SCRIPTPCH=$CSCRIPTPCH -DUSE_COREPCH=$CCOREPCH -DWITH_COREDEBUG=$CDEBUG -DCMAKE_BUILD_TYPE=$CTYPE -DWITH_WARNINGS=$CWARNINGS \ - -DCMAKE_C_COMPILER=$CCOMPILERC -DCMAKE_CXX_COMPILER=$CCOMPILERCXX "-DDISABLED_AC_MODULES=$CDISABLED_AC_MODULES" $CCUSTOMOPTIONS + -DCMAKE_C_COMPILER=$CCOMPILERC -DCMAKE_CXX_COMPILER=$CCOMPILERCXX -DENABLE_EXTRA_LOGS=$CEXTRA_LOGS "-DDISABLED_AC_MODULES=$CDISABLED_AC_MODULES" $CCUSTOMOPTIONS cd $CWD diff --git a/conf/dist/config.sh b/conf/dist/config.sh index 91d987fb3a..8feef71197 100644 --- a/conf/dist/config.sh +++ b/conf/dist/config.sh @@ -56,6 +56,8 @@ CTOOLS=OFF # use precompiled headers ( fatest compilation but not optimized if you change headers often ) CSCRIPTPCH=ON CCOREPCH=ON +# enable/disable extra logs +CEXTRA_LOGS=0 # Skip specific modules from compilation (cmake reconfigure needed) # use semicolon ; to separate modules diff --git a/src/server/game/Warden/WardenMac.cpp b/src/server/game/Warden/WardenMac.cpp index 794e101dd3..6599bf1ecc 100644 --- a/src/server/game/Warden/WardenMac.cpp +++ b/src/server/game/Warden/WardenMac.cpp @@ -48,17 +48,17 @@ void WardenMac::Init(WorldSession* pClient, SessionKey const& K) _outputCrypto.Init(_outputKey); #if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) sLog->outDebug(LOG_FILTER_WARDEN, "Server side warden for client %u initializing...", pClient->GetAccountId()); - sLog->outDebug(LOG_FILTER_WARDEN, "C->S Key: %s", acore::Impl::ByteArrayToHexStr(_inputKey).c_str()); - sLog->outDebug(LOG_FILTER_WARDEN, "S->C Key: %s", acore::Impl::ByteArrayToHexStr(_outputKey).c_str()); - sLog->outDebug(LOG_FILTER_WARDEN, " Seed: %s", acore::Impl::ByteArrayToHexStr(_seed).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "C->S Key: %s", acore::Impl::ByteArrayToHexStr(_inputKey, false).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "S->C Key: %s", acore::Impl::ByteArrayToHexStr(_outputKey, false ).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, " Seed: %s", acore::Impl::ByteArrayToHexStr(_seed, false).c_str()); sLog->outDebug(LOG_FILTER_WARDEN, "Loading Module..."); #endif _module = GetModuleForClient(); #if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) - sLog->outDebug(LOG_FILTER_WARDEN, "Module Key: %s", acore::Impl::ByteArrayToHexStr(_module->Key).c_str()); - sLog->outDebug(LOG_FILTER_WARDEN, "Module ID: %s", acore::Impl::ByteArrayToHexStr(_module->Id).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "Module Key: %s", acore::Impl::ByteArrayToHexStr(_module->Key, false).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "Module ID: %s", acore::Impl::ByteArrayToHexStr(_module->Id, false).c_str()); #endif RequestModule(); } diff --git a/src/server/game/Warden/WardenWin.cpp b/src/server/game/Warden/WardenWin.cpp index 1f64db6c7b..8befc10a9d 100644 --- a/src/server/game/Warden/WardenWin.cpp +++ b/src/server/game/Warden/WardenWin.cpp @@ -105,17 +105,17 @@ void WardenWin::Init(WorldSession* session, SessionKey const& k) _outputCrypto.Init(_outputKey); #if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) sLog->outDebug(LOG_FILTER_WARDEN, "Server side warden for client %u initializing...", session->GetAccountId()); - sLog->outDebug(LOG_FILTER_WARDEN, "C->S Key: %s", acore::Impl::ByteArrayToHexStr(_inputKey).c_str()); - sLog->outDebug(LOG_FILTER_WARDEN, "S->C Key: %s", acore::Impl::ByteArrayToHexStr(_outputKey).c_str()); - sLog->outDebug(LOG_FILTER_WARDEN, " Seed: %s", acore::Impl::ByteArrayToHexStr(_seed).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "C->S Key: %s", acore::Impl::ByteArrayToHexStr(_inputKey, false).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "S->C Key: %s", acore::Impl::ByteArrayToHexStr(_outputKey,false).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, " Seed: %s", acore::Impl::ByteArrayToHexStr(_seed, false).c_str()); sLog->outDebug(LOG_FILTER_WARDEN, "Loading Module..."); #endif _module = GetModuleForClient(); #if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) - sLog->outDebug(LOG_FILTER_WARDEN, "Module Key: %s", acore::Impl::ByteArrayToHexStr(_module->Key).c_str()); - sLog->outDebug(LOG_FILTER_WARDEN, "Module ID: %s", acore::Impl::ByteArrayToHexStr(_module->Id).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "Module Key: %s", acore::Impl::ByteArrayToHexStr(_module->Key, false).c_str()); + sLog->outDebug(LOG_FILTER_WARDEN, "Module ID: %s", acore::Impl::ByteArrayToHexStr(_module->Id, false).c_str()); #endif RequestModule(); } |