LinuxQuestions.org
Help answer threads with 0 replies.
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 11-30-2010, 12:40 PM   #1
ahmadj
Member
 
Registered: Jun 2010
Distribution: Slackware64_13.37 \ Slackware_13.1 \ ARMedslack_13.37
Posts: 80

Rep: Reputation: 16
Problem with OpenCASCADE SBo on 64-13.1


Hi,

I'm trying to install OpenCASCADE via the slackbuilds.org script

The build runs fine, until a point, where it halts with the error: /usr/lib/libXext.so: could not read symbols: File in wrong format

ie. it is trying to use a the 32-bit libXext instead of the 64-bit one. I have checked the SlackBuild script and it seems to my eyes that the libraries are set correctly to use the libdirsuffix; indeed, all the libraries until this point in the compile are sourced correctly for /usr/lib64, so why is it looking in /usr/lib for this one? And how do I fix it?

I should also mention that I'm doing this through sbopkg as opposed to manually from console..
 
Old 12-01-2010, 04:58 AM   #2
niels.horn
Senior Member
 
Registered: Mar 2007
Location: Rio de Janeiro - Brazil
Distribution: Slackware64-current
Posts: 1,004

Rep: Reputation: 89
Hi,

Unfortunately I do not have a multilib system to test this for you.

Can you tell me at what point exactly it stops building?
It might be that some Makefile of some module looks at both /usr/lib and /usr/lib64.

I'm working on a new version of the SlackBuild for OpenCASCADE 6.4, but it is not very high on my priority list...

Niels
 
Old 12-01-2010, 06:05 AM   #3
ahmadj
Member
 
Registered: Jun 2010
Distribution: Slackware64_13.37 \ Slackware_13.1 \ ARMedslack_13.37
Posts: 80

Original Poster
Rep: Reputation: 16
Thanks for the reply, Nils,

I'm unsure exactly how to pinpoint where the error occurs. I'm re-running the compile now and will attach a screenshot here once it fails.. would that help?

I wish to run the latest version (10.xx) of FreeCAD... do you know if I would need OpenCASCADE 6.4 for that, or would 6.3 be OK?
 
Old 12-01-2010, 06:12 AM   #4
niels.horn
Senior Member
 
Registered: Mar 2007
Location: Rio de Janeiro - Brazil
Distribution: Slackware64-current
Posts: 1,004

Rep: Reputation: 89
It would be best to paste the output of the build, to see where the error occurs. But a screenshot (as long as it shows the error) might help.

I tried FreeCAD 1.0x a while ago and it worked fine with OpenCASCADE 6.3.

Niels
 
1 members found this post helpful.
Old 12-01-2010, 06:42 AM   #5
ponce
Senior Member
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 2,504

Rep: Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912
FYI, tried (for fun ) to build it on -current multilib with sp9 instead of 6 and all went well.

but, if it's a link-time error, could be also that, on multilib, forcing LDFLAGS in a line before the CFLAGS' one in the slackbuild could do, like this
Code:
...
autoreconf -f -i

LDFLAGS="-L/usr/lib64 -L/lib64" \
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
...

Last edited by ponce; 12-01-2010 at 06:53 AM.
 
1 members found this post helpful.
Old 12-01-2010, 08:37 AM   #6
ahmadj
Member
 
Registered: Jun 2010
Distribution: Slackware64_13.37 \ Slackware_13.1 \ ARMedslack_13.37
Posts: 80

Original Poster
Rep: Reputation: 16
Thank you both.

