LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-13-2011, 03:35 PM   #1
Joe72
LQ Newbie
 
Registered: Mar 2007
Location: Frankfurt, Germany
Distribution: Open SuSE12.2, Debian Squeeze
Posts: 11

Rep: Reputation: 5
[SOLVED] rpmbuild does not create lib64 in correct path


Hi guys,

I am trying to install OpenCV2.2.0 from the sources and to make it easier in the future I want to create a rpm on my OpenSuse 11.2 x86_64 platform. The instructions how to install are in the specfile

The relevant parts of the specfile below:

Code:
---snipp
%prep
%setup
%build
mkdir release
cd release
cmake -DCMAKE_BUILD_TYPE=RELEASE -DCMAKE_INSTALL_PREFIX=`kde4-config --prefix` -DLIB_INSTALL_DIR:PATH=%{_libdir} -DBUILD_PYTHON_SUPPORT=ON ..

%install
cd release
%makeinstall

%clean
rm -rf $RPM_BUILD_ROOT
---snipp
What happens when I try to run

Code:
rpmbuild -bi OpenCV.spec
is I get the following message

Code:
+ /usr/lib/rpm/brp-lib64-linux
sf@suse.de: if you find problems with this script, drop me a note
/home/oliver/rpmhome/BUILDROOT/OpenCV-2.2.0-1joec2d.x86_64/usr/lib/libopencv_objdetect.so:     file format elf64-x86-64
/home/oliver/rpmhome/BUILDROOT/OpenCV-2.2.0-1joec2d.x86_64/usr/lib/libopencv_objdetect.so: should be in */lib64
error: Bad exit status from /home/oliver/rpmhome/tmp/rpm-tmp.5zQNS9 (%install)
What I understand is the libs are in /usr/lib instead of /usr/lib64 so I spent some time and asked google but just found hints to use the cmake flag LIB_INSTALL_DIR. Unfortunately that is not the solution. Can anyone give me a hint at which point I am going wrong? Thanks

Last edited by Joe72; 05-15-2011 at 03:57 AM. Reason: problem solved
 
Old 05-13-2011, 04:10 PM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Welcome to LQ.

OpenCV is available from the Packman repo :
# zypper ar -f -n packman-essentials http://packman.inode.at/suse/openSUSE_11.2/Essentials packman-essentials
→ → http://en.opensuse.org/Additional_package_repositories

# zypper in opencv : Will install version 2.2.0
( libopencv2_2-2.2.0-1.pm.12.58.x86_64 , opencv-2.2.0-1.pm.12.58.x86_64 )
... And provide /usr/lib64/libopencv_***


If you want to build a package yourself, the Suse 11.2 SRC.RPM is here
http://packman.iu-bremen.de/suse/11.2/Essentials/src/
http://packman.iu-bremen.de/suse/11.....12.58.src.rpm

P.S. : Suse 11.2 had end of life yesterday : 12 May 2011.

..

Last edited by knudfl; 05-13-2011 at 04:30 PM.
 
Old 05-15-2011, 03:54 AM   #3
Joe72
LQ Newbie
 
Registered: Mar 2007
Location: Frankfurt, Germany
Distribution: Open SuSE12.2, Debian Squeeze
Posts: 11

Original Poster
Rep: Reputation: 5
[solved]

Hi Knudfl,

Quote:
Originally Posted by knudfl View Post
Welcome to LQ.

OpenCV is available from the Packman repo :

..
Thanks! I've been reading for a long time, this was just my first post :-). I will take it from there

Quote:
If you want to build a package yourself, the Suse 11.2 SRC.RPM is here
http://packman.iu-bremen.de/suse/11.2/Essentials/src/
According to the patches my problem was in the cmakelists.txt. The path to lib was set statically to lib instead of checking the platform. Thanks a lot, I was just surprised that that patch is available for SuSE but on the download site of the project it is not in the sources ???

Quote:
P.S. : Suse 11.2 had end of life yesterday : 12 May 2011.
I know, its time to touch a running system again
 
  


Reply



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
[SOLVED] Move a file to some path and create that path when it doesn't exist WhisperiN Linux - Newbie 6 10-09-2010 11:47 AM
Create a package out of an Installation, preserving the correct path Alexvader Slackware 5 12-21-2009 05:49 PM
Relocat /usr/lib and /usr/lib64 to a different path schokshi Fedora 3 08-30-2005 09:14 PM
which is the correct directory path? verbatim Programming 1 04-24-2005 11:22 PM
please tell me if my path statement is correct on RH 7.3 ergo_sum Linux - Newbie 9 12-12-2003 11:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:47 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
Open Source Consulting | Domain Registration