Jump to content
  • 0

MaNGOS Three Compilation Difficulties


Question

Hello everyone, and thank you for looking this over for me. I am trying to compile the MaNGOS three distribution on an Ubuntu 18.04 virtual machine, and when doing so I'm running into some errors (shown below) I'm aware that the notes mention pulling the /dep directory from git on its own when having errors with the ACE dependencies, and I was able to do so, but I still arrived at the same errors. Note that when I pulled the /dep directory the command I used was "git clone https://github.com/mangos/mangosDeps.git . --recursive --depth=3"

 

Quote

[ 43%] Building CXX object dep/acelite/CMakeFiles/ace.dir/ace/Log_Meg_Android_Logcat.cpp.o /home/wowserver/sources/dep/acelite/ace/Log_Msg.cpp:438:30: error: 'ACE_DEFAULT_LOG_FLAGS' was not declared in this scope     u_long ACE_LOG_MSG::flags_ = ACE_DEFAULT_LOG_FLAGS;

 

The build then proceeds to suggest an alternative of ACE_DEFAULT_LOCALNAME. Obviously ACE is not MaNGOS, so I guess what I need to know is where I can get the correct /dep directory in order to compile correctly for Ubuntu 18.04, or where I might be mucking things up. 

Link to post
Share on other sites

9 answers to this question

Recommended Posts

  • 0

Hello @PQuicksilver

If you follow the guide : 

There is a note about /dep folder but there is no need to fully clone the repo !

Can you start from the begininng and just clone the main repo and for the dep folder just make a git pull / git checkout master as it is stated in the guide ?

Link to post
Share on other sites
  • 0
Posted (edited)

Thanks for the prompt response. I'll give that a run and edit this when I get a result and let you know. I thought my error was with git somehow - I'm not as familiar with that as I could be. I understand then if I use git pull while in the /home/mangos/sources/dep directory it will pull just that directory from the repository? or is that the  git checkout master?

 

Edit 7/31/2020:

Okay, so I started completely over - New VM with the same schematics. For the first attempt at the build, I did nothing to the /sources/dep folder and had the expected ACE dependency errors as mentioned in the note. Thereafter I went to the /sources/dep directory and tried "git pull". Git responded with "You aren't currently on a branch", so I used "git checkout master" and then "git pull" all while in the /sources/dep directory.  git responded with Already up to date. 

 

Following these, the build got further than the last time, and got to the same point as I had with the first post here - the ACE_DEFAULT_LOG_FLAGS error as described above.  Again, many thanks for your assistance in this matter, and I look forward to any further suggestions

Edited by PQuicksilver
Update
Link to post
Share on other sites
  • 0

I've been tripping over the same thing, trying to build three and four. zero->two work fine.

Been trying in:
* Clean 18.04 VM
* Clean 20.04 VM
* ubuntu:bionic docker image
* ubuntu:focal docker image
All with dedicated 6 cores and 16GB of RAM.

For testing/comparison:
 

# All as root
# Install Deps
apt-get -y update
apt-get -y install git make cmake libssl-dev libbz2-dev build-essential default-libmysqlclient-dev libace-6.4.5 libace-dev python

# Pull sources for zero->four
for MANGOS in 'zero' 'one' 'two' 'three' 'four'; do
    mkdir /${MANGOS}
    git clone --single-branch --recursive --depth 1 https://github.com/mangos${MANGOS}/server.git /${MANGOS}/server
    git clone --single-branch --recursive --depth 1 https://github.com/mangos${MANGOS}/database.git /${MANGOS}/db
    cd /${MANGOS}/server/dep && git pull origin master && git checkout master
    mkdir /${MANGOS}/build
done

# Try building zero->four
for MANGOS in 'zero' 'one' 'two' 'three' 'four'; do
    cd /${MANGOS}/build
    cmake ../server/ -DCMAKE_INSTALL_PREFIX=/mangos${MANGOS} -DCONF_INSTALL_DIR=/mangos${MANGOS}/etc -DPLAYERBOTS=0 -DSOAP=1
    make -j 1
done

 

zero - builds in all environments, can also be built with playerbots enabled in all environments
one - builds in all environments, playerbots is broken
two - builds in all environments, playerbots is broken
three - fails in all environments
four - fails in all environments

I've also tried SOAP on/off, clearly not related.

I actually have no idea how three passing travis right now.

Three and four give this(I've rerun a couple times since, so it's quicker to the ACE error)

[email protected]:/three/build# cmake ../server/       -DCMAKE_INSTALL_PREFIX=/mangos       -DCONF_INSTALL_DIR=/mangos/etc       -DPLAYERBOTS=0       -DSOAP=0

This script builds the MaNGOS server.
  Options that can be used in order to configure the process:
   General:
    CMAKE_INSTALL_PREFIX    Path where the server should be installed to
    CONF_DIR                Path to the configs, can be absolute or relative.
    DEBUG                   Debug mode (strict compile, all warnings)
    ACE_USE_EXTERNAL        Use external ACE
    BUILD_MANGOSD           Build the main server
    BUILD_REALMD            Build the login server
    BUILD_TOOLS             Build the map/vmap/mmap extractors
    SOAP                    Enable remote access via SOAP
   Scripting engines:
    SCRIPT_LIB_ELUNA        Compile with support for Eluna scripts
    SCRIPT_LIB_SD3          Compile with support for ScriptDev3 scripts
