Fri May 30 17:51:48 2000 Dan Harkless <dan-nmh@dilvish.speed.net>
* etc/Makefile.in was incorrectly installing mts.conf.in and
- sendfiles.in -- fixed. Changed the suffix for the backed-up
- previous versions of the etc files from the ambiguous .old to
- .prev. Added call to diff -- only keep the .prev files around if
- different from the newly-installed versions (intentionally didn't
- redirect output to /dev/null so you'll notice when your changed
- versions are getting moved aside).
+ sendfiles.in -- fixed. Generated sendfiles script was not a
+ dependency of the `all' target, and was incorrectly included in
+ the distribution. Changed the suffix for the backed-up previous
+ versions of the etc files from the ambiguous .old to .prev. Added
+ call to diff -- only keep the .prev files around if different from
+ the newly-installed versions (intentionally didn't redirect output
+ to /dev/null so you'll notice when your changed versions are
+ getting moved aside).
* INSTALL never documented the etc/*.old thing. Documented the
new etc/*.prev thing (including a note to watch for diff output).
# templates and scripts from which non-static files are generated
GENERATED_FILE_SRCS = mhn.defaults.sh mhn.find.sh mts.conf.in sendfiles.in
-# files generated using above GENERATED_FILE_SRCs
-GENERATED_FILES = mhn.defaults mts.conf sendfiles
+# scripts generated using above GENERATED_FILE_SRCs
+GENERATED_BIN_FILES = sendfiles
-# data files we need to install (in etc)
-INSTALL_FILES = $(STATIC_FILES) $(GENERATED_FILES)
+# non-scripts generated using above GENERATED_FILE_SRCs
+GENERATED_ETC_FILES = mhn.defaults mts.conf
# scripts we need to install (in bin)
-SCRIPTS = sendfiles
+INSTALL_BIN_FILES = $(GENERATED_BIN_FILES)
+
+# non-scripts we need to install (in etc)
+INSTALL_ETC_FILES = $(STATIC_FILES) $(GENERATED_ETC_FILES)
# auxiliary files (included in distribution but not installed)
AUX = Makefile.in
# all non-generated files in this directory are included in the distribution
-DIST = $(STATIC_FILES) $(GENERATED_FILE_SRCS) $(SCRIPTS) $(AUX)
+DIST = $(STATIC_FILES) $(GENERATED_FILE_SRCS) $(AUX)
# ========= DEPENDENCIES FOR BUILDING ==========
-all: $(GENERATED_FILES)
+all: $(GENERATED_BIN_FILES) $(GENERATED_ETC_FILES)
mhn.defaults: $(srcdir)/mhn.defaults.sh $(MHNSEARCHPROG)
rm -f $@
rm -f $@
$(SED) -e 's,%libdir%,$(libdir),' < $(srcdir)/sendfiles.in > $@
-install: install-files install-scripts
+install: install-bin-files install-etc-files
-install-files:
+install-bin-files:
+ $(top_srcdir)/mkinstalldirs $(bindir)
+ for script in $(INSTALL_BIN_FILES); do \
+ $(INSTALL_PROGRAM) $(srcdir)/$$script $(bindir)/$$script; \
+ done
+
+install-etc-files:
$(top_srcdir)/mkinstalldirs $(etcdir)
- for file in $(INSTALL_FILES); do \
+ for file in $(INSTALL_ETC_FILES); do \
echo $$file; \
if [ -f $(etcdir)/$$file ]; then \
mv $(etcdir)/$$file $(etcdir)/$$file.prev; \
fi; \
done
-install-scripts:
- $(top_srcdir)/mkinstalldirs $(bindir)
- for script in $(SCRIPTS); do \
- $(INSTALL_PROGRAM) $(srcdir)/$$script $(bindir)/$$script; \
- done
-
-uninstall: uninstall-files uninstall-scripts
+uninstall: uninstall-bin-files uninstall-etc-files
-uninstall-files:
- for file in $(INSTALL_FILES); do \
- rm -f $(etcdir)/$$file; \
+uninstall-bin-files:
+ for script in $(INSTALL_BIN_FILES); do \
+ rm -f $(bindir)/$$script; \
done
-uninstall-scripts:
- for script in $(SCRIPTS); do \
- rm -f $(bindir)/$$script; \
+uninstall-etc-files:
+ for file in $(INSTALL_ETC_FILES); do \
+ rm -f $(etcdir)/$$file; \
done
# ========== DEPENDENCIES FOR CLEANUP ==========
rm -f *~
clean: mostlyclean
- rm -f $(GENERATED_FILES)
+ rm -f $(GENERATED_ETC_FILES)
distclean: clean
rm -f Makefile