Author Topic: How Do I Add Libs To The Cross Compiler?  (Read 2967 times)

Capn_Fish

  • Hero Member
  • *****
  • Posts: 2342
    • View Profile
    • http://
How Do I Add Libs To The Cross Compiler?
« on: September 25, 2006, 08:45:04 pm »
I am running Ubuntu 6.06.1 with the Beta1 cross compiler. I am trying to compile VisualBoy Advance, but it wants libpng. I have it installed, but the compiler can't find it. How do I make it recognize this library?

Thanks.
SL-C750- pdaXrom beta 1 (mostly unused)
Current distro: Gentoo

pgas

  • Hero Member
  • *****
  • Posts: 1097
    • View Profile
    • http://
How Do I Add Libs To The Cross Compiler?
« Reply #1 on: September 26, 2006, 04:39:26 am »
change the prefix during configure so that it installs the libs in /opt/cross.../
or
move the headers and .so files manually together with the other libs and headers
SLC-860 cacko / senao wifi

Antikx

  • Hero Member
  • *****
  • Posts: 1147
    • View Profile
    • http://tyrannozaurus.com
How Do I Add Libs To The Cross Compiler?
« Reply #2 on: September 26, 2006, 07:07:43 am »
Quote
I am running Ubuntu 6.06.1 with the Beta1 cross compiler. I am trying to compile VisualBoy Advance, .
[div align=\"right\"][a href=\"index.php?act=findpost&pid=142299\"][{POST_SNAPBACK}][/a][/div]
ohhh.. this sounds interesting.
Kanpai,
-Antikx (Twitter, Mugshot and PodNova)
C1000 - pdaXrom R198 (Celestial Environment)
tyrannozaurus.com
[img]http://www.tyrannozaurus.com/files/category_pictures/general_1.png\" border=\"0\" class=\"linked-sig-image\" /]
Zaurus news/blogs feed from Zaurus users
Free Windows, Linux, or Web RSS readers.
Featured pages at tyrannozaurus:
Sharp Petition, ScummVM, Cacko, pdaXii13, and Celestial Environment

Capn_Fish

  • Hero Member
  • *****
  • Posts: 2342
    • View Profile
    • http://
How Do I Add Libs To The Cross Compiler?
« Reply #3 on: September 26, 2006, 07:41:44 am »
I copied four or so files like "libxxx.so.x.x.x", three of which were symbolic links, and it till didn't work. Do I have to delete them from /usr/lib as well or edit any files?

Thanks.
SL-C750- pdaXrom beta 1 (mostly unused)
Current distro: Gentoo

pgas

  • Hero Member
  • *****
  • Posts: 1097
    • View Profile
    • http://
How Do I Add Libs To The Cross Compiler?
« Reply #4 on: September 26, 2006, 08:24:45 am »
you have to tell more about what you do and what error you get
SLC-860 cacko / senao wifi

Meanie

  • Hero Member
  • *****
  • Posts: 2803
    • View Profile
    • http://www.users.on.net/~hluc/myZaurus/
How Do I Add Libs To The Cross Compiler?
« Reply #5 on: September 26, 2006, 10:47:02 am »
in some cases you will need to compile two versions of the library, one native library (for the host architecture) and one cross compiled for the zaurus. the cross compiled libraries need to go under /opt/cross/.../armv5tel-linux/lib.
you also need to make sure you put the .pc file for your libary into the pkgconfig directory and/or the -config files under the bin directory of native/cross environment with the references to where to find the libraries updated to refer to the right location
SL-C3000 - pdaXii13 build5.4.9 (based on pdaXrom beta3) / SL-C3100 - Sharp ROM 1.02 JP (heavily customised)
Netgear MA701 CF, SanDisk ConnectPlus CF, Socket Bluetooth CF, 4GB Kingston CF,  4GB pqi SD, 4GB ChoiceOnly SD, 2GB SanDisk SD USB Plus, 1GB SanDisk USB Plus, 1GB Transcend SD, 2GB SanDisk MicroSD with SD adaptor, Piel Frama Leather Case, GoldX 5-in-1 USB cable, USB hub, USB mouse, USB keyboard, USB ethernet, USB HDD, many other USB accessories...
(Zaurus SL-C3000 owner since March 14. 2005, Zaurus SL-C3100 owner since September 21. 2005)
http://members.iinet.net.au/~wyso/myZaurus - zBook3K

Capn_Fish

  • Hero Member
  • *****
  • Posts: 2342
    • View Profile
    • http://
How Do I Add Libs To The Cross Compiler?
« Reply #6 on: September 26, 2006, 02:19:30 pm »
pgas: I simply (as root) do a #CC=armv5tel-cacko-linux-gcc ./configure --host=armv5tel-cacko-linux --build=i686-linux --disable-sound", and I get

"checking for png_create_write_struct in -lpng... no
configure: error: *** Cannot compile without libpng."

Meanie: Could you explain what you mean? I take it I have to copy the libs from my Zaurus to the .../lib directory of the cross compiler as well as edit some files. Could you walk me through that?

Thanks
« Last Edit: September 26, 2006, 02:21:16 pm by Capn_Fish »
SL-C750- pdaXrom beta 1 (mostly unused)
Current distro: Gentoo