case "$xxx" in
DynaLoader|dynaload) ;;
*)
- if $test -f $xxx/$xxx.xs -o -f $xxx/$xxx.c; then
- known_extensions="$known_extensions $1$xxx";
+ this_ext=`echo $xxx | $sed -e s/-/\\\//g`;
+ leaf=`echo $xxx | $sed -e s/.*-//`;
+ if $test -f $xxx/$leaf.xs -o -f $xxx/$leaf.c; then
+ known_extensions="$known_extensions $1$this_ext";
elif $test -f $xxx/Makefile.PL; then
- nonxs_extensions="$nonxs_extensions $1$xxx";
+ nonxs_extensions="$nonxs_extensions $1$this_ext";
else
if $test -d $xxx -a $# -lt 10; then
set $1$xxx/ $*;
foreach my $spec (@extspec) {
my $mname = $spec;
$mname =~ s!/!::!g;
- my $ext_pathname = "ext/$spec";
+ my $ext_pathname;
+ if (-d "ext/$spec") {
+ # Old style ext/Data/Dumper/
+ $ext_pathname = "ext/$spec";
+ } else {
+ # New style ext/Data-Dumper/
+ my $copy = $spec;
+ $copy =~ tr!/!-!;
+ $ext_pathname = "ext/$copy";
+ }
my $up = $ext_pathname;
$up =~ s![^/]+!..!g;