aMule Forum

English => Compilation problems => Topic started by: Gaznevada on July 09, 2009, 10:03:52 PM

Title: Cross Compilation on Cygwin - Success
Post by: Gaznevada on July 09, 2009, 10:03:52 PM
Hi all,

the aMule Developers Team would probably be glad to know that aMule r9694 :

- cross-compile (almost) perfectly on --build=i686-pc-cygwin --host=mips-sgi-irix6.5
- runs with no problems on my IRIX box (up to now, I mean...)

and thanks god the amuleGUI-r9600 (formerly compiled on mingw ) connects nicely
with the remote server.

"Almost" perfectly, 'cause "cas" won't compile. I'm trying to dig out why. Otherwise this
"configure" gives me a workin' suite of aMule programs:

Code: [Select]
#!/bin/sh
export PKG_CONFIG_LIBDIR=/usr/mips-sgi-irix6.5/usr/local/lib/pkgconfig
export PATH=$PATH:/usr/local/mips-sgi-irix6.5/bin
export LDFLAGS='-L/usr/mips-sgi-irix6.5/usr/lib32 -L/usr/mips-sgi-irix6.5/usr/local/lib -L/usr/mips-sgi-irix6.5/usr/lib -L/usr/mips-sgi-irix6.5/lib'
export CPPFLAGS='-I/usr/mips-sgi-irix6.5/usr/include -I/usr/mips-sgi-irix6.5/usr/local/include'
export CFLAGS='-Wl,--rpath -Wl,/usr/local/lib:/usr/freeware/lib:/usr/freeware/lib32'
export CXXFLAGS=$CFLAGS
./configure --host=mips-sgi-irix6.5 --prefix=/usr/mips-sgi-irix6.5/usr/local \
--enable-webserver \
--enable-amule-daemon \
--enable-amule-gui \
--enable-amulecmd \
--disable-cas \
--enable-wxcas \
--enable-xas \
--enable-geoip \
--enable-ed2k \
--enable-alc \
--enable-alcc \
--enable-monolithic \
--disable-upnp \
--with-zlib=/usr/mips-sgi-irix6.5/usr/local/lib \
--with-gdlib-config=/usr/mips-sgi-irix6.5/usr/local/bin/gdlib-config \
--with-gdlib-prefix=/usr/mips-sgi-irix6.5/usr/local \
--with-libpng-config=/usr/mips-sgi-irix6.5/usr/local/bin/libpng-config \
--with-libpng-prefix=/usr/mips-sgi-irix6.5/usr/local \
--with-wx-config=/usr/mips-sgi-irix6.5/usr/local/bin/wx-config \
--with-wx-prefix=/usr/mips-sgi-irix6.5/usr/local \
--with-wx-exec-prefix=/usr/mips-sgi-irix6.5/usr/local \
--with-libiconv-prefix=/usr/mips-sgi-irix6.5/usr/local \
--with-crypto-prefix=/usr/mips-sgi-irix6.5/usr/local \
--with-geoip-headers=/usr/mips-sgi-irix6.5/usr/local/include \
--with-geoip-lib=/usr/mips-sgi-irix6.5/usr/local/lib \
--with-libintl-prefix=/usr/mips-sgi-irix6.5/usr/local \
--with-denoise-level=0 \
--with-language=en_GB,it

make install


Made it the hard way: starting from Toolchain (a real pain, you have to add stanzas
for c++ in the .m4 files and reconfigure all the stuff)
and cross-compiling from source all the needed libraries. Honestly, I feel myself
satisfied  ;D

But the best thing is a compilation time of 21'49'', that is to say about one hundred
faster than the required time on my O2.

Time to get a beer  ;D

Cheers,

--
Gaznevada
Title: Re: Cross Compilation on Cygwin - Success
Post by: Stu Redman on July 09, 2009, 10:20:17 PM
Thank you for the feedback!

You can download a compiled Windows remote gui here (http://amule.jimdo.com/).
Title: Re: Cross Compilation on Cygwin - Success
Post by: wuischke on July 09, 2009, 10:29:57 PM
Quote
Made it the hard way
:o
Quote
Time to get a beer
I believe you deserve at least two for this feat. ;)

Quote
"Almost" perfectly, 'cause "cas" won't compile. I'm trying to dig out why.
Please keep us posted. Your contributions to making aMule compatible to more platforms have been very valuable.
Title: Re: Cross Compilation on Cygwin - Success
Post by: Gaznevada on July 09, 2009, 10:35:28 PM
Thank you for the feedback!

You can download a compiled Windows remote gui here (http://amule.jimdo.com/).

I forgot to thank wuischke and GonoszTopi for their hints. Thanks a lot, really.

BTW:  just a detail. I have had to transfer all the installed files in a very ugly way,
like

Code: [Select]
# touch Install_timestamp
# make install
# find /usr/mips-sgi-irix6.5/usr/local -newer Install_timestamp -type f | xargs tar -rvf Packaged_tarball.tar

and then transferring the tarfile to the O2. It would be nice to add a target like, let's say,
"packaged-install" in Makefile to make the life easier. Just a suggestion...

Cheers,

--
Gaznevada
Title: Re: Cross Compilation on Cygwin - Success
Post by: Gaznevada on July 09, 2009, 10:41:42 PM
Please keep us posted. Your contributions to making aMule compatible to more platforms have been very valuable.

Sure, of course!

A friend of mine gave me as a gift an old Sun SparcStation5. The PizzaBox.
What a pity aMule is already ported to Solaris  :D

Cheers,

--
Gaznevada



Title: Re: Cross Compilation on Cygwin - Success
Post by: wuischke on July 10, 2009, 07:30:46 AM
I usually do a "make DESTDIR=$PKGDIR install" and then create a tarball of the content of $PKGDIR.
Title: Re: Cross Compilation on Cygwin - Success
Post by: Gaznevada on July 27, 2009, 12:22:07 PM
Please keep us posted. Your contributions to making aMule compatible to more platforms have been very valuable.

Found the "bug". My fault, it was a glitch in gd cross-compilation -not exactly a masterpiece of
clarity of expression in cross-compilation instructions-, nothing related to aMule
itself. Rebult libraries and aMule, "cas" is now working like a breeze.

Cheers,

--
Gaznevada




Title: Re: Cross Compilation on Cygwin - Success
Post by: skolnick on August 10, 2009, 06:56:10 AM
A friend of mine gave me as a gift an old Sun SparcStation5. The PizzaBox.
What a pity aMule is already ported to Solaris  :D
Hi Gaznevada

I believe the last time I tried to compile a SVN aMule on my solaris, it failed. I was pretty tired at that moment, so I didn't take a look deeper, but I will probably next weeked. Also, since my solaris is now a virtual machine under VMware, i cannot test SPARC architecture. (note to self: get friends who giveaway SPARC boxes)

Regards.
Title: Re: Cross Compilation on Cygwin - Success
Post by: Gaznevada on August 19, 2009, 10:47:17 PM
Also, since my solaris is now a virtual machine under VMware, i cannot test SPARC architecture. (note to self: get friends who giveaway SPARC boxes)

Hi skolnick,

I'm afraid my tests on a real SPARC architecture will take a while. I can't even bootstrap the machine. No wonder my friend gave it away as a gift. Probably proper disposal was too much a hassle for him, I suppose.

The moral of the story: while looking for friends giving away SPARC boxes, better being picky.

Cheers,

--
Gaznevada