summaryrefslogtreecommitdiff
path: root/lib/ExtUtils
diff options
context:
space:
mode:
authorDoug MacEachern <dougm@opengroup.org>1997-02-27 11:25:04 -0500
committerChip Salzenberg <chip@atlantic.net>1997-02-25 13:12:02 +1200
commitaf24809749a51c07bdc647819c54e852071ea525 (patch)
treed73e18bcec10a404c7139d786241e4f54f9e4678 /lib/ExtUtils
parent5addc575db0acbcd6850a5c4f853c591b31306dd (diff)
downloadperl-af24809749a51c07bdc647819c54e852071ea525.tar.gz
Allow explicit '-lperl' in link arguments
private-msgid: <199702271625.LAA25402@postman.osf.org>
Diffstat (limited to 'lib/ExtUtils')
-rw-r--r--lib/ExtUtils/Embed.pm6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/ExtUtils/Embed.pm b/lib/ExtUtils/Embed.pm
index 4a371840b9..4d2ed6a77a 100644
--- a/lib/ExtUtils/Embed.pm
+++ b/lib/ExtUtils/Embed.pm
@@ -17,7 +17,7 @@ use vars qw(@ISA @EXPORT $VERSION
);
use strict;
-$VERSION = sprintf("%d.%02d", q$Revision: 1.22 $ =~ /(\d+)\.(\d+)/);
+$VERSION = sprintf("%d.%02d", q$Revision: 1.2201 $ =~ /(\d+)\.(\d+)/);
#for the namespace change
$Devel::embed::VERSION = "99.99";
@@ -199,9 +199,11 @@ sub ldopts {
}
#print STDERR "\@potential_libs = @potential_libs\n";
+ my $libperl = (grep(/^(-l\w+perl)$/, @link_args))[0] || "-lperl";
+
my($extralibs, $bsloadlibs, $ldloadlibs, $ld_run_path) =
$MM->ext(join ' ',
- $MM->catdir("-L$Config{archlibexp}", "CORE"), " -lperl",
+ $MM->catdir("-L$Config{archlibexp}", "CORE"), " $libperl",
@potential_libs);
my $ld_or_bs = $bsloadlibs || $ldloadlibs;