Page 1 of 1

compile SVN on Gentoo

Posted: 06 Feb 2008, 12:06
by MarkU
Hi Im trying to compile the TMW from the SVN source to try the new server and help if I found some bug. The problem is that I can not compile it, even configure it. here are the steps Im trying

1º get the source from SVN

Code: Select all

#svn co https://themanaworld.svn.sourceforge.net/svnroot/themanaworld/tmw/trunk tmw
2º run autogen.sh (I think that here is the problem)

Code: Select all

# ./autogen.sh
Generating build information using autopoint, aclocal, autoheader, automake, and autoconf.

autopoint: *** cvs program not found
autopoint: *** Stop.
/usr/share/aclocal/nspr.m4:8: warning: underquoted definition of AM_PATH_NSPR
/usr/share/aclocal/nspr.m4:8:   run info '(automake)Extending aclocal'
/usr/share/aclocal/nspr.m4:8:   or see http://sources.redhat.com/automake/automake.html#Extending-aclocal
configure.ac:23: required file `./config.rpath' not found
configure.ac:23: required file `./ABOUT-NLS' not found

Now you are ready to run ./configure
there where som errors, but it said that I can run ./configure if I run it I get this at the end.

Code: Select all

#./configure --with-opengl
.
.
.checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for sys/socket.h... (cached) yes
checking for unistd.h... (cached) yes
checking for glBegin in -lGL... yes
configure: creating ./config.status
config.status: error: cannot find input file: Makefile.in
And there it finish. I dont know what is wrong or what Im doing wrong.

thanks and keep on going whith the game.. you are doing a wonderful game.

Posted: 06 Feb 2008, 18:31
by MarkU
ok... I have solve that problem... I didnt have the CVS program installed and it seems like the TMW need it to donwload some more files.

I could configure it and execute the make, but it get staked here

Code: Select all

	mv -f $depbase.Tpo $depbase.Po
depbase=`echo gui/skill.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
	g++ -DHAVE_CONFIG_H -I. -I..  -DTMW_DATADIR=\""/usr/local/share/tmw/"\" -DLOCALEDIR=\""/usr/local/share/locale"\"  -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -I/usr/include/libxml2    -g -O2 -MT gui/skill.o -MD -MP -MF $depbase.Tpo -c -o gui/skill.o gui/skill.cpp &&\
	mv -f $depbase.Tpo $depbase.Po
gui/skill.cpp:39:31: error: ../utils/toString.h: No such file or directory
gui/skill.cpp: In member function 'void SkillDialog::update()':
gui/skill.cpp:100: error: 'toString' was not declared in this scope
make[2]: *** [gui/skill.o] Error 1
make[2]: Leaving directory `/home/martin/tmw/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/martin/tmw'
make: *** [all] Error 2

Posted: 07 Feb 2008, 23:38
by Falcata
I'm having the same problem. It's looking for a file called "toString.h", but that file is actually named "tostring.h" To fix the problem, open up the file "src/gui/skill.cpp", and look for the include for toString.h

The file should be on or near line 39. Change "toString.h" to "tostring.h"

Posted: 07 Feb 2008, 23:48
by Crush
Problem is fixed in latest SVN.

Posted: 09 Feb 2008, 22:28
by MarkU
Thanks Crush. I can test the client now... I found some bugs and reported them to the bug traker.
There where nobody on the server, do you need people to test it, I will try to do my best.

Posted: 14 Feb 2008, 13:26
by Inte
Maybe some of you are interested in installing the SVN version of the client. Feel free to use this ebuild ... at least on my computer it works great.

# cat /usr/local/portage/games-rpg/tmw/tmw-9999.ebuild

Code: Select all

# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

inherit eutils games subversion

ESVN_REPO_URI="http://themanaworld.svn.sourceforge.net/svnroot/themanaworld/tmw/trunk/"
ESVN_BOOTSTRAP="./autogen.sh"
MUSIC="tmwmusic-0.0.20"
SRC_URI="mirror://sourceforge/themanaworld/${MUSIC}.tar.gz"

DESCRIPTION="A fully free and open source MMORPG game with the looks of \"old-fashioned\" 2D RPG"
HOMEPAGE="http://themanaworld.org"

