[asterisk-commits] kpfleming: trunk r48522 - in /trunk: ./ include/ main/stdtime/

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Sat Dec 16 13:19:19 MST 2006


Author: kpfleming
Date: Sat Dec 16 14:19:19 2006
New Revision: 48522

URL: http://svn.digium.com/view/asterisk?view=rev&rev=48522
Log:
Merged revisions 48521 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r48521 | kpfleming | 2006-12-16 14:12:41 -0600 (Sat, 16 Dec 2006) | 2 lines

since we really, really have to have autoconfig.h included before all other headers (especially system headers), the Makefile will now force it to happen (this will fix build problems with files like ast_expr2f.c, where we can't control the inclusion order in the file itself)

........

Modified:
    trunk/   (props changed)
    trunk/Makefile
    trunk/include/asterisk.h
    trunk/main/stdtime/localtime.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/Makefile
URL: http://svn.digium.com/view/asterisk/trunk/Makefile?view=diff&rev=48522&r1=48521&r2=48522
==============================================================================
--- trunk/Makefile (original)
+++ trunk/Makefile Sat Dec 16 14:19:19 2006
@@ -180,6 +180,8 @@
 endif
 
 ASTCFLAGS+=-pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations $(DEBUG)
+
+ASTCFLAGS+=-include $(ASTTOPDIR)/include/asterisk/autoconfig.h
 
 ifeq ($(AST_DEVMODE),yes)
   ASTCFLAGS+=-Werror -Wunused

Modified: trunk/include/asterisk.h
URL: http://svn.digium.com/view/asterisk/trunk/include/asterisk.h?view=diff&rev=48522&r1=48521&r2=48522
==============================================================================
--- trunk/include/asterisk.h (original)
+++ trunk/include/asterisk.h Sat Dec 16 14:19:19 2006
@@ -18,6 +18,13 @@
 #ifndef _ASTERISK_H
 #define _ASTERISK_H
 
+/* The include of 'autoconfig.h' is not necessary for any modules that
+   are part of the Asterisk source tree, because the top-level Makefile
+   will forcibly include that header in all compilations before all
+   other headers (even system headers). However, leaving this here will
+   help out-of-tree module builders, and doesn't cause any harm for the
+   in-tree modules.
+*/
 #include "asterisk/autoconfig.h"
 
 #include "asterisk/compat.h"

Modified: trunk/main/stdtime/localtime.c
URL: http://svn.digium.com/view/asterisk/trunk/main/stdtime/localtime.c?view=diff&rev=48522&r1=48521&r2=48522
==============================================================================
--- trunk/main/stdtime/localtime.c (original)
+++ trunk/main/stdtime/localtime.c Sat Dec 16 14:19:19 2006
@@ -43,10 +43,6 @@
 #define TZ_STRLEN_MAX	255
 /* #define DEBUG */
 
-#include "asterisk.h"
- 
-ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
-
 /*LINTLIBRARY*/
 
 #include <sys/types.h>
@@ -58,9 +54,13 @@
 
 #include "private.h"
 #include "tzfile.h"
+
+#include "asterisk.h"
+
+ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
+
 #include "asterisk/lock.h"
 #include "asterisk/localtime.h"
-
 
 #ifndef lint
 #ifndef NOID



More information about the asterisk-commits mailing list