Page 1 of 1

client ignore command for ubuntu/debian under 0.0.24.x

Posted: 01 Jun 2008, 10:01
by bigglesworth
Fate has written an addition for the 0.0.2x client that allows players to issue an "ignore" command. The client command silences spammers and beggars.

A few of us players are not software engineers. Would someone be kind enough to review a step by step instruction on how to add the code and compile?

Listening to Fate, this is what i've picked up. (Any errors or omissions are my typos)

a) uninstall the old libguichan

b.0) install libguichan-0.8.1 and libguichan-dev-0.8.1 dpkgs from debian/sid
b.1) dpkg -i <filename> for both

c) if anything fails, uninstall what has been (partially) installed
c.0) download libguichan-0.8.1 source code
c.1) unpack libguichgan's source
c.2) enter the libguichan main directory
c.3) ./configure --prefix=/usr
c.4) make
c.5) sudo make install

Now compile the tmw svn snapshots...

d.0) ./configure
d.0.0) ./configure --prefix=/usr
d.0.1) CFLAGS="-03" ./configure
d.1) make
d.2) make install

e) tmw

Ok, I know i've had to have butchered the steps somewhere. Please help us until this becomes part of the 0.0.25 client.

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 01 Jun 2008, 18:03
by fate
Hi,

the `configure' step is not quite correct-- you should only run `./configure' once, most likely as `CXXFLAGS="-O3" ./configure --prefix=/usr' (to follow up on what you had earlier). Also, I forgot to mention that you have to regenerate the `configure' script. The `right' way to do that is probably to use `autogen.sh' (though my guess is that `autoreconf -i' would also work). (By the way, the CFLAGS parameter is for plain C compilation, but since you are compiling for C++, which is a different language with a (mostly) different compiler, you need a different flag-- apologies for the confusion).

Note that this performs a global installation, which may not be the cleanest solution. Here is an alternative route that installs everything locally and at no point requires superuser privileges:

(0) Ensure that you have all prerequisites (the ones I list here are the ones I have installed, you may be able to use similar packages, though):
(0.0) You need libsdl1.2-dev
(0.1) You need libphysfs-dev
(0.2) You need libxml2-dev
(0.3) You need libcurl4-openssl-dev (or an equivalent package)
(0.4) You need zlib1g-dev
(0.5) You need autotools-dev
(0.6) You need g++-4.2 (or g++-4.3 or g++-4.1 or g++-4.2-multilib or...)
(1) install libguichan-0.8.1 locally:
(1.0) Download the libguichan-0.8.1 source package
(1.1) Unzip the libguichan-0.8.1 source package
(1.2) Enter the main directory (should be just one step down, easily identifiable by containing COPYING, README and configure
(1.3) CXXFLAGS="-O3" ./configure --prefix=${HOME} && make && make install
(2) install tmw locally:
(2.0) svn co https://themanaworld.svn.sourceforge.net/svnroot/themanaworld/tmw/branches/0.0
(2.1) cd 0.0
(2.2) CPPFLAGS="-I ${HOME}/include" LDFLAGS="-L ${HOME}/lib" CXXFLAGS="-O3" ./configure && make && make install

Unless you ran into an error message somewhere, you should be done now. To start the game, run

LD_LIBRARY_PATH=${HOME}/lib:${LD_LIBRARY_PATH} ./src/tmw

Please let me know if you run into any issues with this (or post a note if it worked for you, or if you found a workaround/improvement)!

-- fate

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 02 Jun 2008, 02:39
by bigglesworth
Thank you, Fate, for taking the time to hold my hand and walk me through that!

I picked up guichan from sourceforge and tmw from svn.

I followed your local installation instructions.

The only error I had was mistaking "-O3" as "-03".

It shouldn't be too long now before I find some people to ignore.

Thank you. You don't know how happy I am!

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 02 Jun 2008, 16:32
by GonzoDark
fate wrote: Please let me know if you run into any issues with this (or post a note if it worked for you, or if you found a workaround/improvement)!

-- fate

(2.1) cd 0.0
(2.2) sh autogen.sh
(2.3) CPPFLAGS="-I ${HOME}/include" LDFLAGS="-L ${HOME}/lib" CXXFLAGS="-O3" ./configure && make && sudo make install

step 2.2 makes the configure file ;)
and step 2.3 should be done with "sudo make install"


// GonzoDark

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 02 Jun 2008, 16:48
by fate
Ichigo,

thank you for the correction! :-) (What I had in mind, though, was to forego an installation altogether.)

Since I can't edit anymore, here is the full list again:

(0) Ensure that you have all prerequisites (the ones I list here are the ones I have installed, you may be able to use similar packages, though):
(0.0) You need libsdl1.2-dev
(0.1) You need libphysfs-dev
(0.2) You need libxml2-dev
(0.3) You need libcurl4-openssl-dev (or an equivalent package)
(0.4) You need zlib1g-dev
(0.5) You need autotools-dev
(0.6) You need g++-4.2 (or g++-4.3 or g++-4.1 or g++-4.2-multilib or...)
(1) install libguichan-0.8.1 locally:
(1.0) Download the libguichan-0.8.1 source package
(1.1) Unzip the libguichan-0.8.1 source package
(1.2) Enter the main directory (should be just one step down, easily identifiable by containing COPYING, README and configure
(1.3) CXXFLAGS="-O3" ./configure --prefix=${HOME} && make && make install
(2) install tmw locally:
(2.0) svn co https://themanaworld.svn.sourceforge.ne ... anches/0.0
(2.1) cd 0.0
(2.2) sh autogen.sh
(2.3) CPPFLAGS="-I ${HOME}/include" LDFLAGS="-L ${HOME}/lib" CXXFLAGS="-O3" ./configure && make

Unless you ran into an error message somewhere, you should be done now. To start the game, run

LD_LIBRARY_PATH=${HOME}/lib:${LD_LIBRARY_PATH} ./src/tmw

(apologies for the repetition; this should be moved to a wiki page unless there already is one, but I'm in a bit of a hurry.)

-- fate

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 02 Jun 2008, 17:29
by GonzoDark
and one more thing, how about making a symbol link to libguichan_sdl-0.8.1.so.1 with this code:

ln -s /home/YOU-USER-NAME/lib/libguichan_sdl-0.8.1.so.1 /usr/lib/libguichan_sdl-0.8.1.so.1

that enables you to open the game with "tmw" or whatever.

and sorry for making you post again.. but you missed the '&& sudo make install' in your newest update, under step 2.3 =/

// GonzoDark

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 02 Jun 2008, 18:11
by Superkoop
GonzoDark wrote: and sorry for making you post again.. but you missed the '&& sudo make install' in your newest update, under step 2.3 =/

// GonzoDark
I think she left it out on purpose, since her goal was not to actually install it.
fate wrote:(What I had in mind, though, was to forego an installation altogether.)
But if you did want to install it, then you would use && sudo make install (or && sudo checkinstall)

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 03 Jun 2008, 19:46
by GonzoDark
and one more thing, you will need the build-essential package :

sudo apt-get install build-essential

EDIT:

and you might want to add:

automake autoconf subversion

to the list over dependencies.

// GonzoDark

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 03 Jun 2008, 20:12
by Jaxad0127
This may be better on the wiki so fixes are easier to make and older versions aren't listed first by default (they wouldn't be listed at all this way, except through some links).

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 03 Jun 2008, 20:26
by GonzoDark

Re: client ignore command for ubuntu/debian under 0.0.24.x

Posted: 21 Jun 2008, 21:52
by Shaggy
GonzoDark wrote: and step 2.3 should be done with "sudo make install"


// GonzoDark
Just one small point... I don't trust the security of sudo - I'd be much happier disabling it and using su -c "make install"