LICENSE="GPL-2"
SLOT="0"
IUSE="opengl"
KEYWORDS="~amd64 ~x86"

DEPEND=">=dev-games/physfs-1.0.0
    opengl? ( virtual/opengl )
        dev-libs/libxml2
        media-libs/sdl-mixer
        media-libs/sdl-image
        media-libs/sdl-net
        media-libs/sdl-ttf
        net-libs/enet
        net-misc/curl
        >=dev-games/guichan-0.7.0
        dev-util/cvs"


pkg_setup() {
        games_pkg_setup
        if ! built_with_use dev-games/guichan sdl ; then
                eerror "dev-games/guichan needs to be built with USE=sdl"
                die "please re-emerge dev-games/guichan with USE=sdl"
        fi
        if ! built_with_use media-libs/sdl-mixer vorbis ; then
                eerror "media-libs/sdl-mixer needs to be built with USE=vorbis"
                die "please re-emerge media-libs/sdl-mixer with USE=vorbis"
        fi
}

src_unpack() {
        subversion_src_unpack
}

src_compile() {
        egamesconf --disable-dependency-tracking $(use_with opengl) || die
        emake || die
}

src_install() {
        emake DESTDIR="${D}" install || die "make install failed"
        dodoc AUTHORS ChangeLog NEWS README
        cd "${WORKDIR}"
        insinto "${GAMES_DATADIR}"/${PN}/data/music
        doins ${MUSIC}/data/music/*.ogg || die
        newdoc ${MUSIC}/README README.music
        prepgamesdirs
}

Re: compile SVN on Gentoo

Posted: 30 Apr 2008, 17:06
by ryutenchi
if I try to just compile manually I get this:

Code: Select all

make[2]: Entering directory `/home/system/Projects/tmw/src'
depbase=`echo gui/widgets/dropdown.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
        g++ -DHAVE_CONFIG_H -I. -I..  -DTMW_DATADIR=\""/usr/local/share/tmw/"\" -DLOCALEDIR=\""/usr/local/share/locale"\"  -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -I/usr/include/libxml2    -g -O2 -MT gui/widgets/dropdown.o -MD -MP -MF $depbase.Tpo -c -o gui/widgets/dropdown.o gui/widgets/dropdown.cpp &&\
        mv -f $depbase.Tpo $depbase.Po
gui/widgets/dropdown.cpp: In constructor 'DropDown::DropDown(gcn::ListModel*, gcn::ScrollArea*, gcn::ListBox*)':
gui/widgets/dropdown.cpp:45: error: 'setFrameSize' was not declared in this scope
gui/widgets/dropdown.cpp: In member function 'virtual void DropDown::draw(gcn::Graphics*)':
gui/widgets/dropdown.cpp:106: error: 'mFoldedUpHeight' was not declared in this scope
gui/widgets/dropdown.cpp: In member function 'void DropDown::drawFrame(gcn::Graphics*)':
gui/widgets/dropdown.cpp:156: error: 'getFrameSize' was not declared in this scope
gui/widgets/dropdown.cpp: In member function 'virtual void DropDown::drawButton(gcn::Graphics*)':
gui/widgets/dropdown.cpp:165: error: 'mFoldedUpHeight' was not declared in this scope
make[2]: *** [gui/widgets/dropdown.o] Error 1
make[2]: Leaving directory `/home/system/Projects/tmw/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/system/Projects/tmw'
make: *** [all] Error 2
if I try to install it from your ebuild I get this error:

Code: Select all

x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I..  -DTMW_DATADIR=\""/usr/share/games/tmw/"\" -DLOCALEDIR=\""/usr/games/share/locale"\"  -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -I/usr/include/libxml2    -march=k8 -O2 -pipe -c -o engine.o engine.cpp
In file included from gui/minimap.h:27,
                 from engine.cpp:42:
gui/window.h:28:38: error: guichan/widgetlistener.hpp: No such file or directory
In file included from gui/minimap.h:27,
                 from engine.cpp:42:
gui/window.h:48: error: expected class-name before '{' token
x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I..  -DTMW_DATADIR=\""/usr/share/games/tmw/"\" -DLOCALEDIR=\""/usr/games/share/locale"\"  -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -I/usr/include/libxml2    -march=k8 -O2 -pipe -c -o equipment.o equipment.cpp
make[2]: *** [engine.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999'
make: *** [all] Error 2
I actually played around with the straight code trying to get it to compile before I found your post, but honestly I have no idea where 'setFrameSize' and such came from so no luck. I want to get it to compile so I can see where the 0.1 client is so I can maybe add to either the client or the server^^

Thanks in advance,
-Ryu

Re: compile SVN on Gentoo

Posted: 30 Apr 2008, 19:47
by Sanga
ryutenchi wrote:gui/window.h:28:38: error: guichan/widgetlistener.hpp: No such file or directory
Check the version of guichan that you have installed. Trying to compile the latest SVN with 0.7.1 will produce this error - you need 0.8.0 or later.

Re: compile SVN on Gentoo

Posted: 01 May 2008, 15:44
by ryutenchi
well spotted, I updated guichan and both seem to compile now, but (always a but isn't there =P) now the ebuild errors out looking for oggs:

Code: Select all

/games/gettext/po/$file; \
          done; \
          for file in Makevars; do \
            rm -f /var/tmp/portage/games-rpg/tmw-9999/image//usr/share/games/gettext/po/$file; \
          done; \
        else \
          : ; \
        fi
make[1]: Leaving directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999/po'
Making install in src
make[1]: Entering directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999/src'
make[2]: Entering directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999/src'
test -z "/usr/games/bin" || /bin/mkdir -p "/var/tmp/portage/games-rpg/tmw-9999/image//usr/games/bin"
make[2]: Nothing to be done for `install-data-am'.
  /usr/bin/install -c 'tmw' '/var/tmp/portage/games-rpg/tmw-9999/image//usr/games/bin/tmw'
make[2]: Leaving directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999/src'
make[1]: Leaving directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999/src'
make[1]: Entering directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999'
make[2]: Entering directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999'
make[2]: Nothing to be done for `install-exec-am'.
test -z "/usr/share/games/applications" || /bin/mkdir -p "/var/tmp/portage/games-rpg/tmw-9999/image//usr/share/games/applications"
 /usr/bin/install -c -m 644 'tmw.desktop' '/var/tmp/portage/games-rpg/tmw-9999/image//usr/share/games/applications/tmw.desktop'
make[2]: Leaving directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999'
make[1]: Leaving directory `/var/tmp/portage/games-rpg/tmw-9999/work/tmw-9999'
install: cannot stat `tmwmusic-0.0.20/data/music/*.ogg': No such file or directory
 * 
 * ERROR: games-rpg/tmw-9999 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_install
 *             environment, line 2376:  Called die
 * The specific snippet of code:
 *       doins ${MUSIC}/data/music/*.ogg || die;
 *  The die message:
 *   (no error message)
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/games-rpg/tmw-9999/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/games-rpg/tmw-9999/temp/environment'.
 * 

 * Messages for package games-rpg/tmw-9999:

 * 
 * ERROR: games-rpg/tmw-9999 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_install
 *             environment, line 2376:  Called die
 * The specific snippet of code:
 *       doins ${MUSIC}/data/music/*.ogg || die;
 *  The die message:
 *   (no error message)
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/games-rpg/tmw-9999/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/games-rpg/tmw-9999/temp/environment'.
 * 
and the manually made/installed tmw runs but once I pick ok to loginto the test server it crashes saying:

Code: Select all

Error: ItemDB: Error while loading items.xml!
I will look through the forums here for a solution to that problem^^ any idea on the ebuild?
-Ryu

::EDIT:: svn blah/tmwdata got it ^.~

Re: compile SVN on Gentoo

Posted: 07 Sep 2008, 06:59
by The Kid
May I know where to put the tmwdata? I figured out as much to satisfy all the dependencies and have built 0.1 successfully on Ubuntu AMD x86_64, and I've figured that items.xml is missing, and items.xml is obtainable from svn, but where to put it?

I'm wondering if it is possible that "make install" could download tmwdata and install it at the appropriate location. Or at least fail the build if tmwdata is not available.

EDIT: Found it, tmwdata should be in /usr/local/share/tmw/data (on Ubuntu)