The error is make[1]: *** No rule to make target `/usr/src/asterisk-20.1.0/third-party/pjproject/pjproject.symbols', needed by `libasteriskpj.exports'. Stop

Hi Gents,

Getting error while running make:

The error is make[1]: *** No rule to make target /usr/src/asterisk-20.1.0/third-party/pjproject/pjproject.symbols', needed by libasteriskpj.exports’. Stop.
make: *** [main] Error 2 while running sudo make

OS: CentOS Linux release 7.9.2009 (Core)

please help

Did PJSIP actually download correctly? Did you interrupt the build process at all? What happens if you do “make distclean” and start fresh?

Let me try

Same error I am getting:

[CPP] libasteriskssl.c → libasteriskssl.i
[CCi] libasteriskssl.i → libasteriskssl.o
[LD] libasteriskssl.o → libasteriskssl.so.1
[LN] libasteriskssl.so.1 → libasteriskssl.so
[CPP] libasteriskpj.c → libasteriskpj.i
[CCi] libasteriskpj.i → libasteriskpj.o
make[1]: *** No rule to make target /usr/src/asterisk-20.1.0/third-party/pjproject/pjproject.symbols', needed by libasteriskpj.exports’. Stop.
make: *** [main] Error 2

please let me know which version of PJSIP and jansson I need download for Asterisk 20.1.0? Do I need to configure third_party tools first and then configure/make asterisk?

Regards

You don’t have to download either, or configure either. Bundled PJSIP is enabled by default, and jansson can be done that way by passing “–with-jansson-bundled” to configure. Asterisk will download, configure, build, and embed them.

I don’t know why this is failing on your system, but we haven’t had any other reports so it may be environmental. If you use the install_prereq script in the contrib/scripts directory does it download additional things, and afterwards work?

same error after

contrib/scripts/install_prereq install
Loaded plugins: fastestmirror, langpacks
Loading mirror speeds from cached hostfile

No package speexdsp-devel available.
Package 1:mariadb-devel-5.5.68-1.el7.x86_64 already installed and latest version
No package iksemel-devel available.
No package hoard available.
Nothing to do
#############################################

install completed successfully

#############################################

What are the EXACT steps you are doing to download, extract, configure, and build Asterisk?

please find my installation steps:

yum -y update
sudo setenforce 0
sestatus
sudo yum install -y epel-release dmidecode gcc-c++ ncurses-devel libxml2-devel make wget openssl-devel newt-devel kernel-devel sqlite-devel libuuid-devel gtk2-devel jansson-devel binutils-devel libedit libedit-devel wget
sudo yum -y groupinstall “Development Tools”
cd /usr/src/
ls
sudo git clone GitHub - akheron/jansson: C library for encoding, decoding and manipulating JSON data
cd jansson
sudo autoreconf -i
sudo ./configure --prefix=/usr/
sudo make
sudo make install
cd ~
git clone URL pjproject.git
cd pjproject
./configure CFLAGS=“-DNDEBUG -DPJ_HAS_IPV6=1” --prefix=/usr --libdir=/usr/lib64 --enable-shared --disable-video --disable-sound --disable-opencore-amr

make dep
make
sudo make install
sudo ldconfig
ldconfig -p | grep pj
cd /usr/src
wget URL asterisk-20.1.0.tar.gz
sudo tar xvf asterisk-20.1.0.tar.gz
ls
cd asterisk-20.1.0
sudo yum install svn
sudo ./contrib/scripts/get_mp3_source.sh
sudo contrib/scripts/install_prereq install
sudo ./configure --libdir=/usr/lib64 --with-jansson-bundled
sudo make menuselect
sudo make
sudo make install
sudo make samples
sudo make config
sudo systemctl restart asterisk
systemctl status asterisk

The error is make[1]: *** No rule to make target /usr/src/asterisk-20.1.0/third-party/pjproject/pjproject.symbols', needed by libasteriskpj.exports’. Stop.
make: *** [main] Error 2 while running sudo make

If you want to use the system installed version of PJSIP, then you’d need to tell configure that or else things will go awry. I believe it would be “–with-pjproject-bundled=no” though having not done such a thing in years I can’t say for certain.

PJSIP is required as After Asterisk 16, only PJSIP will only work not SIP.

any other way to solve this

Regards

Asterisk will automatically download, build, and use PJSIP without any involvement by you. You’ve messed that up by manually downloading and installing a version of PJSIP on the system globally.

You need to either remove that, or tell Asterisk to use with the argument I gave to configure (you REALLY don’t want to use their master branch though because it can cease working with Asterisk).

You need to pick a direction:

  1. Use a system installed PJSIP
  2. Use the bundled PJSIP

While running bundled PJSIP, getting following error:

[pjproject] Unpacking /tmp/pjproject-2.12.1.tar.bz2

bzip2: Compressed file ends unexpectedly;
perhaps it is corrupted? Possible reason follows.
bzip2: Inappropriate ioctl for device
Input file = (stdin), output file = (stdout)

It is possible that the compressed file(s) have become corrupted.
You can use the -tvv option to test integrity of such files.

You can use the `bzip2recover’ program to attempt to recover
data from undamaged sections of corrupted files.

/bin/tar: Child returned status 2
/bin/tar: Error is not recoverable: exiting now
mv: cannot stat ‘pjproject-2.12.1’: No such file or directory
make: *** [source/.unpacked] Error 1
failed
configure: Unable to configure third-party/pjproject
configure: error: Re-run the ./configure command with ‘NOISY_BUILD=yes’ appended to see error details.

Is it corrupted? If you delete it and have it re-download, what happens?

Please read the messages, don’t just post them here for me to read.

Thanks for help, but ./configure command only downloading and saying corrpted. I cleaned /tmp couple of time but no luck

Github was having issues, which is where it downloads from so it is entirely possible that is the reason. According to their status page things should be returning to normal.

sure. I am running make now.

Make gave new error now:

asterisk
json.o: In function ast_json_vstringf': /usr/src/asterisk-20.1.0/main/json.c:302: undefined reference to json_vsprintf’
collect2: error: ld returned 1 exit status
make[1]: *** [asterisk] Error 1
make: *** [main] Error 2

Did you “make distclean” before telling it to use bundled jansson?

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.