Author Topic: How to build megaglest on Ubuntu linux and help testing  (Read 1435 times)

david

  • Guest
How to build megaglest on Ubuntu linux and help testing
« on: 11 October 2011, 19:16:57 »
How to build megaglest game

To successfully build the latest revision from svn you have to install subversion, cmake and some libraries:
Code: [Select]
sudo apt-get install subversion cmake libxerces-c2-dev libalut-dev libgl1-mesa-dev libglu1-mesa-dev libvorbis-dev libwxbase2.8-dev libwxgtk2.8-dev libx11-dev liblua5.1-0-dev
libjpeg-dev libpng12-dev libcurl4-gnutls-dev cmake-curses-gui libgtk2.0-dev libxml2-dev libircclient-dev libftgl-dev libminiupnpc-dev libsdl1.2-dev
To checkout sources create a directory and type:
Code: [Select]
mkdir megaglest_src
cd megaglest_src

Code: [Select]
svn co https://megaglest.svn.sourceforge.net/svnroot/megaglest/trunk ./
Then launch build-mg.sh
Code: [Select]
./build-mg.sh
To update your folder from svn go into the source directory and type:
Code: [Select]
svn update
Then relaunch build-mg.sh
« Last Edit: 11 October 2011, 21:01:25 by david »

softcoder

  • MegaGlest Team
  • Battle Machine
  • ********
  • Posts: 2,238
    • View Profile
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #1 on: 11 October 2011, 20:13:11 »
What problems do you have launching the editor and viewer (they work fine for me). Also the steps to compile should already be documented on the MG wiki.

Thanks

david

  • Guest
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #2 on: 11 October 2011, 20:58:13 »
Hi,

you're right I've missed some libraries!!!
I didn't read the wiki carefully.

So now all things builds.

Thanks for your help

tomreyn

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 2,764
    • View Profile
    • MegaGlest - the free and open source cross platform 3D real-time strategy game
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #3 on: 11 October 2011, 21:01:28 »
Right, we didn't install the xml2 dependencies since it already took us a while to get dependencies and build options sorted on his OpenSuSE 11.4. We kept trying to statically compile curl, which is the default (and nothing is mentioned about it on our wiki) and a "not really supported" on Opensuse (I was told on IRC).

Glad you could sort this out David, and thanks for your documentation. :)
atibox: Ryzen 1800X (8 cores @3.6GHz), 32 GB RAM, MSI Radeon RX 580 Gaming X 8G, PCI subsystem ID [1462:3417], (Radeon RX 580 chipset, POLARIS10) @3440x1440; latest stable Ubuntu release, (open source) radeon (amdgpu) / mesa video driver
atibox (old): Core2Quad Q9400 (4 cores @2.66GHz), 8 GB RAM, XFX HD-467X-DDF2, PCI subsystem ID [1682:2931], (Radeon HD 4670, RV730 XT) @1680x1050; latest stable Ubuntu release, (open source) radeon / mesa video driver
notebook: HP envy13d020ng
internet access: VDSL2+

· · · How YOU can contribute to MG · Latest development snapshot · How to build yourself · Megapack techtree · Currently hosted MG games · · ·

Omega

  • MegaGlest Team
  • Dragon
  • ********
  • Posts: 6,167
  • Professional bug writer
    • View Profile
    • Personal site
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #4 on: 11 October 2011, 22:59:57 »
How does it differ from the page on the wiki, which already hosts compilation guides for Linux, Windows, Mac, and FreeBSD?
« Last Edit: 18 June 2016, 18:37:48 by filux »
Edit the MegaGlest wiki: http://docs.megaglest.org/

My personal projects: http://github.com/KatrinaHoffert

tomreyn

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 2,764
    • View Profile
    • MegaGlest - the free and open source cross platform 3D real-time strategy game
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #5 on: 12 October 2011, 00:44:13 »
There's no mention of a possible need to change, in mg-build.sh, or when invoking cmake manually, the cmake option -DWANT_STATIC_LIBS=ON to -DWANT_STATIC_LIBS=OFF. Doing a statiuc build can make sense, depending on what you're trying to do.
atibox: Ryzen 1800X (8 cores @3.6GHz), 32 GB RAM, MSI Radeon RX 580 Gaming X 8G, PCI subsystem ID [1462:3417], (Radeon RX 580 chipset, POLARIS10) @3440x1440; latest stable Ubuntu release, (open source) radeon (amdgpu) / mesa video driver
atibox (old): Core2Quad Q9400 (4 cores @2.66GHz), 8 GB RAM, XFX HD-467X-DDF2, PCI subsystem ID [1682:2931], (Radeon HD 4670, RV730 XT) @1680x1050; latest stable Ubuntu release, (open source) radeon / mesa video driver
notebook: HP envy13d020ng
internet access: VDSL2+

