$NetBSD: patch-aa,v 1.5 2013/04/28 03:19:36 dholland Exp $ - configure for pkgsrc - honor PKGMANDIR - honor pkgsrc CFLAGS and LDFLAGS --- Makefile.orig 2005-09-30 22:14:41.000000000 +0000 +++ Makefile @@ -21,12 +21,12 @@ SHELL = /bin/sh # If they don't exist, this makefile will try to create the directories # LIBDIR and SHAREDIR. All others must already exist. -JOVEHOME = /usr/local -SHAREDIR = $(JOVEHOME)/lib/jove +JOVEHOME = $(PREFIX) +SHAREDIR = $(JOVEHOME)/share/jove LIBDIR = $(JOVEHOME)/lib/jove BINDIR = $(JOVEHOME)/bin XEXT= -MANDIR = $(JOVEHOME)/man/man$(MANEXT) +MANDIR = $(JOVEHOME)/$(PKGMANDIR)/man$(MANEXT) MANEXT = 1 # TMPDIR is where the tmp files get stored, usually /tmp, /var/tmp, or @@ -38,11 +38,11 @@ MANEXT = 1 # (in case the system startup salvages tempfiles by moving them, # which is probably a good idea). -TMPDIR = /tmp +TMPDIR = /var/tmp RECDIR = /var/preserve # DFLTSHELL is the default shell invoked by JOVE and TEACHJOVE. -DFLTSHELL = /bin/csh +DFLTSHELL = /bin/sh # The install commands of BSD and System V differ in unpleasant ways: # -c: copy (BSD); -c dir: destination directory (SysV) @@ -53,15 +53,15 @@ DFLTSHELL = /bin/csh # "cp" will work reasonably well, but be aware that any links continue # referencing the old file with new contents. -INSTALLFLAGS = # -g bin -o root +INSTALLFLAGS = -g $(ROOT_GROUP) -o $(ROOT_USER) # to install executable files -XINSTALL=cp +XINSTALL=$(BSD_INSTALL_PROGRAM) #XINSTALL=/usr/ucb/install $(INSTALLFLAGS) -c -m 755 # -s #CYGWIN32: XINSTALL=install $(INSTALLFLAGS) -c -m 755 # to install text files -TINSTALL=cp +TINSTALL=$(BSD_INSTALL_DATA) #TINSTALL=/usr/ucb/install $(INSTALLFLAGS) -c -m 644 #CYGWIN32: TINSTALL=install $(INSTALLFLAGS) -c -m 644 @@ -146,7 +146,7 @@ SYSDEFS = -DBSDPOSIX_STDC # On DEC OSF/1 and Digital UNIX VV4.0, add -std1 to enable ANSI C features # and perhaps -g3 for more debugging info with optimization. -OPTFLAGS = -O +OPTFLAGS += -O2 # For making dependencies under BSD systems DEPENDFLAG = -M @@ -181,13 +181,13 @@ EXTRALIBS = # PDP-11 with separate I&D: -i # PDP-11 without separate I&D: -n -LDFLAGS = +LDFLAGS+= # for SCO Xenix, set # MEMFLAGS = -Mle # CFLAGS = -LARGE -O -F 3000 -K -Mle (say -Mle2 for an 80286) -CFLAGS = $(OPTFLAGS) $(SYSDEFS) +CFLAGS+= $(OPTFLAGS) $(SYSDEFS) # For SYSVR4 (/usr/ucb/cc will NOT work because of setjmp.h): # CC = /usr/bin/cc