CellIAX - SVN Revision 505 - Trixbox 2.2 - Asterisk 1.2.18

Hello Giovanni,

Thanks for the cables :)

Good: I now have a motorola c350 :)
Bad: There seem to be several posts about problems with the c350 :(

... but that's not the subject of this post.

As I said in my email I'm trying to run CellIAX on Trixbox 2.2

I'm not expert on linux/svn/asterisk but am enjoying learning as I go :)

I have downloaded Revision 505 using svn to local directory celliax using the svn checkout from this site.

When I follow the instructions in the README file, make clean seems to work, but make install gives the following (I think this is the first error) :

gcc -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -g3 -Iinclude -I../include -D_REENTRANT -D_GNU_SOURCE -DMAKE_VALGRIND_HAPPY -O6 -march=i486 -fomit-frame-pointer -Wno-missing-prototypes -Wno-missing-declarations -DCRYPTO -fPIC -c -o chan_features.o chan_features.c
gcc -shared -Xlinker -x -o chan_features.so chan_features.o -ldl -lpthread -lncurses -lm -lresolv -lssl
gcc -c -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -g3 -Iinclude -I../include -D_REENTRANT -D_GNU_SOURCE -DMAKE_VALGRIND_HAPPY -O6 -march=i486 -fomit-frame-pointer -Wno-missing-prototypes -Wno-missing-declarations -DCRYPTO -fPIC -o chan_celliax.o chan_celliax.c
chan_celliax.c:421:28: alsa/asoundlib.h: No such file or directory
chan_celliax.c:606: error: syntax error before "format"
chan_celliax.c:606: warning: type defaults to `int' in declaration of `format'
chan_celliax.c:606: error: `SND_PCM_FORMAT_S16_LE' undeclared here (not in a function)
chan_celliax.c:606: warning: data definition has no type or storage class
chan_celliax.c:876: error: syntax error before "snd_pcm_t"
chan_celliax.c:876: warning: no semicolon at end of struct or union
chan_celliax.c:877: warning: type defaults to `int' in declaration of `alsap'
chan_celliax.c:877: warning: data definition has no type or storage class

I've noticed that Trixbox distribution is Asterisk 1.2.18 not 1.2.17

Any idea how to fix this?

Thanks in advance, tayhow

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

no problem with asterisk

no problem with asterisk version.

You have to add the alsa development libraries.

I think that the command for that is:

yum install alsa-dev

you have to run this command as root user

then retry to compile and post your results here.

Don't be afraid to ask any question you may have, we all have passed through this :)

Thanks G for the

Thanks G for the encouragement.
No doubt I'll ask lots of daft questions. :)

That didn't seem to work: "Nothing to do" (full listing below)

Do I need to add another repository?

Is yum the 'right' way to do this? There is a 'packages' menu option in Trixbox/FreePBX. Perhaps packages is actually yum???

As I said, most of this is new to me.

[root@asterisk1 celliax]# yum install alsa-dev
Setting up Install Process
Setting up repositories
trixbox 100% |=========================| 951 B 00:00
update 100% |=========================| 951 B 00:00
base 100% |=========================| 1.1 kB 00:00
trixboxaddons 100% |=========================| 951 B 00:00
addons 100% |=========================| 951 B 00:00
extras 100% |=========================| 1.1 kB 00:00
Reading repository metadata in from local files
Excluding Packages from CentOS-4 - Updates
Finished
Excluding Packages from CentOS-4 - Base
Finished
Excluding Packages from CentOS-4 - Addons
Finished
Excluding Packages from CentOS-4 - Extras
Finished
Parsing package install arguments
No Match for argument: alsa-dev
Nothing to do

I'll carry on looking.

oooops, sorry! my fault, I

oooops, sorry! my fault, I was going by memory

probably, but just probably, the correct command is:

yum install alsa-lib.i386 alsa-lib-devel.i386 alsa-utils.i386

try this, and please report back :)

I did yum search alsa* which

I did yum search alsa* which made me think it should be alsa-lib-devel so I tried this:

