Summary:ASTERISK-16437: [patch] Autoconf issues PGSQL_INCLUDE, etc.
Reporter:Philip Prindeville (pprindeville)Labels:
Date Opened:2010-07-26 15:12:39Date Closed:2011-06-07 14:01:07
Versions:Frequency of
Environment:Attachments:( 0) postgres_built.diff
Description:Looking into makeopts, I see:

GTK2_INCLUDE=-pthread -I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12  
MYSQLCLIENT_INCLUDE=-I/usr/include/mysql  -g -pipe -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -fno-strict-aliasing -fwrapv -fPIC   -DUNIV_LINUX
NETSNMP_INCLUDE=-DNETSNMP_ENABLE_IPV6 -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_RPM_4_4_COMPAT -Ulinux -Dlinux=linux -I/usr/include/rpm -D_REENTRANT -D_GNU_SOURCE -DPERL_USE_SAFE_PUTENV -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/lib64/perl5/CORE -I. -I/usr/include

and I see several issues going on here.

One:  you should be able to override the directory(ies) that are looking into for NETSNMP_INCLUDE, GTK2_INCLUDE, etc. without affecting the other compiler flags.

This needs to be broken into XXX_INCLUDE and XXX_CFLAGS so as to be individually settable.

Two: PGSQL_INCLUDE can't be specified on the command line arguments to configure, because there's no AC_SUBST(PGSQL_INCLUDE) in configure.ac.

It seems the value can only be set by running pg-config:

asterisk-trunk/configure.ac:   PGSQL_includedir=`${PG_CONFIG} --includedir`

this seems to be a recurring problem.  It would be nice to sit down and systematically resolve this issue for all packages and subsystems.

Comments:By: Leif Madsen (lmadsen) 2010-07-27 12:19:46

"this seems to be a recurring problem. It would be nice to sit down and systematically resolve this issue for all packages and subsystems."

That is a clear indication a discussion should be brought up on the asterisk-dev mailing list to get that fleshed out in order to move this issue forward.

By: Philip Prindeville (pprindeville) 2010-07-28 19:25:54

No, it's a prelude to a discussion.

I'm saying that this is potentially a significant amount of work, and while it probably should all be fixed in one fell swoop (to simplify testing and limit the potential for regressions), the question is do we want to fix this here and now or do we want to work around it to get 1.8 released, and then come back and fix it properly?

If we want to fix it here and now, then we should have that discussion.

By: Leif Madsen (lmadsen) 2010-07-29 10:56:28

Again, you need to bring this up on the asterisk-dev mailing list.

By: Paul Belanger (pabelanger) 2010-08-18 08:06:45

Suspended due to lack of activity. Please request a bug marshal in #asterisk-bugs on the IRC network irc.freenode.net to reopen the issue should you have the additional information requested.

Further information can be found at http://www.asterisk.org/developers/bug-guidelines