summaryrefslogtreecommitdiff
path: root/perliol.h
diff options
context:
space:
mode:
authorCraig A. Berry <craigberry@mac.com>2015-01-01 09:02:37 -0600
committerCraig A. Berry <craigberry@mac.com>2015-01-01 09:02:37 -0600
commit0c2c3d000e799a35bdc2bdd24feaf77cf854a2dd (patch)
treeae72485ab8b43973f01b6eba132451369be13e64 /perliol.h
parentf660499c5fbbc20023791625e914d7662b557e85 (diff)
downloadperl-0c2c3d000e799a35bdc2bdd24feaf77cf854a2dd.tar.gz
Fix PerlIO vtables on VMS.
f0e5c859d36afe5 broke the build because it caused the PerlIO_funcs declarations to be const in perlio.h and EXTPERLIO in perliol.h and on VMS, EXTPERLIO was EXTCONST which is globalref. The compiler considers globalref and const to be incompatible. As a workaround, make EXTPERLIO "extern const" on VMS only. The whole custom global data model on VMS probably needs a rethink, but this gets the build working again.
Diffstat (limited to 'perliol.h')
-rw-r--r--perliol.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/perliol.h b/perliol.h
index 87b1fc77fa..9852026475 100644
--- a/perliol.h
+++ b/perliol.h
@@ -109,7 +109,11 @@ struct _PerlIO {
/* Data exports - EXTCONST rather than extern is needed for Cygwin */
#undef EXTPERLIO
#ifdef PERLIO_FUNCS_CONST
-#define EXTPERLIO EXTCONST
+#ifdef __VMS
+# define EXTPERLIO extern const
+#else
+# define EXTPERLIO EXTCONST
+#endif
#else
#define EXTPERLIO EXT
#endif