summaryrefslogtreecommitdiff
path: root/perl.h
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2011-05-01 12:25:58 +0100
committerNicholas Clark <nick@ccl4.org>2011-06-12 16:15:22 +0200
commit0447859b8a048144ae0ece76a2f7595840942fcb (patch)
tree665b7b2c2e89cfdc6022bd547b12e17572790aa3 /perl.h
parent58f645e20791a7788fcb38189895a712d5c53419 (diff)
downloadperl-0447859b8a048144ae0ece76a2f7595840942fcb.tar.gz
Move PL_sh_path to perl.h (except for OS/2), as it's const char[]
On OS/2, keep it in perlvars.h, as it's not const there. makedef.pl doesn't pay attention to C pre-processor symbols, so it will always see the declaration in perlvars.h, and add the symbol to the linker file, so no need to mention sh_path in globvar.sym. Add special case logic in regen/embed.pl to make the embedvar.h macros for PL_sh_path defined only on OS/2.
Diffstat (limited to 'perl.h')
-rw-r--r--perl.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/perl.h b/perl.h
index 5bbda62cb3..77824d1956 100644
--- a/perl.h
+++ b/perl.h
@@ -4251,6 +4251,12 @@ EXTCONST char PL_No[]
EXTCONST char PL_hexdigit[]
INIT("0123456789abcdef0123456789ABCDEF");
+/* This is constant on most architectures, a global on OS/2 */
+#ifndef OS2
+EXTCONST char PL_sh_path[]
+ INIT(SH_PATH); /* full path of shell */
+#endif
+
#ifdef CSH
EXTCONST char PL_cshname[]
INIT(CSH);