Not sure where this bug is or if its been corrected already or even how to 
correct it.

Trying to compile a 64bit build of FreeSWITCH on SmartOS we end up with 
compiler_lib_search_dirs in libtool with these values in order:

(64bit) /opt/local/lib/ 
(64bit) /opt/local/gcc47/lib/gcc/x86_64-sun-solaris2.11/4.7.3 
(64bit) 
/opt/local/gcc47/lib/gcc/x86_64-sun-solaris2.11/4.7.3/../../../../x86_64-sun-solaris2.11/lib/amd64
 
(64bit) /opt/local/gcc47/lib/gcc/x86_64-sun-solaris2.11/4.7.3/../../../amd64 
(64bit) /lib/amd64 
(64bit) /usr/lib/amd64 
(32bit) 
/opt/local/gcc47/lib/gcc/x86_64-sun-solaris2.11/4.7.3/../../../../x86_64-sun-solaris2.11/lib
 
(32bit) /opt/local/gcc47/lib/gcc/x86_64-sun-solaris2.11/4.7.3/../../.. 
(64bit) /opt/local/gcc47/x86_64-sun-solaris2.11/lib/amd64 
(64bit) /opt/local/gcc47/lib/amd64 

When linking to -llibstdc++ since the 32bit directory is before the two 64bit 
directories that contain libstdc++.so for 64bit.

Resulting in /opt/local/gcc47/lib/libstdc++.so: wrong ELF class: ELFCLASS32

Any idea how to fix this?  I do not have the same problem on Solaris 11.1, It 
also excludes any paths that are 32bit from compiler_lib_search_dirs, I've also 
tried CC='gcc -m64' and CXX='g++ -m64' it fails.

If I force the LDFLAGS like so:

LDFLAGS='-L/opt/local/gcc47/lib/amd64' ./configure --enable-64 

It works, but I shouldn't have to do that step.

Thoughts?

--
Brian West
[email protected]



Twitter: @FreeSWITCH , @briankwest
http://www.freeswitchbook.com
http://www.freeswitchcookbook.com

T: +1.918.420.9001  |  F: +1.918.420.9002  |  M: +1.918.424.WEST
iNUM: +883 5100 1420 9001
ISN: 410*543
Skype:briankwest
PGP Key: http://www.bkw.org/key.txt (AB93356707C76CED)


















-------------------------------------------
smartos-discuss
Archives: https://www.listbox.com/member/archive/184463/=now
RSS Feed: https://www.listbox.com/member/archive/rss/184463/25769125-55cfbc00
Modify Your Subscription: 
https://www.listbox.com/member/?member_id=25769125&id_secret=25769125-7688e9fb
Powered by Listbox: http://www.listbox.com

Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

Reply via email to