[asterisk-users] Best way to handle include files?

Tzafrir Cohen tzafrir.cohen at xorcom.com
Wed Nov 19 13:25:23 CST 2008


On Wed, Nov 19, 2008 at 01:14:55PM -0600, Doug wrote:
> Hi folks,
> 
> I am building a new box.  Want it to look
> pretty much like an older Asterisk 1.2,
> Debian box that is in production.  The new
> box will used as a test box before we
> implement changes to the production box.
> 
> New box:
> ================================================
> # cat /etc/issue;  uname -a
> Debian GNU/Linux 4.0 \n \l
> 
> Linux ServerName 2.6.18-6-686 #1 SMP Mon Oct 13 
> 16:13:09 UTC 2008 i686 GNU/Linux
> ================================================
> 
> I've got Asterisk compiled and running:
> 
> ================================================
> # asterisk -rvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
>    == Parsing '/etc/asterisk/asterisk.conf': Found
>    == Parsing '/etc/asterisk/extconfig.conf': Found
> Asterisk 1.2.30.2, Copyright (C) 1999 - 2007 Digium, Inc. and others.
> Created by Mark Spencer <markster at digium.com>
> Asterisk comes with ABSOLUTELY NO WARRANTY; type 'show warranty' for details.
> ================================================
> 
> The problem lies when I try to compile rxfax and
> txfax.  The compiler jumps out of the
> 
>    /usr/src/asterisk/asterisk/asterisk-1.2.30.2/apps/
> 
> directory:
> 
> /bin/sh: curl-config: command not found
> cc -fPIC   -c -o app_dial.o app_dial.c
> app_dial.c:37:22: error: asterisk.h: No such file or directory
> app_dial.c:39: error: expected declaration 
> specifiers or â...â before string constant
> 
> "asterisk.h" is located:
> 
> # find / -name "asterisk.h"
> /usr/src/asterisk/asterisk/asterisk-1.2.30.2/include/asterisk.h
> 
> I am finding that other Asterisk-related
> include files are located:
> 
> /usr/include/asterisk/
> 
> but, they have a recent time stamp.  I prefer
> a time stamp that indicated the last "real"
> modification date.

[Use package management rather than gueswork?]

> 
> Researching on the Web, some people suggest
> copying all the include files to:
> 
> /usr/include/asterisk/

This is indeed normally installed by 'make install' of Asterisk.

> 
> Others suggest making a symbolic link that
> translates:
> 
> /usr/include/asterisk/
> 
> to:
> 
> /usr/src/asterisk/asterisk/asterisk-1.2.30.2/include/

Why do you actually want to keep the build directory around?

(Note that Asterisk modules don't link at build time with and Asterisk
component (e.g.: library), and hence the sterisk-devel only includes
only the header files)

-- 
               Tzafrir Cohen
icq#16849755              jabber:tzafrir.cohen at xorcom.com
+972-50-7952406           mailto:tzafrir.cohen at xorcom.com
http://www.xorcom.com  iax:guest at local.xorcom.com/tzafrir



More information about the asterisk-users mailing list