Here is a paste of the error:
Quote:
/tmp/SBo/OpenCASCADE6.3.0/ros/adm/make/TKMath/.libs/libTKMath.so /tmp/SBo/OpenCASCADE6.3.0/ros/adm/make/TKernel/.libs/libTKernel.so -ldl -lpthread -L/usr/lib64/gcc/x86_64-slackware-linux/4.4.4 -L/usr/lib/gcc/x86_64-slackware-linux/4.4.4 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/lib64/gcc/x86_64-slackware-linux/4.4.4/../../../../x86_64-slackware-linux/lib -L/usr/lib64/gcc/x86_64-slackware-linux/4.4.4/../../.. /usr/lib64/../lib64/libstdc++.so -lm -lc -lgcc_s /usr/lib64/gcc/x86_64-slackware-linux/4.4.4/crtendS.o /usr/lib64/gcc/x86_64-slackware-linux/4.4.4/../../../../lib64/crtn.o -Wl,-soname -Wl,libTKXSDRAW-6.3.0.so -o .libs/libTKXSDRAW-6.3.0.so
/usr/lib/libXext.so: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make[3]: *** [libTKXSDRAW.la] Error 1
make[3]: Leaving directory `/tmp/SBo/OpenCASCADE6.3.0/ros/adm/make/TKXSDRAW'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/tmp/SBo/OpenCASCADE6.3.0/ros/adm/make'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/tmp/SBo/OpenCASCADE6.3.0/ros'
make: *** [all] Error 2
I will try out Ponce's suggestions...
 
Old 12-01-2010, 01:53 PM   #7
ahmadj
Member
 
Registered: Jun 2010
Distribution: Slackware64_13.37 \ Slackware_13.1 \ ARMedslack_13.37
Posts: 80

Original Poster
Rep: Reputation: 16
Quote:
Originally Posted by ponce View Post
but, if it's a link-time error, could be also that, on multilib, forcing LDFLAGS in a line before the CFLAGS' one in the slackbuild could do
This worked, thanks!
 
Old 12-01-2010, 02:06 PM   #8
niels.horn
Senior Member
 
Registered: Mar 2007
Location: Rio de Janeiro - Brazil
Distribution: Slackware64-current
Posts: 1,004

Rep: Reputation: 89
OK, I'll test this when I get home and - if it does not cause any problems on "standard" Slackware, I'll include it in the update for OCC 6.4.

Niels
 
Old 12-02-2010, 06:50 AM   #9
ponce
Senior Member
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 2,504

Rep: Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912
this got into a bloodbath (at least for me, hope I am not too OT ): I've gone on building FreeCAD (and deps) on -current multilib and I stumbled in this while building FreeCAD itself
Code:
ld: cannot find -ljscore
I looked around a little and what I seem to have found is: if you run configure of qt-4.7.0 activating webkit, when you run make it actually builds libjscore.a and libjscore.prl, but the make install forgets about it and doesn't copy them in the $PKG folder. (looks like there are other reports)
so I hacked qt.SlackBuild a little
Code:
@@ -184,6 +184,13 @@
   done
 )
 
+# seems make install forgot about these
+cp src/3rdparty/webkit/JavaScriptCore/release/libjscore.* $PKG/usr/lib${LIBDIRSUFFIX}/qt/lib
+
+# fix wrong hardcoded build paths in pkgconfig and *.prl files
+sed -i "s,$TMP/qt-$VERSION,/usr/lib${LIBDIRSUFFIX}/qt,g" $PKG/usr/lib${LIBDIRSUFFIX}/pkgconfig/*.pc
+sed -i "s,$TMP/qt-$VERSION,/usr/lib${LIBDIRSUFFIX}/qt,g" $PKG/usr/lib${LIBDIRSUFFIX}/qt/lib/*.prl
+
 # Add a documentation directory:
 mkdir -p $PKG/usr/doc/$PKGNAM-$VERSION
 cp -a *GPL_EXCEPTION* FAQ* INSTALL KNOWN* LICENSE* README* changes-* \
(I spotted the second fix here)
and with the rebuilt qt he got its libjscore and was happy (for the moment).

But, as I am on multilib, another bugger arised: the linker refused to link /usr/lib64/../lib/libstdc++.so.
This is obvious, is a 32bit library, but I wasn't able to get where in his build configuration file was constructing this wrong path (that can happen if you don't know where to look :P )

I tried with the LDFLAGS trick but my ld-fu wasn't strong enough.

then I stumbled in this nice message and tried the LDEMULATION triple-kick, but it laughed at me.

as a last resort, I tried the second suggestion that Master Ken cite in the message above, and punched him indaface changing the linker
Code:
@@ -57,6 +58,7 @@
 
 ./autogen.sh
 
+LD='gcc ${BUILD64}' \
 CFLAGS="$SLKCFLAGS" \
 CXXFLAGS="$SLKCFLAGS" \
 ./configure \
and that fixed him for good

for the record, I was trying this later linker stuff with FreeCAD 0.10.3205 and had to do other modifications to the slackbuild (turned off debug too): result is a not-so-much working FreeCAD, because it cannot find any module (but I'll have a look on that too. It's like Terminator: you think you got him but he gets back on his feet ).

sorry for the long post but maybe it's useful to know about it.

P.S. happy note: after that qt fiddling, I made also a qt-4.7.1 (from the corresponding branch) package and is running nice on my desktop with alien's kde.

Last edited by ponce; 01-29-2011 at 03:41 AM. Reason: fixed libjscore library name
 
Old 12-02-2010, 04:11 PM   #10
ppr:kut
Slackware Contributor
 
Registered: Aug 2006
Location: Netherlands
Distribution: Slackware
Posts: 370

Rep: Reputation: 98
Quote:
Originally Posted by niels.horn View Post
OK, I'll test this when I get home and - if it does not cause any problems on "standard" Slackware, I'll include it in the update for OCC 6.4.

Niels
See http://www.slackbuilds.org/faq/#multilib
As long as it's only that simple LDFLAGS modification, it won't survive the review process
 
Old 12-02-2010, 04:52 PM   #11
niels.horn
Senior Member
 
Registered: Mar 2007
Location: Rio de Janeiro - Brazil
Distribution: Slackware64-current
Posts: 1,004

Rep: Reputation: 89
ppr:kut: OK...

I don't use multilib. I use "pure" 64-bits.
If something does not run on 64-bits means that it's badly written or it's a closed-source binary - and I want nothing to do with either.
 
Old 12-02-2010, 05:37 PM   #12
ppr:kut
Slackware Contributor
 
Registered: Aug 2006
Location: Netherlands
Distribution: Slackware
Posts: 370

Rep: Reputation: 98
Well, not really. The LDFLAGS issue is quite common, and most likely affects quite some amount of scripts on SlackBuilds.org, hence the FAQ entry

The only things I tend to fix/report are if the script doesn't succeed with only multilib gcc/glibc installed, because 99% of the scripts do. But that's already pretty borderline stuff for SBo.
 
Old 12-03-2010, 06:13 AM   #13
ahmadj
Member
 
Registered: Jun 2010
Distribution: Slackware64_13.37 \ Slackware_13.1 \ ARMedslack_13.37
Posts: 80

Original Poster
Rep: Reputation: 16
Very nice work, Ponce. I haven't got around to FreeCAD yet.. man that looks nightmarish.

May I ask whose Slackbuild you started off with for Qt 4.7? And how much extra work is it to get a working FreeCAD 10.xx?
 
Old 12-03-2010, 06:32 AM   #14
ozanbaba
Member
 
Registered: May 2003
Location: Tengiz
Distribution: Slackware64 14.1
Posts: 671

Rep: Reputation: 94
Lte me drop a link for SlackBuilds.Org FAQ for multilib systems:
http://www.slackbuilds.org/faq/#multilib
 
Old 12-03-2010, 07:57 AM   #15
ponce
Senior Member
 
Registered: Aug 2004
Location: Pisa, Italy
Distribution: Slackware
Posts: 2,504

Rep: Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912Reputation: 912
Quote:
Originally Posted by ahmadj View Post
Very nice work, Ponce. I haven't got around to FreeCAD yet.. man that looks nightmarish.
yes, but without trying to do it I wouldn't have found that qt thingie

Quote:
May I ask whose Slackbuild you started off with for Qt 4.7? And how much extra work is it to get a working FreeCAD 10.xx?
for qt you can use the standard one (adding that "cp src..." as shown in the patch above)

if you want to try 4.7.1, as written in the slackbuild, it's using the kde-qt branches on gitorious, so
Code:
git clone git://gitorious.org/+kde-developers/qt/kde-qt.git
QTVER=4.7.1
cd kde-qt
git archive origin/$QTVER-patched > ../tmp.tar
git checkout origin/$QTVER-patched
QTCOMMIT=$( git log -1 | head -1 | cut -c 8-14 )
mkdir ../qt-${QTVER}_${QTCOMMIT}
cd ../qt-${QTVER}_${QTCOMMIT}
tar xf ../tmp.tar
cd ..
rm tmp.tar
tar Jcf qt-${QTVER}_${QTCOMMIT}.tar.xz qt-${QTVER}_${QTCOMMIT}
at the end you will have two folder, kde-qt and qt-4.7.1_somecommit, and a qt-4.7.1_somecommit.tar.xz: put this one in the qt build folder instead on the qt-4.7.0*.tar.xz and launch the build.

for the "working" freecad cannot tell yet cause here still cannot see its mods

Last edited by ponce; 12-03-2010 at 08:07 AM.
 
  


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
Opencascade RPM for centOS Alexvader Red Hat 13 11-18-2010 10:07 AM
[SOLVED] Many sbo repository errors rm%rf Slackware 3 09-23-2010 03:56 PM
installing mpd 0.15.8 from SBo dumdadum Slackware 3 04-14-2010 10:22 AM
Building OpenCascade in Slackware64 13 Alexvader Slackware 2 03-21-2010 11:21 PM
Opera 10.01 in SBo hitest Slackware 2 11-09-2009 03:14 PM


All times are GMT -5. The time now is 06:10 PM.

Main Menu
Advertisement
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