Hello everyone.
I Hope you are all doing fine. I am trying to compile the asterisk for past few days. My setup is Centos 7 minimal with kernel 5.14. I tried to update everything. Installed new packages nothing seems to be working.
I am facing this issue. I tried to add lresolv lpthread and other libraries in:
Configuration command ./config LDFLAG… and ASTLDFLAG=…
Have you run ./contrib/scripts/install_prereq? Once that’s completed, a simple ./configure followed my make should compile Asterisk with no issues. When you have a successful compile, you can add options to configure like --prefix=/usr to control installation location.
If it still fails, you need to provide the exact commands you’re issuing and the full output.
for doing it for last few days I memorized everything
I did yum update at beginning.
First I un-tar the package then install all preqs using script located in contrib/scripts (mainly pjsip and jansson lib)
then I did ./configure --with libjansson. Although I added few arguments like --lib=/usr/lib64 LDFLAGS=-pg CFLAGS=-pg ASTLDFLAGS=“-lresolv -lpthread” etc.
then make menuselect gives me UI for selecting the modules for installation. For last time I unselected pjsip_resolver and in TEST I unselect all tests which are related to DNS.
then Finally I did “make”. after sometime it shows the screen which is attached in question.
What I observed that I faced the same issue in asterisk 16, 20 and 22-current. the same error when I make.
thank you for your time. Any help or suggestion is welcome.
I don’t understand. Why are you adding CFLAGS, LDFLAGS and ASTLDFLAGS? Why and how are you unselecting pjsip_resolver? You should not have to any of that. What is your objective here?
Just run…
$ ./configure --prefix=/usr --libdir=/usr/lib64
$ make
Hi @gjoseph
thank you for your timely response. I unselect the pjsip stuff from make menuselect GUI. I deselected everything related to DNS.
I tried to compile the asterisk 16 and 22-current with it removed everything else except --withjansons but I am still getting the same error dn_expand res_search.
My setup is centos 7 minimal with kernal 5.5.
The command just before the error has -lresolv -lpthread by default. but unable to get pass the error.
thank you in advance.
I just tried this in a CentOS 7 container and it worked fine.
You may see warnings during the build but they’re OK. If anything goes wrong, you MUST copy the exact commands and output from the terminal and paste it here. I can’t help if you don’t show me exactly what you’ve done and the exact errors.