# -*- perl -*- use strict; use Config; use ExtUtils::MakeMaker qw(WriteMakefile); use Test::Harness; require 5.005; my $base; if ($base ||= $ENV{NDB_BASE}) { warn "Using NDB_BASE=$base\n"; } $base or die "FATAL: need env.variable NDB_BASE\n"; my $top; if ($top ||= $ENV{NDB_TOP}) { warn "Using NDB_TOP=$top\n"; } $top or die "FATAL: need env.variable NDB_TOP\n"; my @scripts = qw(ndbnet.pl ndbnetd.pl); for my $f (@scripts) { my $p = $f; $p =~ s/\.pl$//; unlink("$p.sh"); open(G, ">$p.sh") or die "$p.sh: $!"; if ($Config{osname} ne 'MSWin32') { print G < 'NDB', PM=> \%pm, EXE_FILES=> [ qw(ndbrun) ], # install PREFIX=> $top, LIB=> "$top/lib/perl5", ); sub MY::postamble { my $mk = ""; $mk .= "\n" . <