Certified Asterisk installation failed

Yandri Loor

Member

Reaction score: 2
Messages: 46

hi i am trying to install Certified Asterisk 16 - LTS but i have a crypt_r error


Code:
ld: error: undefined symbol: crypt_r

>>> referenced by crypt.c:124

>>>               crypt.o:(ast_crypt)

>>> referenced by crypt.c:139

>>>               crypt.o:(ast_crypt_validate)

>>> referenced by crypt.c:124

>>>               crypt.o:(ast_crypt_encrypt)

c++: error: linker command failed with exit code 1 (use -v to see invocation)

gmake[2]: *** [Makefile:320: asterisk] Error 1

gmake[1]: *** [Makefile:383: main] Error 2
 
OP
Yandri Loor

Yandri Loor

Member

Reaction score: 2
Messages: 46

You need to use the FreeBSD ports & package system for our specific patches.
net/asterisk18
The older port
net/asterisk16
or if you want more detailed:
1. I downloaded the source code from http://downloads.asterisk.org/pub/t...terisk/asterisk-certified-16.8-current.tar.gz
Code:
wget http://downloads.asterisk.org/pub/telephony/certified-asterisk/asterisk-certified-16.8-current.tar.gz
2. unzipped the tar file
Code:
tar xvf asterisk-certified-16.8-current.tar.gz
3. installed the dependencies
Code:
cd asterisk-certified-16.8-cert5
cd contrib/scripts
./install-prereq test
3.1 I built each of the dependencies from the ports tree
4. I configured Asterisk
Code:
cd ../..
./configure
5. I tried to build and there the error came up
 

Phishfry

Beastie's Twin

Reaction score: 2,644
Messages: 5,558

Please look at the official Git repository for asterick
Notice how it says:

SUPPORTED OPERATING SYSTEMS​

Linux​


So you are trying to compile Linux based code on FreeBSD.
That requires patches.
So you need to run the FreeBSD port/package system.
It has patches applied for this to build.

Easy way to do this is pkg install asterisk18

I don't know what Certified Asterisk means. For FreeBSD you are best off using our ports and packages.
Building from ports if you want but it is a harder operation.

You may also look at the Asterisk18 patches by browsing the ports directory: /usr/ports/net/asterisk18/files
With the patches manually applied from this directory you could build from Asterisk supplied source code.

Here is a good video with instructions for installing via packages.
 

sidetone

Daemon

Reaction score: 832
Messages: 1,727


If you still want to build Asterisk:
Use portsnap to get the ports collection. Go to /usr/ports/net/asterisk18/, and use make commands (including make config) from there.

All are according to the instructions in that link. This is the standard way to build it on FreeBSD from source code. It bypasses the trial and error approach from building it from scratch, and includes necessary patches (as someone mentioned above).
 
Top