diff options
author | Charles Bailey <bailey@newman.upenn.edu> | 1998-03-26 10:11:50 -0500 |
---|---|---|
committer | Malcolm Beattie <mbeattie@sable.ox.ac.uk> | 1998-04-02 16:03:37 +0000 |
commit | 17f28c40fa08b585b95d4a2531b1cd975d11e986 (patch) | |
tree | a3848d6befdc55f7cc1a326e0b4b19b31ad09869 /ext/SDBM_File | |
parent | ec2ab091f034a27dfbd7d815fad4e3e670b743e9 (diff) | |
download | perl-17f28c40fa08b585b95d4a2531b1cd975d11e986.tar.gz |
Next wave of _63 VMS patches
p4raw-id: //depot/perl@854
Diffstat (limited to 'ext/SDBM_File')
-rw-r--r-- | ext/SDBM_File/Makefile.PL | 13 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/Makefile.PL | 12 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/dba.c | 1 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/dbd.c | 1 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/dbu.c | 1 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/hash.c | 1 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/pair.c | 1 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/sdbm.c | 5 | ||||
-rw-r--r-- | ext/SDBM_File/sdbm/sdbm.h | 11 |
9 files changed, 28 insertions, 18 deletions
diff --git a/ext/SDBM_File/Makefile.PL b/ext/SDBM_File/Makefile.PL index c0daa064c7..b639b2948f 100644 --- a/ext/SDBM_File/Makefile.PL +++ b/ext/SDBM_File/Makefile.PL @@ -6,13 +6,8 @@ use ExtUtils::MakeMaker; # which perform the corresponding actions in the subdirectory. $define = ($^O eq 'MSWin32') ? '-DMSDOS' : ''; -if ($^O eq 'MSWin32') { - $myextlib = 'sdbm\\libsdbm$(LIB_EXT)'; -} elsif ($^O eq 'VMS') { - $myextlib = 'sdbm/libsdbm$(LIB_EXT)'; -} else { - $myextlib = 'sdbm/libsdbm$(LIB_EXT)'; -} +if ($^O eq 'MSWin32') { $myextlib = 'sdbm\\libsdbm$(LIB_EXT)'; } +else { $myextlib = 'sdbm/libsdbm$(LIB_EXT)'; } WriteMakefile( NAME => 'SDBM_File', @@ -21,8 +16,6 @@ WriteMakefile( XSPROTOARG => '-noprototypes', # XXX remove later? VERSION_FROM => 'SDBM_File.pm', DEFINE => $define, -# NORECURS => $^O eq 'VMS', -# SKIP => $^O eq 'VMS' ? 'subdirs' : '', # Don't do the subdirs section for VMS ); sub MY::postamble { @@ -33,7 +26,7 @@ $(MYEXTLIB): sdbm/Makefile '; } else { ' -$(MYEXTLIB): [.sdbm]descrip.mms +$(MYEXTLIB) : [.sdbm]descrip.mms set def [.sdbm] $(MMS) all set def [-] diff --git a/ext/SDBM_File/sdbm/Makefile.PL b/ext/SDBM_File/sdbm/Makefile.PL index e9d4dcd0fa..96f5b7af91 100644 --- a/ext/SDBM_File/sdbm/Makefile.PL +++ b/ext/SDBM_File/sdbm/Makefile.PL @@ -3,13 +3,19 @@ use ExtUtils::MakeMaker; $define = '-DSDBM -DDUFF'; $define .= ' -DWIN32' if ($^O eq 'MSWin32'); +if ($^O eq 'VMS') { # Old VAXC compiler can't handle Duff's device + require Config; + $define =~ s/\s+-DDUFF// if $Config::Config{'vms_cc_type'} eq 'vaxc'; +} + WriteMakefile( NAME => 'sdbm', # (doesn't matter what the name is here) oh yes it does # LINKTYPE => 'static', DEFINE => $define, INC => '-I$(PERL_INC)', # force PERL_INC dir ahead of system -I's - SKIP => [qw(dynamic dynamic_lib)], - OBJECT => ($^O eq 'VMS') ? 'sdbm.obj pair.obj hash.obj' : '$(O_FILES)', + INST_ARCHLIB => '.', + SKIP => [qw(dynamic dynamic_lib dlsyms)], + OBJECT => '$(O_FILES)', clean => {'FILES' => 'dbu libsdbm.a dbd dba dbe x-dbu *.dir *.pag'}, H => [qw(tune.h sdbm.h pair.h $(PERL_INC)/config.h)], C => [qw(sdbm.c pair.c hash.c)] @@ -24,8 +30,10 @@ INST_STATIC = libsdbm$(LIB_EXT) sub MY::top_targets { ' all :: static + $(NOECHO) $(NOOP) config :: + $(NOECHO) $(NOOP) lint: lint -abchx $(LIBSRCS) diff --git a/ext/SDBM_File/sdbm/dba.c b/ext/SDBM_File/sdbm/dba.c index 4f227e5245..05e70c8961 100644 --- a/ext/SDBM_File/sdbm/dba.c +++ b/ext/SDBM_File/sdbm/dba.c @@ -4,6 +4,7 @@ #include <stdio.h> #include <sys/file.h> +#include "EXTERN.h" #include "sdbm.h" char *progname; diff --git a/ext/SDBM_File/sdbm/dbd.c b/ext/SDBM_File/sdbm/dbd.c index 697a547597..04ab842e2d 100644 --- a/ext/SDBM_File/sdbm/dbd.c +++ b/ext/SDBM_File/sdbm/dbd.c @@ -4,6 +4,7 @@ #include <stdio.h> #include <sys/file.h> +#include "EXTERN.h" #include "sdbm.h" char *progname; diff --git a/ext/SDBM_File/sdbm/dbu.c b/ext/SDBM_File/sdbm/dbu.c index 106262872e..a3c0004da9 100644 --- a/ext/SDBM_File/sdbm/dbu.c +++ b/ext/SDBM_File/sdbm/dbu.c @@ -1,6 +1,7 @@ #include <stdio.h> #include <sys/file.h> #ifdef SDBM +#include "EXTERN.h" #include "sdbm.h" #else #include <ndbm.h> diff --git a/ext/SDBM_File/sdbm/hash.c b/ext/SDBM_File/sdbm/hash.c index 514bb5ed1a..9b27648599 100644 --- a/ext/SDBM_File/sdbm/hash.c +++ b/ext/SDBM_File/sdbm/hash.c @@ -8,6 +8,7 @@ */ #include "config.h" +#include "EXTERN.h" #include "sdbm.h" /* * polynomial conversion ignoring overflows diff --git a/ext/SDBM_File/sdbm/pair.c b/ext/SDBM_File/sdbm/pair.c index e1a6ee6f43..6b41f88471 100644 --- a/ext/SDBM_File/sdbm/pair.c +++ b/ext/SDBM_File/sdbm/pair.c @@ -12,6 +12,7 @@ static char rcsid[] = "$Id: pair.c,v 1.10 90/12/13 13:00:35 oz Exp $"; #endif #include "config.h" +#include "EXTERN.h" #include "sdbm.h" #include "tune.h" #include "pair.h" diff --git a/ext/SDBM_File/sdbm/sdbm.c b/ext/SDBM_File/sdbm/sdbm.c index 7fbba0f00a..7bf9d3a97b 100644 --- a/ext/SDBM_File/sdbm/sdbm.c +++ b/ext/SDBM_File/sdbm/sdbm.c @@ -11,6 +11,7 @@ static char rcsid[] = "$Id: sdbm.c,v 1.16 90/12/13 13:01:31 oz Exp $"; #endif +#include "INTERN.h" #include "config.h" #include "sdbm.h" #include "tune.h" @@ -39,7 +40,7 @@ extern int errno; extern Malloc_t malloc proto((MEM_SIZE)); extern Free_t free proto((Malloc_t)); -extern Off_t lseek(int, off_t, int); +extern Off_t lseek(int, Off_t, int); #endif /* @@ -72,8 +73,6 @@ static long masks[] = { 001777777777, 003777777777, 007777777777, 017777777777 }; -datum nullitem = {NULL, 0}; - DBM * sdbm_open(register char *file, register int flags, register int mode) { diff --git a/ext/SDBM_File/sdbm/sdbm.h b/ext/SDBM_File/sdbm/sdbm.h index b3ed2d4b8b..591ff24799 100644 --- a/ext/SDBM_File/sdbm/sdbm.h +++ b/ext/SDBM_File/sdbm/sdbm.h @@ -51,7 +51,11 @@ typedef struct { int dsize; } datum; -extern datum nullitem; +EXTCONST datum nullitem +#ifdef DOINIT + = {NULL, 0} +#endif + ; #if defined(__STDC__) || defined(__cplusplus) || defined(CAN_PROTOTYPE) #define proto(p) p @@ -120,12 +124,13 @@ extern long sdbm_hash proto((char *, int)); #include <ctype.h> #include <setjmp.h> -#if defined(I_UNISTD) || defined(VMS) +#if defined(I_UNISTD) #include <unistd.h> #endif #ifdef VMS -# include <fcntl.h> +# include <file.h> +# include <unixio.h> #endif #if !defined(MSDOS) && !defined(WIN32) && !defined(VMS) |