LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
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 09-09-2013, 06:45 AM   #1
saman_artorious
Member
 
Registered: Sep 2008
Posts: 78

Rep: Reputation: 1
how to install a library via .so


I have two ways to install packages:
1.
Code:
apt-get install package_name
2.I downloaded the compressed source, inside there are two folders DEBIAN and opt.
Code:
packages/libjpeg-turbo-official32_1.3.0_amd64/opt/libjpeg-turbo/lib3
inside this directory there are .so and .a files. How can I install these files on my system? where should I copy them?

I tried copying them in /usr/lib32 and added this path to ld.so.conf with ldconfig. but it had no effect.

what is your opinion?


Edit: I could some the error I was received ragarding undefined references to functions by copying .a library and adding it directly to my program. what does it work in this case and not in the previous case?

Last edited by saman_artorious; 09-09-2013 at 07:01 AM.
 
Old 09-09-2013, 08:09 AM   #2
pan64
Senior Member
 
Registered: Mar 2012
Location: Hungary
Distribution: debian i686 (solaris)
Posts: 4,500

Rep: Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221
it looks like you mixed the 32bit and 64bit system. Which one do you really need? Which one was installed?
 
Old 09-09-2013, 08:23 AM   #3
saman_artorious
Member
 
Registered: Sep 2008
Posts: 78

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by pan64 View Post
it looks like you mixed the 32bit and 64bit system. Which one do you really need? Which one was installed?
my system is 32-bit. the package as it appears is also for 32 bit system.
 
Old 09-09-2013, 08:28 AM   #4
pan64
Senior Member
 
Registered: Mar 2012
Location: Hungary
Distribution: debian i686 (solaris)
Posts: 4,500

Rep: Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221Reputation: 1221
no, the package name contains amd64. Or maybe I missed something?
 
Old 09-09-2013, 11:27 AM   #5
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2014, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,522

Rep: Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503
All the "libjpeg-turbo-official_1.3.0" packages are here ..
http://sourceforge.net/projects/libj...o/files/1.3.0/

Are you sure you have got the right package for your OS ?
Specifying your OS : 1) $ uname -m <Enter>
2) $ cat /etc/issue <Enter>

Your "libjpeg-turbo-official32_1.3.0_amd64"
contains 32bits compatibility libraries for a 64bits OS, I guess.

?? What did you download ?? A package name and a link, please.

-
 
Old 09-11-2013, 02:55 AM   #6
saman_artorious
Member
 
Registered: Sep 2008
Posts: 78

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by knudfl View Post
All the "libjpeg-turbo-official_1.3.0" packages are here ..
http://sourceforge.net/projects/libj...o/files/1.3.0/

Are you sure you have got the right package for your OS ?
Specifying your OS : 1) $ uname -m <Enter>
2) $ cat /etc/issue <Enter>

Your "libjpeg-turbo-official32_1.3.0_amd64"
contains 32bits compatibility libraries for a 64bits OS, I guess.

?? What did you download ?? A package name and a link, please.

-
I downloaded libjpeg-turbo-official32_1.3.0_amd64 and not 1.3.0_i386.deb. It is also the second link in the address you referenced. However, is it is also not compatible with /usr/lib32 then how come it is working fine when I added the .a library to my program source as an external library?


UPDATE: I downloaded this http://sourceforge.net/projects/libjpeg-turbo/

Last edited by saman_artorious; 09-11-2013 at 02:56 AM.
 
Old 09-11-2013, 03:08 AM   #7
evo2
Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Debian, SL
Posts: 5,103

Rep: Reputation: 1102Reputation: 1102Reputation: 1102Reputation: 1102Reputation: 1102Reputation: 1102Reputation: 1102Reputation: 1102Reputation: 1102
Hi,

if your machine is running a 32bit OS then you want the i386 file not the amd64 download. The easiest thing to do is probably to download the i386 .deb and then install it with "dpkg -i". However since you have not told us what os and version you are using*, there may be a better way.

Evo2.

* Am assuming some version of Ubuntu or derivative.
 
Old 09-11-2013, 03:45 AM   #8
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian Jessie / sid
Posts: 1,330

Rep: Reputation: 400Reputation: 400Reputation: 400Reputation: 400Reputation: 400
read the readme

http://sourceforge.net/projects/libj...o/files/1.3.0/

especially [2] Overhauled the packaging system:

below is basically just a reiteration of previous posts...


if you have 32bit
dpkg -i libjpeg-turbo-official_1.3.0_i386.deb


if you have 64Bit

dpkg -i libjpeg-turbo-official_1.3.0_amd64.deb

if you have 32Bit software that depends on libjpeg-turbo, also install

dpkg -i libjpeg-turbo-official32_1.3.0_amd64.deb

as far as I remember Ubuntu is Multilib 'out of the box'
if 64Bit it will do no harm to install both.. will just take up space
 
Old 09-11-2013, 08:27 AM   #9
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2014, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,522

Rep: Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503
I.e. you will have to specify your OS, if you want an answer.

Please show the output from the commands
1) $ uname -m <Enter>
2) $ cat /etc/issue <Enter>

( Ref. post #5.)

-
 
Old 09-12-2013, 12:37 AM   #10
saman_artorious
Member
 
Registered: Sep 2008
Posts: 78

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by knudfl View Post
I.e. you will have to specify your OS, if you want an answer.

Please show the output from the commands
1) $ uname -m <Enter>
2) $ cat /etc/issue <Enter>

( Ref. post #5.)

-
Code:
 uname -m
i686
Code:
cat /etc/issue
Ubuntu 12.04.2 LTS \n \l
 
Old 09-12-2013, 01:16 AM   #11
Firerat
Senior Member
 
Registered: Oct 2008
Distribution: Debian Jessie / sid
Posts: 1,330

Rep: Reputation: 400Reputation: 400Reputation: 400Reputation: 400Reputation: 400
you have 32bit

dpkg -i libjpeg-turbo-official_1.3.0_i386.deb

confusing,, as it is i386 and not i686
 
  


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
install from source - unable to find the libcurl library - but library is installed pulper Linux - Newbie 2 02-23-2009 09:00 PM
install a library yumener Linux - Software 6 01-13-2007 04:39 AM
How to install Library? vanhelsing Programming 23 07-10-2004 07:31 PM
gd library install. eye Linux - Software 0 10-15-2003 11:11 AM
I can't install this library carlcromer Linux - Newbie 2 07-01-2002 11:03 PM


All times are GMT -5. The time now is 03:40 PM.

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