[root@asterisk1 celliax]# yum install alsa-lib-devel
Setting up Install Process
Setting up repositories
Reading repository metadata in from local files
Excluding Packages from CentOS-4 - Updates
Finished
Excluding Packages from CentOS-4 - Base
Finished
Excluding Packages from CentOS-4 - Addons
Finished
Excluding Packages from CentOS-4 - Extras
Finished
Parsing package install arguments
Resolving Dependencies
--> Populating transaction set with selected packages. Please wait.
---> Downloading header for alsa-lib-devel to pack into transaction set.
alsa-lib-devel-1.0.6-5.RH 100% |=========================| 28 kB 00:00
---> Package alsa-lib-devel.i386 0:1.0.6-5.RHEL4 set to be updated
--> Running transaction check

Dependencies Resolved

=============================================================================
Package Arch Version Repository Size
=============================================================================
Installing:
alsa-lib-devel i386 1.0.6-5.RHEL4 base 808 k

Transaction Summary
=============================================================================
Install 1 Package(s)
Update 0 Package(s)
Remove 0 Package(s)
Total download size: 808 k
Is this ok [y/N]: y
Downloading Packages:
(1/1): alsa-lib-devel-1.0 100% |=========================| 808 kB 00:01
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing: alsa-lib-devel ######################### [1/1]

Installed: alsa-lib-devel.i386 0:1.0.6-5.RHEL4
Complete!
[root@asterisk1 celliax]#

... Which looks like success ??? so then the make install:

chan_celliax.c: In function `do_monitor':
chan_celliax.c:2838: warning: 'celliax_debug' might be used uninitialized in this function
gcc -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -g3 -Iinclude -I../include -D_REENTRANT -D_GNU_SOURCE -DMAKE_VALGRIND_HAPPY -O6 -march=i486 -fomit-frame-pointer -Wno-missing-prototypes -Wno-missing-declarations -DCRYPTO -fPIC -c -o celliax_spandsp.o celliax_spandsp.c
gcc -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -g3 -Iinclude -I../include -D_REENTRANT -D_GNU_SOURCE -DMAKE_VALGRIND_HAPPY -O6 -march=i486 -fomit-frame-pointer -Wno-missing-prototypes -Wno-missing-declarations -DCRYPTO -fPIC -c -o celliax_libcsv.o celliax_libcsv.c
gcc -shared -Xlinker -x -o chan_celliax.so chan_celliax.o celliax_spandsp.o celliax_libcsv.o -lasound -lm -ldl -lX11
/usr/bin/ld: cannot find -lX11
collect2: ld returned 1 exit status
make[1]: *** [chan_celliax.so] Error 1
make[1]: Leaving directory `/root/hjt/celliax/asterisk-1.2.17/channels'
make: *** [subdirs] Error 1
[root@asterisk1 asterisk-1.2.17]#

Is Error 1 fatal?

If I go on to make samples

[root@asterisk1 asterisk-1.2.17]# make samples
build_tools/make_version_h > include/asterisk/version.h.tmp
if cmp -s include/asterisk/version.h.tmp include/asterisk/version.h ; then echo; else \
mv include/asterisk/version.h.tmp include/asterisk/version.h ; \
fi