· · · How YOU can contribute to MG · Latest development snapshot · How to build yourself · Megapack techtree · Currently hosted MG games · · ·

david

  • Guest
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #6 on: 12 October 2011, 19:05:30 »
Hi all,

I did that post because when I've searched documentation to build mg, I didn't found lib dependencies.  :look:
So I've build mg resolving all errors I have and I thought  this topic was helpfully.

Thanks to your remark and after reading more carefully the wiki, I've finally found the libs I missed on file setupBuildDeps.sh.

I think I missed that because as an Ubuntu user for a long time (And I think as Linux users), when I've searched the libs to install, I read quickly the doc searching a line which begin by
sudo apt-get install....
So it's my fault... :-[

So I didn't think to search on mk/linux/setupBuildDeps.sh

Maybe the work you've done is too perfect and too easy.  :D

Sorry if my post seems to be a double of the wiki. But finally it help me!

Thank you all.

tomreyn

  • MegaGlest Team
  • Airship
  • ********
  • Posts: 2,764
    • View Profile
    • MegaGlest - the free and open source cross platform 3D real-time strategy game
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #7 on: 13 October 2011, 17:47:17 »
Here's an update which will likely matter for people doing dynamic builds, i.e. with -DWANT_STATIC_LIBS=OFF:

Since r2641, the code works with the miniupnpc library v1.6 (was 1.4). To remain compatible to v1.4, new build flags was added in r2643:

Quote
<CIA-64> megaglest: mvejvoda * r2643 /trunk/source/shared_lib/ (4 files in 3 dirs):
<CIA-64> megaglest: - bugfixes for supporting compile of miniupnpc1.4 -> 1.6. Added two new optional commandline options for cmake:
<CIA-64> megaglest: -DMINIUPNPC_VERSION_PRE1_6=true
<CIA-64> megaglest: -DMINIUPNPC_VERSION_PRE1_5=true
<softcoder> unfortunately there is no consistent and workable way to get the version of libunpnpc so i added cmake flags for older versions
<softcoder> so to compile using the lib you sent me a link for:
<softcoder> cmake -DCMAKE_INSTALL_PREFIX= -DMINIUPNPC_VERSION_PRE1_6=true ..
<softcoder> this will build the dynamic libs and work with pre 1.6 libupnpc
<softcoder> so voila we support miniupnpc 1.4 to 1.6
atibox: Ryzen 1800X (8 cores @3.6GHz), 32 GB RAM, MSI Radeon RX 580 Gaming X 8G, PCI subsystem ID [1462:3417], (Radeon RX 580 chipset, POLARIS10) @3440x1440; latest stable Ubuntu release, (open source) radeon (amdgpu) / mesa video driver
atibox (old): Core2Quad Q9400 (4 cores @2.66GHz), 8 GB RAM, XFX HD-467X-DDF2, PCI subsystem ID [1682:2931], (Radeon HD 4670, RV730 XT) @1680x1050; latest stable Ubuntu release, (open source) radeon / mesa video driver
notebook: HP envy13d020ng
internet access: VDSL2+

· · · How YOU can contribute to MG · Latest development snapshot · How to build yourself · Megapack techtree · Currently hosted MG games · · ·

softcoder

  • MegaGlest Team
  • Battle Machine
  • ********
  • Posts: 2,238
    • View Profile
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #8 on: 13 October 2011, 17:50:02 »
I have already updated the wiki page to show customized build options in cmake listing these and other option arguments.

david

  • Guest
Re: How to build megaglest on Ubuntu linux and help testing
« Reply #9 on: 15 October 2011, 17:43:29 »
Hi,

today I’ve upgrade to Ubuntu 11.10 and I couldn’t build from svn. cmake complain about some Vars and make ends with an error.

To resolve this problem I've proceed as that:

First I've clean the system, deleting all libraries witch does still used to do a "fresh" install.
Then I've used the install lib deps script that mg sources provide.

But I've got another error. make complain about rtmp.

So I’ve installed librtmp-dev and the problem was solved.

 

anything