By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,750 Members | 1,199 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,750 IT Pros & Developers. It's quick & easy.

Module loading problem

P: n/a
I am try to load a .so file through asterisk but get the following problem:

Mar 23 17:38:19 WARNING[423]: loader.c:325 __load_resource: ld.so.1:
asterisk: fatal: /opt/asterisk/lib/modules/SPARC64codec_g729a.so: wrong
ELF class: ELFCLASS64
Mar 23 17:38:19 WARNING[423]: loader.c:554 load_modules: Loading module
SPARC64codec_g729a.so failed!
I am on a Ultra80 Solaris 10 machine in 64-bit mode.

I compiled asterisk using:
Reading specs from /usr/local/lib/gcc/sparc-sun-solaris2.9/3.4.6/specs
Configured with: ../configure --with-as=/usr/ccs/bin/as
--with-ld=/usr/ccs/bin/ld --enable-shared --enable-languages=c,c++,f77
Thread model: posix
gcc version 3.4.6

But the .so file is precomplied and downloaded.

How may I resolve this problem?

Thanks
Mar 23 '07 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Changing followups to comp.unix.solaris.

In comp.unix.solaris Mikail Dellovich <fo*@foo.comwrote:
I am try to load a .so file through asterisk but get the following problem:
Mar 23 17:38:19 WARNING[423]: loader.c:325 __load_resource: ld.so.1:
asterisk: fatal: /opt/asterisk/lib/modules/SPARC64codec_g729a.so: wrong
ELF class: ELFCLASS64
This looks like your application is a 32 bit binary, but it is trying to
use a 64 bit shared object.

Run 'file' on both your application and the .so file.

The app and any shared objects it uses must be of the same bitness.
I am on a Ultra80 Solaris 10 machine in 64-bit mode.
I compiled asterisk using:
Reading specs from /usr/local/lib/gcc/sparc-sun-solaris2.9/3.4.6/specs
Configured with: ../configure --with-as=/usr/ccs/bin/as
--with-ld=/usr/ccs/bin/ld --enable-shared --enable-languages=c,c++,f77
Thread model: posix
gcc version 3.4.6
But the .so file is precomplied and downloaded.
If there's only one .so and it's a 64 bit object, I'd assume you would
need to tell the compiler to create a 64 bit executable.

--
Darren Dunham dd*****@taos.com
Senior Technical Consultant TAOS http://www.taos.com/
Got some Dr Pepper? San Francisco, CA bay area
< This line left intentionally blank to confuse you. >
Mar 23 '07 #2

P: n/a
On Fri, 23 Mar 2007 18:08:24 -0400, Mikail Dellovich <fo*@foo.com>
wrote:
>I am try to load a .so file through asterisk but get the following problem:
This is far off topic in comp.lang.c.

--
Al Balmer
Sun City, AZ
Mar 23 '07 #3

P: n/a
Mikail Dellovich <fo*@foo.comwrites:
I am try to load a .so file through asterisk but get the following problem:

Mar 23 17:38:19 WARNING[423]: loader.c:325 __load_resource: ld.so.1:
asterisk: fatal: /opt/asterisk/lib/modules/SPARC64codec_g729a.so:
wrong ELF class: ELFCLASS64
Mar 23 17:38:19 WARNING[423]: loader.c:554 load_modules: Loading
module SPARC64codec_g729a.so failed!
I am on a Ultra80 Solaris 10 machine in 64-bit mode.
[...]

I was about to tell you that comp.unix.solaris would be a better place
to ask this question; then I noticed that it's cross-posted to both
comp.lang.c and comp.unix.solaris.

Since you don't appear to have a C language issue, I've redirected
followups to just comp.unix.solaris, and I encourage others to
restrict their followups to that group.

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Mar 23 '07 #4

This discussion thread is closed

Replies have been disabled for this discussion.