#   Modules:
#    PLAYERBOTS              Enable Player Bots
  To set an option simply type -D<OPTION>=<VALUE> after 'cmake <srcs>'.
  Also, you can specify the generator with -G. see 'cmake --help' for more details
  For example: cmake .. -DDEBUG=1 -DCMAKE_INSTALL_PREFIX=/opt/mangos

  Note: On UNIX systems, CONF_DIR is relative to the bin folder.

-- Detected 64-bit platform
-- OpenSSL library: /usr/lib/x86_64-linux-gnu/libssl.so;/usr/lib/x86_64-linux-gnu/libcrypto.so
-- OpenSSL headers: /usr/include
-- OpenSSL version: 1.1.1
-- Install server to     : /mangosthree
-- Install configs to    : /mangosthree/etc/
-- Search configs from   : etc/
-- Support for SOAP      : No (default)
-- Script engine Eluna   : No (default)
-- Script engine SD3     : Yes (default)
-- Build main server     : Yes (default)
-- Build login server    : Yes (default)
-- Build tools           : Yes (default)
-- Build in debug-mode   : No  (default)
-- Configuring done
-- Generating done
-- Build files have been written to: /three/build
[email protected]:/three/build# make -j1
[  0%] Built target pch.cpp_dephelp
[  0%] Built target generate_pch.cpp
[  0%] Building CXX object dep/acelite/CMakeFiles/ace.dir/ace/Log_Msg.cpp.o
/three/server/dep/acelite/ace/Log_Msg.cpp:438:30: error: 'ACE_DEFAULT_LOG_FLAGS' was not declared in this scope
 u_long ACE_Log_Msg::flags_ = ACE_DEFAULT_LOG_FLAGS;
                              ^~~~~~~~~~~~~~~~~~~~~
/three/server/dep/acelite/ace/Log_Msg.cpp:438:30: note: suggested alternative: 'ACE_DEFAULT_LOCALNAME'
 u_long ACE_Log_Msg::flags_ = ACE_DEFAULT_LOG_FLAGS;
                              ^~~~~~~~~~~~~~~~~~~~~
                              ACE_DEFAULT_LOCALNAME
dep/acelite/CMakeFiles/ace.dir/build.make:2438: recipe for target 'dep/acelite/CMakeFiles/ace.dir/ace/Log_Msg.cpp.o' failed
make[2]: *** [dep/acelite/CMakeFiles/ace.dir/ace/Log_Msg.cpp.o] Error 1
CMakeFiles/Makefile2:225: recipe for target 'dep/acelite/CMakeFiles/ace.dir/all' failed
make[1]: *** [dep/acelite/CMakeFiles/ace.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2

 

Edited by Daecho
Link to post
Share on other sites
  • 0

@Daecho Thanks for the reports. I'm aware of the following:
MangosOne Playerbots broken
MangosTwo Playerbots Broken
For MangosThree and MangosFour the problems run deeper.
- There isn't much interest in MangosThree or MangosFour at all, so they are a little neglected - But I do try and work on them when I can.

All the Above are on my list to fix, but I don't have spare time and there are higher priority fixes needed elsewhere.
- If you are willing to investigate the issues, i'll happily offer my help where I can

 

Link to post
Share on other sites
  • 0

Did this every get solved? I think I'm running into the same issue. MangosThree and a Ubuntu 18.04 server.  

I do a git clone on the original repo, cd dep, git pull (which tells me I need to select a remote branch), so I do git remote -v and then git pull https://github.com/mangos/mangosDeps master. It pulls down a lot of files, but get 46% into building and get this error:

 

Quote

/home/mangos/sources/dep/acelite/ace/Log_Msg.cpp:438:30: error: ‘ACE_DEFAULT_LOG_FLAGS’ was not declared in this scope
 u_long ACE_Log_Msg::flags_ = ACE_DEFAULT_LOG_FLAGS;
                              ^~~~~~~~~~~~~~~~~~~~~
/home/mangos/sources/dep/acelite/ace/Log_Msg.cpp:438:30: note: suggested alternative: ‘ACE_DEFAULT_LOCALNAME’
 u_long ACE_Log_Msg::flags_ = ACE_DEFAULT_LOG_FLAGS;
                              ^~~~~~~~~~~~~~~~~~~~~
                              ACE_DEFAULT_LOCALNAME
 

 

Link to post
Share on other sites
  • 0

@lauren_eily The recommended way to get and the correct source code is to use the --recursive flag when cloning: see

MangosThree is a bit more messier than the other cores due to problems of the build system. I did managed to get MangosThree to Build on Linux and Windows recently with some changes.

Link to post
Share on other sites
  • 0
5 hours ago, antz said:

@lauren_eily The recommended way to get and the correct source code is to use the --recursive flag when cloning: see

MangosThree is a bit more messier than the other cores due to problems of the build system. I did managed to get MangosThree to Build on Linux and Windows recently with some changes.

I did use the --recursive flag, with --depth=1, for the original clone, but I still run into Ace issues (even after pulling the dep submodule and checking out master). Sadly, I'm now trying mangostwo instead. :(

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use