constant_add_symbol needs to be static, else static builds can fail at
[p5sagit/p5-mst-13.2.git] / lib / ExtUtils / Constant / ProxySubs.pm
index 2df31b9..d9c9ac3 100644 (file)
@@ -198,7 +198,8 @@ sub WriteConstants {
     my $symbol_table = C_stringify($package) . '::';
 
     print $c_fh $self->header(), <<"EOADD";
-void ${c_subname}_add_symbol($pthx HV *hash, const char *name, I32 namelen, SV *value) {
+static void
+${c_subname}_add_symbol($pthx HV *hash, const char *name, I32 namelen, SV *value) {
     SV **sv = hv_fetch(hash, name, namelen, TRUE);
     if (!sv) {
         Perl_croak($athx "Couldn't add key '%s' to %%$package_sprintf_safe\::",