I've managed to get fuppes cross compiled for the PCH in the VM based toolchain setup by:
- Using the tool chain building instructions given in this post
- downloaded the source bundles for the dependent libraries (pcre, libxml2, sqlite3)
- sourced the toolchain-path.env in my build window.
[update: a compiled binary is available here.]
For each of the dependent libraries I build them using:
$ ./configure --host=mipsel-linux --disable-zlib --prefix=/home/user/popcorn/smp86xx_toolchain.20080505/build_mipsel_nofpu/staging_dir/
$ make
$ make install
This install the libs and header files into the /home/user/popcorn/smp86xx_toolchain.20080505/build_mipsel_nofpu/staging_dir/ folder under lib and include.. I think that is what I want (??) sounds fair.
Now this all feels good so far..
So I jump into the fuppes build dir and run:
$ ./configure --host=mipsel-linux -disable-transcoding --disable-zlib
This didn't work though, it couldn't find libpcre and libxml2 etc, even though I thought doing the make install (with the configure --prefix) was all that was required, anyway I found that I had to do a:
which points to the location of libpcre.pc etc for package... Anyone shed some light on my this is required? Or is that just normal when cross compiling?
Now I build again.
$ make
Close... It gets all they way to linking and fails with a misleading error about a missing file... Anyway, I found that the generated makefile in src/Makfile was not quite right. There is a line:
Is missing the -L and -lpcre... Anyone know what's going on here? Anyway, I needed to change it to:
Now I make again (with butchered Makefile):
Now... I have binaries in the .../fuppes/src/.lib dir that are built against the environment in the staging_dir.. How do I package this up to run on the PCH making sure that it finds the right libs (not the ones already on the PCH etc)..
Any ideas?
I have already tried just tgz'ing all the required libs and bins, putting them in a folder on the PCH then running:
$ ./fuppes
This appears to work for a few moments until it segfaults.. I expect (hoping) that it may be finding libxml2 and maybe other libs that already exist on the PCH but are not the ones compiled against (???)
Any ideas where I'm going wrong?
How do you people debug things like this (no gdb etc on the PCH, no strace).?
