develooper Front page | perl.perl5.porters | Postings from November 2008

could we add usedevel to config.h?

Thread Next
From:
Nicholas Clark
Date:
November 27, 2008 12:28
Subject:
could we add usedevel to config.h?
Message ID:
20081127202807.GG49335@plum.flirble.org
Could we do something like the appended to add usedevel to config.sh
and hence to config.h?

[Not sure how to default all the canned config.sh files in various places]

Nicholas Clark

==== //depot/perl/Configure#711 - /Volumes/Stuff/p4perl/perl/Configure ====
--- /tmp/tmp.47998.50	2008-11-27 20:24:55.000000000 +0000
+++ /Volumes/Stuff/p4perl/perl/Configure	2008-11-27 19:52:31.000000000 +0000
@@ -1197,6 +1197,7 @@ use64bitint=''
 dtrace=''
 usedtrace=''
 usefaststdio=''
+usedevel=''
 ccflags_uselargefiles=''
 ldflags_uselargefiles=''
 libswanted_uselargefiles=''
@@ -2142,7 +2143,8 @@ EOF
 : See if we are using a devel version and want that
 xversion=`awk '/define[ 	]+PERL_VERSION/ {print $3}' $rsrc/patchlevel.h`
 case "$usedevel" in
-$define|true|[yY]*) ;;
+$define|true|[yY]*)
+   usedevel="$define" ;;
 *) case "$xversion" in
    *[13579])
 	cat >&4 <<EOH
@@ -2175,6 +2177,7 @@ EOH
 	esac
 	;;
     esac
+    usedevel="$undef"
     ;;
 esac
 case "$usedevel" in
@@ -23028,6 +23031,7 @@ use5005threads='$use5005threads'
 use64bitall='$use64bitall'
 use64bitint='$use64bitint'
 usecrosscompile='$usecrosscompile'
+usedevel='$usedevel'
 usedl='$usedl'
 usedtrace='$usedtrace'
 usefaststdio='$usefaststdio'
==== //depot/perl/Porting/Glossary#197 - /Volumes/Stuff/p4perl/perl/Porting/Glossary ====
--- /tmp/tmp.47998.101	2008-11-27 20:24:55.000000000 +0000
+++ /Volumes/Stuff/p4perl/perl/Porting/Glossary	2008-11-27 19:49:23.000000000 +0000
@@ -4890,6 +4890,10 @@ usecrosscompile (Cross.U):
 	This variable conditionally defines the USE_CROSS_COMPILE symbol,
 	and indicates that Perl has been cross-compiled.
 
+usedevel (XXX.U):
+	This variable indicates that Perl was configured with development
+	features enabled.  This should not be done for production builds.
+
 usedl (dlsrc.U):
 	This variable indicates if the system supports dynamic
 	loading of some sort.  See also dlsrc and dlobj.
==== //depot/perl/config_h.SH#351 - /Volumes/Stuff/p4perl/perl/config_h.SH ====
--- /tmp/tmp.47998.130	2008-11-27 20:24:55.000000000 +0000
+++ /Volumes/Stuff/p4perl/perl/config_h.SH	2008-11-27 19:49:41.000000000 +0000
@@ -4075,6 +4075,13 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#und
  */
 #$d_writev HAS_WRITEV		/**/
 
+/* PERL_USE_DEVEL:
+ *	This symbol, if defined, indicates that Perl was configured with
+ *	-Dusedevel, to enable development features.  This should not be
+ *	done for production builds.
+ */
+#$usedevel PERL_USE_DEVEL		/**/
+
 /* USE_DYNAMIC_LOADING:
  *	This symbol, if defined, indicates that dynamic loading of
  *	some sort is available.
==== //depot/perl/perl.c#889 - /Volumes/Stuff/p4perl/perl/perl.c ====
--- /tmp/tmp.47998.219	2008-11-27 20:24:56.000000000 +0000
+++ /Volumes/Stuff/p4perl/perl/perl.c	2008-11-27 19:45:00.000000000 +0000
@@ -1876,6 +1876,9 @@ S_parse_body(pTHX_ char **env, XSINIT_t 
 #  ifdef PERL_MEM_LOG_TIMESTAMP
 			     " PERL_MEM_LOG_TIMESTAMP"
 #  endif
+#  ifdef PERL_USE_DEVEL
+			     " PERL_USE_DEVEL"
+#  endif
 #  ifdef PERL_USE_SAFE_PUTENV
 			     " PERL_USE_SAFE_PUTENV"
 #  endif

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About