--- Makefile.in.orig 1994-12-12 20:21:47 UTC +++ Makefile.in @@ -47,7 +47,7 @@ INCLUDE_DIR = $(prefix)/include INCLUDE_DIR = $(prefix)/include # top-level directory for manual entries -MAN_DIR = $(prefix)/man +MAN_DIR = $(prefix)/share/man # directory in which to install manual entries for library functions MAN3_DIR = $(MAN_DIR)/man3 @@ -175,25 +175,13 @@ vp_opts.c: makeopts Makefile cc -o makeopts makeopts.c vp_opts.c: makeopts Makefile - makeopts vp_opts.c $(CFLAGS) + ./makeopts vp_opts.c $(CFLAGS) $(COMP_SRCS): $(COMP_IN) - @for i in $(COMP_SRCS) ; \ - do \ - rm -f $$i ;\ - echo "$(M4) -DSourceFile=$$i $(COMP_IN) > $$i" ;\ - $(M4) -DSourceFile=$$i $(COMP_IN) > $$i; \ - chmod -w $$i; \ - done + $(M4) -DSourceFile=$@ $(COMP_IN) > $@ && chmod -w $@ $(WARP_SRCS): $(WARP_IN) - @for i in $(WARP_SRCS) ; \ - do \ - rm -f $$i ;\ - echo "$(M4) -DSourceFile=$$i $(WARP_IN) > $$i" ;\ - $(M4) -DSourceFile=$$i $(WARP_IN) > $$i; \ - chmod -w $$i; \ - done + $(M4) -DSourceFile=$@ $(WARP_IN) > $@ && chmod -w $@ examples: libvolpack.a cd examples; make @@ -201,7 +189,7 @@ install-binaries: libvolpack.a install: install-binaries install-include install-man install-binaries: libvolpack.a - @for i in $(LIB_DIR) ; \ + @for i in $(DESTDIR)$(LIB_DIR) ; \ do \ if [ ! -d $$i ] ; then \ echo "Making directory $$i"; \ @@ -211,11 +199,11 @@ install-binaries: libvolpack.a fi; \ done; @echo "Installing libvolpack.a" - @$(INSTALL_DATA) libvolpack.a $(LIB_DIR) - @$(RANLIB) $(LIB_DIR)/libvolpack.a + @$(INSTALL_DATA) libvolpack.a $(DESTDIR)$(LIB_DIR) + @$(RANLIB) $(DESTDIR)$(LIB_DIR)/libvolpack.a install-include: - @for i in $(INCLUDE_DIR) ; \ + @for i in $(DESTDIR)$(INCLUDE_DIR) ; \ do \ if [ ! -d $$i ] ; then \ echo "Making directory $$i"; \ @@ -225,10 +213,10 @@ install-include: fi; \ done; @echo "Installing volpack.h" - @$(INSTALL_DATA) volpack.h $(INCLUDE_DIR) + @$(INSTALL_DATA) volpack.h $(DESTDIR)$(INCLUDE_DIR) install-man: - @for i in $(MAN_DIR) $(MAN3_DIR) ; \ + @for i in $(DESTDIR)$(MAN_DIR) $(DESTDIR)$(MAN3_DIR) ; \ do \ if [ ! -d $$i ] ; then \ echo "Making directory $$i"; \ @@ -239,10 +227,9 @@ install-man: done; @cd $(SRC_DIR)/man/src; for i in *.3; \ do \ - echo "Installing man/src/$$i"; \ - rm -f $(MAN3_DIR)/$$i; \ - cp $$i $(MAN3_DIR); \ - chmod 444 $(MAN3_DIR)/$$i; \ + echo "Installing man/src/volpack-$$i"; \ + cp $$i $(DESTDIR)$(MAN3_DIR)/volpack-$$i; \ + chmod 444 $(DESTDIR)$(MAN3_DIR)/volpack-$$i; \ done; Makefile: $(SRC_DIR)/Makefile.in