aMule Forum

English => Compilation problems => Topic started by: tt-web on September 09, 2007, 08:21:03 AM

Title: aMule CVS auf (k)ubuntu feisty
Post by: tt-web on September 09, 2007, 08:21:03 AM
Hi,
i have the problem that i do not get a good package fpr i686.  I started configure with:

./configure  --with-x --enable-geoip --enable-alc --enable-alcc --enable-wxcas --enable-cas --enable-amule-gui --enable-webserver --enable-amulecmd --enable-amule-daemon --enable-optimize --enable-ccache CFLAGS="-march=pentium3 -O2" CXXFLAGS="-march=pentium3 -O2"

afterwards i used "make" and "checkinstall". Checkinstall says the architecture would be i386, so i changed it to i686 and it creates a package named amule_20070909-1_i686.deb which is not installable, because the package-system complains about wrong architecture. Maybe this is because i686 is the subarchitecture, so i built the pac again with i386. Now the name of pac is diffrent, but wrong. I compiled the pac for pentium3. What can i do to build "clean" pacs for (k)ubuntu?
Thank You
Thomas
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: Vollstrecker on September 09, 2007, 10:25:42 AM
i386 is just the name in the repos. Original Debian Repos are called i386, too, but they are optimised at least for i486 since Etch.

http://www.amule.org/wiki/index.php/HowTo_Compile_In_Debian
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: tt-web on September 09, 2007, 12:05:35 PM
OK,
i did the whole HowTo but how do i tell dpkg-buildpackage that it should compile for i686 or even better pentium3 (my cpu). How can i mark the packages that they are special for pentium3?
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: Vollstrecker on September 09, 2007, 12:36:14 PM
In debian/rules you'll find two lines:

DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)

If you run the command after the shell statement, you'll get the value that is used for the --host (line1) and --build (line 2) options if the configure script. If these command give you on the shell the value you want, it's all fine. If not change them to something like

DEB_HOST_GNU_TYPE   = i686
DEB_BUILD_GNU_TYPE  = i686

or something, I don't know what they exactly expect.

If you want to have the --optimise option activated, run debian/rules help, and pick the packages you want, but don't choose any -dbg package.

In any way, debian expects i386 as arch-indicator, and that's what the name still expresses.
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: tt-web on September 09, 2007, 01:51:46 PM
Hi,
this tip was exactly what i needed. The compiling process works, but apt complains about wrong architecture *argh*. The problem is: I definitly know that i have a i686 *lol*. How can i tell my system that it is not a

thomas@thomas-laptop:~$ dpkg-architecture -qDEB_HOST_GNU_TYPE
i486-linux-gnu

but a i686-linux-gnu ???

Can i find it in an environmental var, or do i have to force the installation? Both ways are not very satisfying, because the package should run on other i686, too.

Thank you! Thomas
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: Vollstrecker on September 09, 2007, 02:04:50 PM
You don't get it. If you set the compilation to the right thing, it get's compiled with this options. You use the original debian/rules you can just search for the place where the configure line is, remove the --build and --host statements and let configure choose it by itself. But in any way, in the Architecture filed and the name of the package there has to be i386. You can enter something else, like sparc or ppc, but if you use intel, apt accepts ONLY i386. For apt things like i[456]86 just don't exist.
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: tt-web on September 09, 2007, 02:19:34 PM
Ahhhhhh, ok, i understand. But i did a mistake: it does not work, i used the old parameters. If i try this:

dpkg-architecture -qDEB_HOST_GNU_TYPE

i get:

i486-linux-gnu

If i try to set the correct gnu-system type i get this:

thomas@thomas-laptop:~/Desktop/dev/aMule-CVS-20070908/amule-cvs/debian$ dpkg-architecture -ai386 -ti686-linux-gnu
dpkg-architecture: warning: Default GNU system type i486-linux-gnu for Debian arch i386 does not match specified GNU system type i686-linux-gnu
dpkg-architecture: warning: Specified GNU system type i686-linux-gnu does not match gcc system type i486-linux-gnu.
DEB_BUILD_ARCH=i386
DEB_BUILD_ARCH_OS=linux
DEB_BUILD_ARCH_CPU=i386
DEB_BUILD_GNU_CPU=i486
DEB_BUILD_GNU_SYSTEM=linux-gnu
DEB_BUILD_GNU_TYPE=i486-linux-gnu
DEB_HOST_ARCH=i386
DEB_HOST_ARCH_OS=linux
DEB_HOST_ARCH_CPU=i386
DEB_HOST_GNU_CPU=i686
DEB_HOST_GNU_SYSTEM=linux-gnu
DEB_HOST_GNU_TYPE=i686-linux-gnu
thomas@thomas-laptop:~/Desktop/dev/aMule-CVS-20070908/amule-cvs/debian$


This is confusing me a lot!

So it seems that the problem is an "old" gcc Version which only can handle i486, is that right?

Thomas
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: Vollstrecker on September 09, 2007, 02:48:39 PM
gcc --version
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: tt-web on September 09, 2007, 02:54:13 PM
thomas@thomas-laptop:~/.aMule/Incoming$ gcc --version
gcc (GCC) 4.1.2 (Ubuntu 4.1.2-0ubuntu4)
Copyright (C) 2006 Free Software Foundation, Inc.
Dies ist freie Software; die Kopierbedingungen stehen in den Quellen. Es
gibt KEINE Garantie; auch nicht für MARKTGÄNGIGKEIT oder FÜR SPEZIELLE ZWECKE.
Title: Re: aMule CVS auf (k)ubuntu feisty
Post by: Vollstrecker on September 09, 2007, 06:51:48 PM
You know what sarcasm is?

I just found a german Link, but you should see the infos you want

http://debiananwenderhandbuch.de/dpkg-architecture.html