LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 06-17-2011, 04:29 AM   #1
tradet
LQ Newbie
 
Registered: May 2010
Posts: 20

Rep: Reputation: 0
File in wrong format while during Slackbuilds, 13.37 64bit with multilib


Hi,

I'm trying to build imlib2 and smpeg from the latest slackbuilds but I'm getting these errors:

Code:
smpeg: /usr/lib/libXext.so: could not read symbols: File in wrong format
imlib2: /usr/lib/libfreetype.so: could not read symbols: File in wrong format
I've installed Alien's multilib files (smpeg works in 32bit mode but I'd like to have the 64bit so I can build pygame in 64bit, imlib does not) but I think it's a 32/64 error somewhere and these errors appear to be related?

I have converted the packages:

Code:
$ ls /var/log/packages | grep freetype
freetype-2.4.4-x86_64-1
freetype-compat32-2.4.4-x86_64-1

$ ls /var/log/packages | grep libXext
libXext-1.2.0-x86_64-1
libXext-compat32-1.2.0-x86_64-1
And all multilibs appear to be installed:

Code:
$ ls /var/log/packages | grep multi
gcc-4.5.2_multilib-x86_64-2alien
gcc-g++-4.5.2_multilib-x86_64-2alien
gcc-gfortran-4.5.2_multilib-x86_64-2alien
gcc-gnat-4.5.2_multilib-x86_64-2alien
gcc-java-4.5.2_multilib-x86_64-2alien
gcc-objc-4.5.2_multilib-x86_64-2alien
glibc-2.13_multilib-x86_64-4alien
glibc-i18n-2.13_multilib-x86_64-4alien
glibc-profile-2.13_multilib-x86_64-4alien
glibc-solibs-2.13_multilib-x86_64-4alien
glibc-zoneinfo-2.13_multilib-noarch-4alien
I'm running Slackware 13.37 64bit on a fairly fresh install.

Help or ideas are appreciated.
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 06-17-2011, 04:49 AM   #2
sahko
Senior Member
 
Registered: Sep 2008
Distribution: Slackware
Posts: 1,041

Rep: Reputation: Disabled
I am the imlib2 maintainer. Please read the slackbuilds.org FAQ

Quote:
Originally Posted by http://slackbuilds.org/faq/#multilib
I have problems compiling with my unofficial and unsupported multilib setup.

If you are using multilib packages from somewhere and also have some 32bit packages installed, then you might run into problems with the build process trying to link 32bit libraries instead of 64bit libraries. If this occurs, it can probably be solved by placing the following line:
LDFLAGS="-L/usr/lib${LIBDIRSUFFIX}" \
after the lines for CFLAGS and CXXFLAGS passed to the configure script. In other words, make it look something like this:
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
LDFLAGS="-L/usr/lib${LIBDIRSUFFIX}" \
./configure \
Beyond that, you are on your own. This is an unsupported setup.
 
3 members found this post helpful.
Old 06-17-2011, 04:53 AM   #3
tradet
LQ Newbie
 
Registered: May 2010
Posts: 20

Original Poster
Rep: Reputation: 0
Ouch, my bad.

Thanks!
 
Old 06-17-2011, 04:56 AM   #4
sahko
Senior Member
 
Registered: Sep 2008
Distribution: Slackware
Posts: 1,041

Rep: Reputation: Disabled
It's not just you, you're the third person i have helped with the same issue and i've been maintaining imlib2 only for a month.
 
1 members found this post helpful.
Old 06-17-2011, 04:57 AM   #5
Mike_M
Member
 
Registered: Mar 2011
Location: California
Distribution: Slackware
Posts: 116

Rep: Reputation: 50
Quote:
Originally Posted by tradet View Post
Hi,

I'm trying to build imlib2 and smpeg from the latest slackbuilds but I'm getting these errors:

Code:
smpeg: /usr/lib/libXext.so: could not read symbols: File in wrong format
imlib2: /usr/lib/libfreetype.so: could not read symbols: File in wrong format
I've installed Alien's multilib files (smpeg works in 32bit mode but I'd like to have the 64bit so I can build pygame in 64bit, imlib does not) but I think it's a 32/64 error somewhere and these errors appear to be related?
Yes, this is related to having both 32-bit and 64-bit versions of the same libraries installed. It is possible the build procedure for the software you're attempting to compile can't deal with this gracefully. Generally when I run in to this, setting the LDFLAGS environment variable works around the issue for me. You can try something like this:

Code:
LDFLAGS="-L/usr/lib64" ./configure <rest of configure options here>
The approach I use is to add the following to my build scripts for misbehaving software just before the ./configure line:

Code:
LDFLAGS="-L/usr/lib${LIBDIRSUFFIX}" \
So it will end up looking something like this:

Code:
LDFLAGS="-L/usr/lib${LIBDIRSUFFIX}" \
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
   <configure options here>
edit: Oops, sahko beat me to it

Last edited by Mike_M; 06-17-2011 at 05:00 AM.
 
2 members found this post helpful.
Old 08-06-2011, 11:56 AM   #6
jjthomas
Member
 
Registered: Jan 2004
Location: Tacoma, WA
Distribution: Slackware 14
Posts: 242
Blog Entries: 2

Rep: Reputation: 28
Mike M, added LDFLAGS="-L/usr/lib${LIBDIRSUFFIX}" \ before the CFLAGS line and sahko added it after. Does where the line is added make a difference?


-JJ

Last edited by jjthomas; 08-06-2011 at 12:00 PM.
 
Old 08-06-2011, 11:59 AM   #7
jjthomas
Member
 
Registered: Jan 2004
Location: Tacoma, WA
Distribution: Slackware 14
Posts: 242
Blog Entries: 2

Rep: Reputation: 28
Quote:
Originally Posted by sahko View Post
It's not just you, you're the third person i have helped with the same issue and i've been maintaining imlib2 only for a month.
+1 Thank you for maintaining the project.

Google is my friend, LinuxQuestions is my best friend.

-JJ
 
Old 08-06-2011, 12:07 PM   #8
Mike_M
Member
 
Registered: Mar 2011
Location: California
Distribution: Slackware
Posts: 116

Rep: Reputation: 50
Quote:
Originally Posted by jjthomas View Post
Mike M, added LDFLAGS="-L/usr/lib${LIBDIRSUFFIX}" \ before the CFLAGS line and sahko added it after. Does where the line is added make a difference?


-JJ
No. Those lines are defining environment variables and assigning values to them. One does not rely on the other, so order does not matter.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Glade compile error, could not read symbols: File in wrong format Lethys Slackware 4 03-04-2011 04:51 AM
[SOLVED] Slackware 13 64bit: First time using SlackBuilds and unable to install programs. Switch7 Slackware 19 10-08-2009 09:26 AM
Fedora 7 64bit /usr/lib/libexpat.so: could not read symbols: File in wrong format GATTACA Fedora 1 06-21-2007 07:47 PM
/usr/lib/libfontconfig.so: could not read symbols: File in wrong format TrekJunky Linux - Newbie 2 10-01-2006 06:05 PM


All times are GMT -5. The time now is 08:23 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration