Имеем
Код: Выделить всё
# uname -a
FreeBSD 8.2-PRERELEASE FreeBSD 8.2-PRERELEASE #2: Fri Apr 22 11:47:35 UTC 2011
Код: Выделить всё
# pkg_info | grep asterisk
asterisk16-1.6.2.16.1 An Open Source PBX and telephony toolkit
asterisk16-addons-1.6.2.3_2 GPL modules for the Asterisk Open Source PBX
Код: Выделить всё
*CLI> module load res_fax_digium.so
Unable to load module res_fax_digium.so
Command 'module load res_fax_digium.so' failed.
[Apr 29 10:42:29] WARNING[12358]: loader.c:387 load_dynamic_module: Error loading module 'res_fax_digium.so': Shared object "libc.so.6" not found, required by "res_fax_digium.so"
[Apr 29 10:42:29] WARNING[12358]: loader.c:797 load_resource: Module 'res_fax_digium.so' could not be loaded.
Код: Выделить всё
*CLI> module load res_fax_digium.so
Unable to load module res_fax_digium.so
Command 'module load res_fax_digium.so' failed.
[Apr 29 11:19:45] WARNING[1252]: loader.c:387 load_dynamic_module: Error loading module 'res_fax_digium.so': /usr/lib/librt.so.1: version GLIBC_2.2 required by /usr/local/lib/asterisk/modules/res_fax_digium.so not found
[Apr 29 11:19:45] WARNING[1252]: loader.c:797 load_resource: Module 'res_fax_digium.so' could not be loaded.
Код: Выделить всё
# pkg_info | grep linux
linux_base-f10-10_4 Base set of packages needed in Linux mode for i386/amd64 (L
Код: Выделить всё
# objdump -x res_fax_digium.so
res_fax_digium.so: file format elf32-i386-freebsd
res_fax_digium.so
architecture: i386, flags 0x00000150:
HAS_SYMS, DYNAMIC, D_PAGED
start address 0x00029310
Program Header:
LOAD off 0x00000000 vaddr 0x00000000 paddr 0x00000000 align 2**12
filesz 0x0013ae04 memsz 0x0013ae04 flags r-x
LOAD off 0x0013b000 vaddr 0x0013b000 paddr 0x0013b000 align 2**12
filesz 0x0000f268 memsz 0x0013de34 flags rw-
DYNAMIC off 0x0013b01c vaddr 0x0013b01c paddr 0x0013b01c align 2**2
filesz 0x000000d0 memsz 0x000000d0 flags rw-
EH_FRAME off 0x0013ad8c vaddr 0x0013ad8c paddr 0x0013ad8c align 2**2
filesz 0x0000001c memsz 0x0000001c flags r--
STACK off 0x00000000 vaddr 0x00000000 paddr 0x00000000 align 2**2
filesz 0x00000000 memsz 0x00000000 flags rw-
Dynamic Section:
NEEDED librt.so.1
NEEDED libc.so.6
INIT 0x292c4
FINI 0x109038
HASH 0xd4
STRTAB 0xff4
SYMTAB 0x584
STRSZ 0x7c7
SYMENT 0x10
PLTGOT 0x13b0f8
PLTRELSZ 0x10
PLTREL 0x11
JMPREL 0x292b4
REL 0x198c
RELSZ 0x27928
RELENT 0x8
TEXTREL 0x0
VERNEED 0x190c
VERNEEDNUM 0x2
VERSYM 0x17bc
RELCOUNT 0x46ee
Version References:
required from librt.so.1:
0x0d696912 0x00 06 GLIBC_2.2
required from libc.so.6:
0x09691f73 0x00 07 GLIBC_2.1.3
0x0d696913 0x00 05 GLIBC_2.3
0x0d696911 0x00 04 GLIBC_2.1
0x09691972 0x00 03 GLIBC_2.3.2
0x0d696910 0x00 02 GLIBC_2.0
Sections:
Idx Name Size VMA LMA File off Algn
0 .hash 000004b0 000000d4 000000d4 000000d4 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
1 .dynsym 00000a70 00000584 00000584 00000584 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
2 .dynstr 000007c7 00000ff4 00000ff4 00000ff4 2**0
CONTENTS, ALLOC, LOAD, READONLY, DATA
3 .gnu.version 0000014e 000017bc 000017bc 000017bc 2**1
CONTENTS, ALLOC, LOAD, READONLY, DATA
4 .gnu.version_r 00000080 0000190c 0000190c 0000190c 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
5 .rel.dyn 00027928 0000198c 0000198c 0000198c 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
6 .rel.plt 00000010 000292b4 000292b4 000292b4 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
7 .init 00000017 000292c4 000292c4 000292c4 2**2
CONTENTS, ALLOC, LOAD, READONLY, CODE
8 .plt 00000030 000292dc 000292dc 000292dc 2**2
CONTENTS, ALLOC, LOAD, READONLY, CODE
9 .text 000dfd28 00029310 00029310 00029310 2**4
CONTENTS, ALLOC, LOAD, READONLY, CODE
10 .fini 0000001c 00109038 00109038 00109038 2**2
CONTENTS, ALLOC, LOAD, READONLY, CODE
11 .rodata 00031d2c 00109060 00109060 00109060 2**5
CONTENTS, ALLOC, LOAD, READONLY, DATA
12 .eh_frame_hdr 0000001c 0013ad8c 0013ad8c 0013ad8c 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
13 .eh_frame 0000005c 0013ada8 0013ada8 0013ada8 2**2
CONTENTS, ALLOC, LOAD, READONLY, DATA
14 .ctors 0000000c 0013b000 0013b000 0013b000 2**2
CONTENTS, ALLOC, LOAD, DATA
15 .dtors 0000000c 0013b00c 0013b00c 0013b00c 2**2
CONTENTS, ALLOC, LOAD, DATA
16 .jcr 00000004 0013b018 0013b018 0013b018 2**2
CONTENTS, ALLOC, LOAD, DATA
17 .dynamic 000000d0 0013b01c 0013b01c 0013b01c 2**2
CONTENTS, ALLOC, LOAD, DATA
18 .got 0000000c 0013b0ec 0013b0ec 0013b0ec 2**2
CONTENTS, ALLOC, LOAD, DATA
19 .got.plt 00000014 0013b0f8 0013b0f8 0013b0f8 2**2
CONTENTS, ALLOC, LOAD, DATA
20 .data 0000f148 0013b120 0013b120 0013b120 2**5
CONTENTS, ALLOC, LOAD, DATA
21 .bss 0012ebb4 0014a280 0014a280 0014a268 2**5
ALLOC
22 .comment 00001382 00000000 00000000 0014a268 2**0
CONTENTS, READONLY
SYMBOL TABLE:
no symbols
Потому как я понимаю что в фре либы лежат в /usr/local/lib/compat/
а эмуляционные либы линуха лежат в /usr/compat/linux/lib.
Если делаю так
Код: Выделить всё
ldconfig -m /usr/compat/linux/lib/
Код: Выделить всё
# asterisk -r
/libexec/ld-elf.so.1: /usr/local/lib/libh323_r.so.1: Undefined symbol "__divdi3"
Код: Выделить всё
/etc/rc.d/ldconfig restart