rm -f include/asterisk/version.h.tmp
mkdir -p /usr/local/asterisk/etc/asterisk
for x in configs/*.adsi; do \
if [ ! -f /$x ]; then \
install -m 644 $x /usr/local/asterisk/etc/asterisk/`basename $x` ; \
fi ; \
done
mkdir -p /usr/local/asterisk/etc/asterisk
for x in configs/*.sample; do \
if [ -f /usr/local/asterisk/etc/asterisk/`basename $x .sample` ]; then \
if [ "y" = "y" ]; then \
if cmp -s /usr/local/asterisk/etc/asterisk/`basename $x .sample` $x ; then \
echo "Config file $x is unchanged"; \
continue; \
fi ; \
mv -f /usr/local/asterisk/etc/asterisk/`basename $x .sample` /usr/local/asterisk/etc/asterisk/`basename $x .sample`.old ; \
else \
echo "Skipping config file $x"; \
continue; \
fi ;\
fi ; \
install -m 644 $x /usr/local/asterisk/etc/asterisk/`basename $x .sample` ;\
done
Config file configs/adsi.conf.sample is unchanged
Config file configs/adtranvofr.conf.sample is unchanged
Config file configs/agents.conf.sample is unchanged
Config file configs/alarmreceiver.conf.sample is unchanged
Config file configs/alsa.conf.sample is unchanged
Config file configs/cdr.conf.sample is unchanged
Config file configs/cdr_custom.conf.sample is unchanged
Config file configs/cdr_manager.conf.sample is unchanged
Config file configs/cdr_odbc.conf.sample is unchanged
Config file configs/cdr_pgsql.conf.sample is unchanged
Config file configs/cdr_tds.conf.sample is unchanged
Config file configs/codecs.conf.sample is unchanged
Config file configs/dnsmgr.conf.sample is unchanged
Config file configs/dundi.conf.sample is unchanged
Config file configs/enum.conf.sample is unchanged
Config file configs/extconfig.conf.sample is unchanged
Config file configs/extensions.ael.sample is unchanged
Config file configs/extensions.conf.sample is unchanged
Config file configs/features.conf.sample is unchanged
Config file configs/festival.conf.sample is unchanged
Config file configs/iax.conf.sample is unchanged
Config file configs/iaxprov.conf.sample is unchanged
Config file configs/indications.conf.sample is unchanged
Config file configs/logger.conf.sample is unchanged
Config file configs/manager.conf.sample is unchanged
Config file configs/meetme.conf.sample is unchanged
Config file configs/mgcp.conf.sample is unchanged
Config file configs/misdn.conf.sample is unchanged
Config file configs/modem.conf.sample is unchanged
Config file configs/modules.conf.sample is unchanged
Config file configs/musiconhold.conf.sample is unchanged
Config file configs/osp.conf.sample is unchanged
Config file configs/oss.conf.sample is unchanged
Config file configs/phone.conf.sample is unchanged
Config file configs/privacy.conf.sample is unchanged
Config file configs/queues.conf.sample is unchanged
Config file configs/res_odbc.conf.sample is unchanged
Config file configs/rpt.conf.sample is unchanged
Config file configs/rtp.conf.sample is unchanged
Config file configs/sip.conf.sample is unchanged
Config file configs/sip_notify.conf.sample is unchanged
Config file configs/skinny.conf.sample is unchanged
Config file configs/voicemail.conf.sample is unchanged
Config file configs/vpb.conf.sample is unchanged
Config file configs/zapata.conf.sample is unchanged
if [ "y" = "y" ] || [ ! -f /usr/local/asterisk/etc/asterisk/asterisk.conf ]; then \
( \
echo "[directories]" ; \
echo "astetcdir => /usr/local/asterisk/etc/asterisk" ; \
echo "astmoddir => /usr/local/asterisk/usr/lib/asterisk/modules" ; \
echo "astvarlibdir => /usr/local/asterisk/var/lib/asterisk" ; \
echo "astagidir => /usr/local/asterisk/var/lib/asterisk/agi-bin" ; \
echo "astspooldir => /usr/local/asterisk/var/spool/asterisk" ; \
echo "astrundir => /usr/local/asterisk/var/run" ; \
echo "astlogdir => /usr/local/asterisk/var/log/asterisk" ; \
echo "" ; \
echo "; Changing the following lines may compromise your security." ; \
echo ";[files]" ; \
echo ";astctlpermissions = 0660" ; \
echo ";astctlowner = root" ; \
echo ";astctlgroup = apache" ; \
echo ";astctl = asterisk.ctl" ; \
) > /usr/local/asterisk/etc/asterisk/asterisk.conf ; \
else \
echo "Skipping asterisk.conf creation"; \
fi
mkdir -p /usr/local/asterisk/var/lib/asterisk/sounds ; \
for x in sounds/demo-*; do \
if grep -q "^%`basename $x`%" sounds.txt; then \
install -m 644 $x /usr/local/asterisk/var/lib/asterisk/sounds ; \
else \
echo "No description for $x"; \
exit 1; \
fi; \
done
mkdir -p /usr/local/asterisk/var/lib/asterisk/mohmp3 ; \
for x in sounds/*.mp3; do \
install -m 644 $x /usr/local/asterisk/var/lib/asterisk/mohmp3 ; \
done
install: cannot stat `sounds/*.mp3': No such file or directory
make: *** [samples] Error 1
[root@asterisk1 asterisk-1.2.17]# install: cannot stat `sounds/*.mp3': No such file or directory
> make: *** [samples] Error 1

Two questions about that .....

1) Why am I seeing script in the output?

2) What are these config *sample* files? (I have some config in Trixbox and don't want to overwrite it with samples.)

Is that progress? I guess I'm learning, probably learning by my mistakes :)

OK, tried that, got "Nothing

OK, tried that, got "Nothing to do" message again.

As I said in previous post I already installed alsa-lib-devel (<-- without the architecture .i386)

[root@asterisk1 ~]# yum install alsa-lib.i386 alsa-lib-devel.i386 alsa-utils.i386
Setting up Install Process
Setting up repositories
trixbox 100% |=========================| 951 B 00:00
update 100% |=========================| 951 B 00:00
base 100% |=========================| 1.1 kB 00:00
trixboxaddons 100% |=========================| 951 B 00:00
addons 100% |=========================| 951 B 00:00
extras 100% |=========================| 1.1 kB 00:00
Reading repository metadata in from local files
Excluding Packages from CentOS-4 - Updates
Finished
Excluding Packages from CentOS-4 - Base
Finished
Excluding Packages from CentOS-4 - Addons
Finished
Excluding Packages from CentOS-4 - Extras
Finished
Parsing package install arguments
Nothing to do
[root@asterisk1 ~]#

I'm going to look into the repositories now as this says 'excluding' ... and I'm not sure why / what that means :)

Now I seem to have X Windows

Now I seem to have X Windows problems.
"Can not find -lX11"
Why do I need X11 library to install CellIAX ????

gcc -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -g3 -Iinclude -I../include -D_REENTRANT -D_GNU_SOURCE -DMAKE_VALGRIND_HAPPY -O6 -march=i486 -fomit-frame-pointer -Wno-missing-prototypes -Wno-missing-declarations -DCRYPTO -fPIC -c -o celliax_libcsv.o celliax_libcsv.c
gcc -shared -Xlinker -x -o chan_celliax.so chan_celliax.o celliax_spandsp.o celliax_libcsv.o -lasound -lm -ldl -lX11
/usr/bin/ld: cannot find -lX11
collect2: ld returned 1 exit status
make[1]: *** [chan_celliax.so] Error 1
make[1]: Leaving directory `//asterisk-1.2.17/channels'
make: *** [subdirs] Error 1
[root@asterisk1 asterisk-1.2.17]#

I found a post saying that this is sometimes caused by FreeType, but applied the fix removing a freetype file ... and still get the above error.

X Windows does not appear to be installed on Trixbox 2.2

I have tried adding various packages with yum: xorg-libX11-devel???, but no luck.

Any suggestions how I can solve this?
Also, how can I troubleshoot this myself in future? It's very slow iterating towards a working solution by asking a question each time :)

Sorry about these newbie questions. I need to get a spare box and play more with Linux.

Ciao Tayhow, it is true, to

Ciao Tayhow,

it is true, to compile celliax with skype support, you need the development files for libX11 (I do not know which package it is into).

You can #undef CELLIAX_SKYPE and WANT_SKYPE_X11 if you are not planning to use skype, so it will no more need X11

to compile celliax with

to compile celliax with skype support, you need the development files for libX11 (I do not know which package it is into).

You can #undef CELLIAX_SKYPE and WANT_SKYPE_X11 if you are not planning to use skype, so it will no more need X11

Then,from the asterisk-1.2.17 directory, do:

touch sounds/ciao.mp3

then make install. Sorry for all this unnecessary mess :(

Ciao Giovanni. Oh I see. I

Ciao Giovanni.

Oh I see. I forgot the Skype side would need X Windows as I don't want to use it.

But ...

I checked chan_celliax.c and both CELLIAX_SKYPE and WANT_SKYPE_X11 *are* #undef'd in the Linux (non-CYGWIN) section.

I've noticed there's an old_chan_celliax.c

Perhaps that's getting compiled. I'm just checking ....

Help! ... I thought this was

Help! ... I thought this was supposed to be relatively simple? :)

I know a lot more about Linux/CentOS commands than I did, but not enough to make my own way or to know where to look for problems and solutions.

Iterating to a solution is not very efficient or swift ...

The install still seems to want X Windows.

If inclusion of X Windows is controlled by the defines, then the following should work.

I have tried the following:

=> 1 ========= edited chan_celliax.c to remove the windows defines ========

/* rewriting begin */
#include "asterisk/version.h" /* needed here for conditional compilation on version.h */
/* the following #defs are for LINUX */
#undef ASTERISK_VERSION_1_4
#undef CELLIAX_SKYPE
#undef WANT_SKYPE_X11
#define CELLIAX_ALSA
#undef CELLIAX_WINMM
#define CELLIAX_DIR
#define CELLIAX_LIBCSV
/* the following #defs are for WINDOWS */
/*** MODULEINFO
asound
***/
/* INCLUDES */
#include "asterisk.h"

