summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH.Merijn Brand <h.m.brand@xs4all.nl>2014-06-11 09:45:44 +0200
committerH.Merijn Brand <h.m.brand@xs4all.nl>2014-06-11 09:45:44 +0200
commitf6a82adeac84b0be20188fd4ea164d8e4a1cc131 (patch)
treef54d5a7cf728c9783ac5d0a021cd64b607d2ff1a
parent60bd7b488a4d9a548c63a8440324726b52ba9a3c (diff)
downloadperl-f6a82adeac84b0be20188fd4ea164d8e4a1cc131.tar.gz
Fix cbacktrace
-rwxr-xr-xConfigure44
-rw-r--r--Cross/config.sh-arm-linux1
-rw-r--r--NetWare/config.wc1
-rw-r--r--Porting/Glossary22
-rw-r--r--Porting/config.sh1
-rwxr-xr-xconfig_h.SH46
-rw-r--r--configure.com1
-rw-r--r--metaconfig.h3
-rw-r--r--plan9/config_sh.sample1
-rw-r--r--symbian/config.sh1
-rw-r--r--uconfig.h50
-rw-r--r--uconfig.sh1
-rw-r--r--uconfig64.sh1
-rw-r--r--win32/config.ce1
-rw-r--r--win32/config.gc1
-rw-r--r--win32/config.vc1
16 files changed, 116 insertions, 60 deletions
diff --git a/Configure b/Configure
index 059e8cfb77..02c2a9bf36 100755
--- a/Configure
+++ b/Configure
@@ -28,7 +28,7 @@
# See Porting/pumpkin.pod for more information on metaconfig.
#
-# Generated on Wed Jun 4 08:58:13 CEST 2014 [metaconfig 3.5 PL0]
+# Generated using [metaconfig 3.5 PL0]
# (with additional metaconfig patches by perlbug@perl.org)
cat >c1$$ <<EOF
@@ -9364,6 +9364,29 @@ rp='Pathname where add-on public executable scripts should be installed?'
prefixvar=sitescript
. ./setprefixvar
+: see if backtrace exists
+set backtrace d_backtrace
+eval $inlibc
+
+: add flags if using c backtrace
+case "$usecbacktrace" in
+ "") usecbacktrace=$undef ;;
+ [yY]*|true|$define)
+ case "$d_backtrace" in
+ [yY]*|true|$define)
+ case " $ccflags " in
+ *" -DUSE_C_BACKTRACE "*) ;; # Already there.
+ *) ccflags="$ccflags -DUSE_C_BACKTRACE -g" ;;
+ esac
+ ;;
+ *)
+ echo "This system does not support backtrace" >&4
+ usecbacktrace=$undef
+ ;;
+ esac
+ ;;
+ esac
+
: Check if faststdio is requested and available
case "$usefaststdio" in
$define|true|[yY]*|'')
@@ -10840,10 +10863,6 @@ set d_attribute_warn_unused_result
eval $setvar
$rm -f attrib*
-: see if backtrace exists
-set backtrace d_backtrace
-eval $inlibc
-
: see if bcmp exists
set bcmp d_bcmp
eval $inlibc
@@ -12347,17 +12366,6 @@ $rm -f fred fred.* dyna.$dlext dyna.* tmp-dyna.*
set d_dlsymun
eval $setvar
-: add flags if using c backtrace
-case "$usecbacktrace" in
-[yY]*|true|$define)
- case " $ccflags " in
- *" -DUSE_C_BACKTRACE "*) ;; # Already there.
- *) ccflags="$ccflags -DUSE_C_BACKTRACE -g"
- ;;
- esac
- ;;
-esac
-
: see if drand48_r exists
set drand48_r d_drand48_r
eval $inlibc
@@ -24100,11 +24108,7 @@ EOM
fi
: preserve RCS keywords in files with variable substitution, grrr
-Date='$Date'
Id='$Id'
-Log='$Log'
-RCSfile='$RCSfile'
-Revision='$Revision'
: Finish up by extracting the .SH files
case "$alldone" in
diff --git a/Cross/config.sh-arm-linux b/Cross/config.sh-arm-linux
index 1aad80db29..f703258bfe 100644
--- a/Cross/config.sh-arm-linux
+++ b/Cross/config.sh-arm-linux
@@ -1028,6 +1028,7 @@ uquadtype='unsigned long long'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='define'
diff --git a/NetWare/config.wc b/NetWare/config.wc
index f37517d5a3..3824d99f8b 100644
--- a/NetWare/config.wc
+++ b/NetWare/config.wc
@@ -991,6 +991,7 @@ uquadtype='unsigned __int64'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='define'
diff --git a/Porting/Glossary b/Porting/Glossary
index 301fa66427..9128f5f41a 100644
--- a/Porting/Glossary
+++ b/Porting/Glossary
@@ -478,6 +478,11 @@ d_attribute_warn_unused_result (d_attribut.U):
compiler can know that certain functions have a return values
that must not be ignored, such as malloc() or open().
+d_backtrace (d_backtrace.U):
+ This variable conditionally defines the HAS_BACKTRACE symbol, which
+ indicates to the C program that the backtrace() routine is available
+ to get a stack trace.
+
d_bcmp (d_bcmp.U):
This variable conditionally defines the HAS_BCMP symbol if
the bcmp() routine is available to compare strings.
@@ -650,6 +655,11 @@ d_dirnamlen (i_dirent.U):
to the C program that the length of directory entry names is
provided by a d_namelen field.
+d_dladdr (d_dladdr.U):
+ This variable conditionally defines the HAS_DLADDR symbol, which
+ indicates to the C program that the dladdr() routine is available
+ to get a stack trace.
+
d_dlerror (d_dlerror.U):
This variable conditionally defines the HAS_DLERROR symbol, which
indicates to the C program that the dlerror() routine is available.
@@ -3030,6 +3040,10 @@ i_assert (i_assert.U):
indicates to the C program that <assert.h> exists and could be
included.
+i_bfd (i_bfd.U):
+ This variable conditionally defines the I_BFD symbol, and
+ indicates whether a C program can include <bfd.h>.
+
i_bsdioctl (i_sysioctl.U):
This variable conditionally defines the I_SYS_BSDIOCTL symbol, which
indicates to the C program that <sys/bsdioctl.h> exists and should
@@ -3057,6 +3071,10 @@ i_dlfcn (i_dlfcn.U):
indicates to the C program that <dlfcn.h> exists and should
be included.
+i_execinfo (i_execinfo.U):
+ This variable conditionally defines the I_EXECINFO symbol, and indicates
+ whether a C program may include <execinfo.h>, for backtrace() support.
+
i_fcntl (i_fcntl.U):
This variable controls the value of I_FCNTL (which tells
the C program to include <fcntl.h>).
@@ -5084,6 +5102,10 @@ use64bitint (use64bits.U):
This may mean using for example "long longs", while your memory
may still be limited to 2 gigabytes.
+usecbacktrace (usebacktrace.U):
+ This variable indicates whether we are compiling with backtrace
+ support.
+
usecrosscompile (Cross.U):
This variable conditionally defines the USE_CROSS_COMPILE symbol,
and indicates that Perl has been cross-compiled.
diff --git a/Porting/config.sh b/Porting/config.sh
index f20ad5a513..2c1c25d38e 100644
--- a/Porting/config.sh
+++ b/Porting/config.sh
@@ -1056,6 +1056,7 @@ uquadtype='unsigned long long'
use5005threads='undef'
use64bitall='undef'
use64bitint='define'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='define'
usedl='define'
diff --git a/config_h.SH b/config_h.SH
index 5e8432baa9..fcd1c4d1c0 100755
--- a/config_h.SH
+++ b/config_h.SH
@@ -131,12 +131,6 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
*/
#$d_difftime HAS_DIFFTIME /**/
-/* HAS_DLADDR:
- * This symbol, if defined, indicates that the dladdr routine is
- * available to return information about stack addresses.
- */
-#$d_dladdr HAS_DLADDR /**/
-
/* HAS_DLERROR:
* This symbol, if defined, indicates that the dlerror routine is
* available to return a string describing the last error that
@@ -144,12 +138,6 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
*/
#$d_dlerror HAS_DLERROR /**/
-/* HAS_BACKTRACE:
- * This symbol, if defined, indicates that the backtrace routine is
- * available to return backtrace information about the C stack.
- */
-#$d_backtrace HAS_BACKTRACE /**/
-
/* HAS_DUP2:
* This symbol, if defined, indicates that the dup2 routine is
* available to duplicate file descriptors.
@@ -701,12 +689,6 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
*/
#$i_dlfcn I_DLFCN /**/
-/* I_EXECINFO:
- * This symbol, if defined, indicates that <execinfo.h> exists and should
- * be included.
- */
-#$i_execinfo I_EXECINFO /**/
-
/* I_FCNTL:
* This manifest constant tells the C program to include <fcntl.h>.
*/
@@ -3338,6 +3320,26 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
#$d_vendorlib PERL_VENDORLIB_EXP "$vendorlibexp" /**/
#$d_vendorlib PERL_VENDORLIB_STEM "$vendorlib_stem" /**/
+/* HAS_BACKTRACE:
+ * This symbol, if defined, indicates that the backtrace() routine is
+ * available to get a stack trace. The <execinfo.h> header must be
+ * included to use this routine.
+ */
+#$d_backtrace HAS_BACKTRACE /**/
+
+/* HAS_DLADDR:
+ * This symbol, if defined, indicates that the dladdr() routine is
+ * available to get a stack trace. The <execinfo.h> header must be
+ * included to use this routine.
+ */
+#$d_dladdr HAS_DLADDR /**/
+
+/* I_EXECINFO:
+ * This symbol, if defined, indicates to the C program that it should
+ * include <execinfo.h> for backtrace() support.
+ */
+#$i_execinfo I_EXECINFO /**/
+
/* I_TERMIO:
* This symbol, if defined, indicates that the program should include
* <termio.h> rather than <sgtty.h>. There are also differences in
@@ -4232,7 +4234,7 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
/* I_BFD:
* This symbol, if defined, indicates that <bfd.h> exists and
- * could be included by the C program to use the BFD library.
+ * can be included.
*/
#$i_bfd I_BFD /**/
@@ -4701,6 +4703,12 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
#$use64bitall USE_64_BIT_ALL /**/
#endif
+/* USE_CBACKTRACE:
+ * This symbol, if defined, indicates that Perl should
+ * be built with support for backtrace.
+ */
+#$usecbacktrace USE_CBACKTRACE /**/
+
/* USE_DTRACE:
* This symbol, if defined, indicates that Perl should
* be built with support for DTrace.
diff --git a/configure.com b/configure.com
index deade6d4f9..4d8a4f1d84 100644
--- a/configure.com
+++ b/configure.com
@@ -6677,6 +6677,7 @@ $ WC "use64bitint='" + use64bitint + "'"
$ WC "usecasesensitive='" + be_case_sensitive + "'" ! VMS-specific
$ WC "usedebugging_perl='"+use_debugging_perl+"'"
$ WC "usedefaulttypes='" + usedefaulttypes + "'" ! VMS-specific
+$ WC "usecbacktrace='undef'"
$ WC "usecrosscompile='undef'"
$ WC "usedevel='" + usedevel + "'"
$ WC "usedl='" + usedl + "'"
diff --git a/metaconfig.h b/metaconfig.h
index 0a90c86ed0..72f73e3dba 100644
--- a/metaconfig.h
+++ b/metaconfig.h
@@ -13,8 +13,10 @@
* BOOTSTRAP_CHARSET
* CHARBITS
* HAS_ASCTIME64
+ * HAS_BACKTRACE
* HAS_CTIME64
* HAS_DIFFTIME64
+ * HAS_DLADDR
* HAS_GMTIME64
* HAS_ISBLANK
* HAS_LOCALTIME64
@@ -32,6 +34,7 @@
* I8SIZE
* LOCALTIME_R_NEEDS_TZSET
* U8SIZE
+ * USE_CBACKTRACE
* USE_KERN_PROC_PATHNAME
* USE_NSGETEXECUTABLEPATH
*
diff --git a/plan9/config_sh.sample b/plan9/config_sh.sample
index 112878aa01..fdfba5c28b 100644
--- a/plan9/config_sh.sample
+++ b/plan9/config_sh.sample
@@ -999,6 +999,7 @@ uquadtype='unsigned long long'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='undef'
diff --git a/symbian/config.sh b/symbian/config.sh
index 4c3c590e49..fc588c3d34 100644
--- a/symbian/config.sh
+++ b/symbian/config.sh
@@ -814,6 +814,7 @@ uquadtype='uint64_t'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='undef'
diff --git a/uconfig.h b/uconfig.h
index 37a25457fa..6707d66fad 100644
--- a/uconfig.h
+++ b/uconfig.h
@@ -96,12 +96,6 @@
*/
/*#define HAS_DIFFTIME / **/
-/* HAS_DLADDR:
- * This symbol, if defined, indicates that the dladdr routine is
- * available to return information about stack addresses.
- */
-/*#define HAS_DLADDR / **/
-
/* HAS_DLERROR:
* This symbol, if defined, indicates that the dlerror routine is
* available to return a string describing the last error that
@@ -109,12 +103,6 @@
*/
/*#define HAS_DLERROR / **/
-/* HAS_BACKTRACE:
- * This symbol, if defined, indicates that the backtrace routine is
- * available to return backtrace information about the C stack.
- */
-/*#define HAS_BACKTRACE / **/
-
/* HAS_DUP2:
* This symbol, if defined, indicates that the dup2 routine is
* available to duplicate file descriptors.
@@ -666,12 +654,6 @@
*/
/*#define I_DLFCN / **/
-/* I_EXECINFO:
- * This symbol, if defined, indicates that <execinfo.h> exists and should
- * be included.
- */
-/*#define I_EXECINFO / **/
-
/* I_FCNTL:
* This manifest constant tells the C program to include <fcntl.h>.
*/
@@ -3303,6 +3285,26 @@
/*#define PERL_VENDORLIB_EXP "" / **/
/*#define PERL_VENDORLIB_STEM "" / **/
+/* HAS_BACKTRACE:
+ * This symbol, if defined, indicates that the backtrace() routine is
+ * available to get a stack trace. The <execinfo.h> header must be
+ * included to use this routine.
+ */
+/*#define HAS_BACKTRACE / **/
+
+/* HAS_DLADDR:
+ * This symbol, if defined, indicates that the dladdr() routine is
+ * available to get a stack trace. The <execinfo.h> header must be
+ * included to use this routine.
+ */
+/*#define HAS_DLADDR / **/
+
+/* I_EXECINFO:
+ * This symbol, if defined, indicates to the C program that it should
+ * include <execinfo.h> for backtrace() support.
+ */
+/*#define I_EXECINFO / **/
+
/* I_TERMIO:
* This symbol, if defined, indicates that the program should include
* <termio.h> rather than <sgtty.h>. There are also differences in
@@ -4197,7 +4199,7 @@
/* I_BFD:
* This symbol, if defined, indicates that <bfd.h> exists and
- * could be included by the C program to use the BFD library.
+ * can be included.
*/
/*#define I_BFD / **/
@@ -4666,6 +4668,12 @@
/*#define USE_64_BIT_ALL / **/
#endif
+/* USE_CBACKTRACE:
+ * This symbol, if defined, indicates that Perl should
+ * be built with support for backtrace.
+ */
+/*#define USE_CBACKTRACE / **/
+
/* USE_DTRACE:
* This symbol, if defined, indicates that Perl should
* be built with support for DTrace.
@@ -4747,6 +4755,6 @@
#endif
/* Generated from:
- * 45e2c6b42b88b07e21adb94c47d9bd7bcb8da04e2bbb38d7223eb516eb7d99de config_h.SH
- * 6d0cc2cac48fbe8139cf8a89bdd458a93797d18e649f3ed80896bfe4d218b0a2 uconfig.sh
+ * 611edf01f1919fa67b739fd66ee8691021498ca8029accb0ecd74d6352d4570c config_h.SH
+ * d4c6d7b05a17c792e1a29260fa58783614c7895971bc5a3ab830a39303a2be03 uconfig.sh
* ex: set ro: */
diff --git a/uconfig.sh b/uconfig.sh
index 810aaec660..5c1a5d6efe 100644
--- a/uconfig.sh
+++ b/uconfig.sh
@@ -782,6 +782,7 @@ uquadtype='uint64_t'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='undef'
diff --git a/uconfig64.sh b/uconfig64.sh
index 8537547870..748dfc0753 100644
--- a/uconfig64.sh
+++ b/uconfig64.sh
@@ -782,6 +782,7 @@ uquadtype='unsigned long'
use5005threads='undef'
use64bitall='define'
use64bitint='define'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='undef'
diff --git a/win32/config.ce b/win32/config.ce
index dae0c606ad..696f91d09a 100644
--- a/win32/config.ce
+++ b/win32/config.ce
@@ -981,6 +981,7 @@ uquadtype='unsigned __int64'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='define'
usedevel='undef'
usedl='define'
diff --git a/win32/config.gc b/win32/config.gc
index 2f5e6d0958..a92880de87 100644
--- a/win32/config.gc
+++ b/win32/config.gc
@@ -1025,6 +1025,7 @@ uquadtype='unsigned long long'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='define'
diff --git a/win32/config.vc b/win32/config.vc
index 3aa1992e40..77c8fa1f1c 100644
--- a/win32/config.vc
+++ b/win32/config.vc
@@ -1024,6 +1024,7 @@ uquadtype='unsigned __int64'
use5005threads='undef'
use64bitall='undef'
use64bitint='undef'
+usecbacktrace='undef'
usecrosscompile='undef'
usedevel='undef'
usedl='define'