This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
use &dl_error rather than &dl_load_file as the guard for calling
authorGurusamy Sarathy <gsar@cpan.org>
Tue, 25 Apr 2000 18:11:53 +0000 (18:11 +0000)
committerGurusamy Sarathy <gsar@cpan.org>
Tue, 25 Apr 2000 18:11:53 +0000 (18:11 +0000)
boot_DynaLoader() (meant to fix dl_error() redefined warnings in
statically built perl)

p4raw-id: //depot/perl@5947

ext/DynaLoader/DynaLoader_pm.PL
ext/DynaLoader/XSLoader_pm.PL

index e0eb604..55b8eca 100644 (file)
@@ -114,9 +114,9 @@ push(@dl_library_path, split(/:/, $ENV{LD_LIBRARY_PATH}))
 }
 
 # No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
 }
 
 # No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
+# NOTE: All dl_*.xs (including dl_none.xs) define a dl_error() XSUB
 boot_DynaLoader('DynaLoader') if defined(&boot_DynaLoader) &&
 boot_DynaLoader('DynaLoader') if defined(&boot_DynaLoader) &&
-                                !defined(&dl_load_file);
-
+                                !defined(&dl_error);
 
 if ($dl_debug) {
     print STDERR "DynaLoader.pm loaded (@INC, @dl_library_path)\n";
 
 if ($dl_debug) {
     print STDERR "DynaLoader.pm loaded (@INC, @dl_library_path)\n";
index 8cdfd63..7657410 100644 (file)
@@ -37,10 +37,12 @@ print OUT '  my $dl_dlext = ', to_string($Config::Config{'dlext'}), ";\n" ;
 
 print OUT <<'EOT';
 
 
 print OUT <<'EOT';
 
-# No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
 package DynaLoader;
 package DynaLoader;
+
+# No prizes for guessing why we don't say 'bootstrap DynaLoader;' here.
+# NOTE: All dl_*.xs (including dl_none.xs) define a dl_error() XSUB
 boot_DynaLoader('DynaLoader') if defined(&boot_DynaLoader) &&
 boot_DynaLoader('DynaLoader') if defined(&boot_DynaLoader) &&
-                                !defined(&dl_load_file);
+                                !defined(&dl_error);
 package XSLoader;
 
 1; # End of main code
 package XSLoader;
 
 1; # End of main code