99ac 32 bit libpq.so on 64 host - The FreeBSD Forums
The FreeBSD Forums  

Go Back   The FreeBSD Forums > Ports & Packages > Porting New Software

Porting New Software Having trouble or general questions about porting software to FreeBSD? Ask here.

Reply
 
Thread Tools Display Modes
  #1  
Old January 11th, 2013, 09:13
jaromir jaromir is offline
Junior Member
 
Join Date: Jan 2013
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default 32 bit libpq.so on 64 host

Hello,

This is my first post here so greetings for everyone !

So I have to say that I'm software developer (windows mainly) not FreeBSD administrator so BSD world for me is not well known.

I need to run one of my application on FreeBSD 9.1 64 bit. This app is compiled by FPC 32 bit due to inner 64 bit compatibility problems.

Application start and run properly but the problem is with PostgreSQL access. Because this app use libpq.so (I can't change this) and this is 32 bit - standard libpq.so located at /usr/local/lib/ (which is 64 bit) can't be used of course. So I place 32 bit libpq.so at /usr/lib32 and my application load this properly (You can place this lib on other place and add path by ldconfig - this works too).

Unfortunately from this point I have big trouble. My app give error about wrong version (64 bit) of libintl.so.9 - this is understood.

So on my libpq.so 32 bit I ran:

ldd libpq.so

and the result is:
Code:
        libintl.so.9 => not found (0)
        libssl.so.6 => not found (0)
        libcrypto.so.6 => /usr/lib32/libcrypto.so.6 (0x281cb000)
        libthr.so.3 => /usr/lib32/libthr.so.3 (0x28327000)
        libc.so.7 => /usr/lib32/libc.so.7 (0x2806c000)
So I took libintl.so.9 from 32 bit os version and placed next to libpq.so at /usr/lib32. And this is my problem. Wherever I place this lib above - ldd looks like this. This 32 lib version can't be found - I tried every path which is possible and it doesn't work.

It looks like only place where this lib can be placed is /usr/local/lib path. When I temporary place my 32 libintl at this path ldd looks like this:
Code:
ldd libpq.so:
        libintl.so.9 => /usr/local/lib/libintl.so.9 (0x281cb000)
        libssl.so.6 => not found (0)
        libcrypto.so.6 => /usr/lib32/libcrypto.so.6 (0x281d4000)
        libthr.so.3 => /usr/lib32/libthr.so.3 (0x28330000)
        libc.so.7 => /usr/lib32/libc.so.7 (0x2806c000)
        libiconv.so.3 => not found (0)
So I conclude that this lib is ok but can not be found in other places. Of course 32-bit lib can't be placed at /usr/local/lib because this is system library and this break whole system.

Could anyone can help me with this? What can be wrong here? Why only one correct place for libintl.so is /usr/local/lib? How can I change this?

I know about 32-bit jail solution on my 64 OS but this is extreme solution for me.

Best regards from Poland
Jaromir
Reply With Quote
  #2  
Old January 11th, 2013, 12:19
SirDice's Avatar
SirDice SirDice is offline
Moderator
 
Join Date: Nov 2008
Location: Rotterdam, Netherlands
Posts: 13,694
Thanks: 47
Thanked 2,021 Times in 1,860 Posts
Default

Quote:
Originally Posted by jaromir View Post
I know about 32-bit jail solution on my 64 OS but this is extreme solution for me.
Well, I was going to suggest this actually

It's probably the easiest solution that's also still manageable.
__________________
Senior UNIX Engineer at Unix Support Nederland
Experience is something you don't get until just after you need it.
Reply With Quote
Reply

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Web host gpatrick Web & Network Services 1 October 1st, 2012 16:09
FreeBSD & KVM as Win 7 host NickC General 8 April 27th, 2012 11:33
FreeBSD VM Host Pushrod General 1 August 8th, 2010 22:19
Multiple jails on host... How to get each host network usage gigikent2000 Networking 7 August 14th, 2009 12:44
[Solved] HOST DNS ip's? CoolDemon Installing & Upgrading 3 July 13th, 2009 04:50


All times are GMT +1. The time now is 18:14.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.
The mark FreeBSD is a registered trademark of The FreeBSD Foundation and is used by The FreeBSD Project with the permission of The FreeBSD Foundation.
Web protection and acceleration provided by CloudFlare
0