=> 2 ========= Deleted old_chan_celliax.c ========

[root@asterisk1 celliax_stuff]# ls
alsactl.txt celliax_spandsp.h newconfigs
asound.conf chan_celliax.c old_chan_celliax.c
celliax_libcsv.c cyg_no_pthread_kill.c sh
celliax_libcsv.h dialog-1.0-20060221 states_n_controls.h
celliax_spandsp.c LiveCD

[root@asterisk1 celliax_stuff]# rm old_chan_celliax.c
rm: remove regular file `old_chan_celliax.c'? y

=> 3 ========= Checked defines for CELLIAX_SKYPE and WANT_SKYPE_X11 ========
=> 3 ========= are not in this directory ========

[root@asterisk1 celliax_stuff]# cat * | grep "efine CELLIAX_SKYPE"

cat: dialog-1.0-20060221: Is a directory
cat: LiveCD: Is a directory
cat: newconfigs: Is a directory
cat: sh: Is a directory

[root@asterisk1 celliax_stuff]# cat * | grep "efine WANT_SKYPE"

cat: dialog-1.0-20060221: Is a directory
cat: LiveCD: Is a directory
cat: newconfigs: Is a directory
cat: sh: Is a directory
[root@asterisk1 celliax_stuff]#

=> 4 ========= Ran make clean ========
=> 5 ========= Ran touch sounds/ciao.mp3 ========
=> 6 ========= Ran make install ========

The result?

gcc -shared -Xlinker -x -o chan_celliax.so chan_celliax.o celliax_spandsp.o celliax_libcsv.o -lasound -lm -ldl -lX11

/usr/bin/ld: cannot find -lX11 <----------------- CLANG !

collect2: ld returned 1 exit status
make[1]: *** [chan_celliax.so] Error 1
make[1]: Leaving directory `/root//celliax/asterisk-1.2.17/channels'
make: *** [subdirs] Error 1
[root@asterisk1 asterisk-1.2.17]#

I'm probably not the ideal person to try this on Trixbox 2.2.

Am I the first?

/BLUSH if you do not want

/BLUSH
if you do not want the skype stuff you have to edit the channels/Makefile and delete -lX11
BLUSH/

very sorry for this, the sources are not yet in a state very easy to use... they will be very much better when released! I swear! I swear! ;-)

How to install Celliax in

How to install Celliax in Trixbox 2.2: http://www.celliax.org/node/313

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.