]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
Clean up our cleaning
authorBenjamin Kaduk <kaduk@mit.edu>
Wed, 8 Oct 2014 20:51:33 +0000 (16:51 -0400)
committerJeffrey Altman <jaltman@your-file-system.com>
Fri, 28 Nov 2014 23:04:15 +0000 (18:04 -0500)
'make clean' and 'make maintainer-clean' still leave around a fair
number of droppings, prior to this commit.

We were not descending into the 'tests' top-level directory while
cleaning.  Furthermore, tests/opr/Makefile needed $(LT_CLEAN), and
tests/rx/Makefile needed to spell it correctly.

The libtoolization places a lot of files to be removed in the
'pristine' target.

The processing used to implement the =include directive in the pod
sources for the man pages leaves around the non-.in versions of
files; we should clean that up in the 'pristine' target as well.

The 'pristine' target should likewise remove the man pages which
are generated from the pod files.

Additionally, the documentation build uses a Doxyfile which is
output by configure; that should be removed (if present) by the
'distclean' target.

When hcrypto was converted to libtool, the use of ${OBJECTS} in
the clean target was missed, so we were leaving around most of the
actual object files -- $(LT_CLEAN) does not handle this for us.
Change the rule to remove *.o as is done elsewhere.

The conversion of libafsrpc to libtool added a convenience library
libafsrpc_sys.la, and changed how syscall.o was generated on
most architectures, to be the result of compiling an empty .c file
(instead of just an empty .o file).  This introduced a new
intermediate file, syscall.c, which must be cleaned up.

tvolser was only listing volserver and not vos in its list of
executables to remove while cleaning.

The conversion of venus/test to libtool was not done quite right.
Makefile.libtool and the .lo suffix are only needed when libtool
is being used to link *libraries*; just Makefile.pthread suffices
when libtool is being used to link executables.  As such, remove
the inclusion of Makefile.libtool, and change the .lo targets back
to regular .o ones, and add back *.o to the list of files to remove
in the 'clean' target (it was needed there even without the
other changes to that Makefile).

Change-Id: Ifbc3eee4ad2dce54df991301bc5edd11eb29a24a
Reviewed-on: http://gerrit.openafs.org/11532
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Makefile.in
src/crypto/hcrypto/Makefile.in
src/sys/Makefile.in
src/tvolser/Makefile.in
src/venus/test/Makefile.in
tests/opr/Makefile.in
tests/rx/Makefile.in

index 455c04a31ad3ec87aa255e83dbdde5c27f5e9f99..082c63c8e9599be274694980202e1b0c61147e6a 100644 (file)
@@ -780,6 +780,7 @@ clean2:
        -(cd src; /bin/rm cscope.out)
        -(cd src/libafs; /bin/rm -rf afs afsint config rx)
        -(cd src/libuafs; /bin/rm -rf afs afsint config rx)
+       -(cd tests ${COMPILE_CLEAN})
        -/bin/rm -rf ${TOP_INCDIR} ${TOP_LIBDIR} ${TOP_JLIBDIR}
        -/bin/rm -rf libafs_tree ${SYS_NAME}
 
@@ -948,10 +949,33 @@ distclean: clean
        tests/volser/Makefile \
        src/helper-splint.sh
        if test -d doc/man-pages ; then \
-           rm -f doc/man-pages/Makefile doc/man-pages/install-man ; \
+           /bin/rm -f doc/man-pages/Makefile doc/man-pages/install-man ; \
+       fi
+       if test -d doc/doxygen ; then \
+           /bin/rm -f doc/doxygen/Doxyfile ; \
        fi
 
 pristine: distclean
-       /bin/rm -f src/config/afsconfig.h.in configure configure-libafs aclocal.m4
+       /bin/rm -f src/config/afsconfig.h.in configure configure-libafs \
+       aclocal.m4 \
+       libtool \
+       build-tools/ltmain.sh \
+       src/cf/libtool.m4 \
+       src/cf/ltoptions.m4 \
+       src/cf/ltsugar.m4 \
+       src/cf/ltversion.m4 \
+       src/cf/lt~obsolete.m4
+       if test -d doc/xml ; then \
+           /bin/rm -f doc/xml/mobi-fixup.xsl ; \
+       fi
+       if test -d doc/man-pages ; then \
+           /bin/rm -rf doc/man-pages/man1 \
+               doc/man-pages/man3 \
+               doc/man-pages/man5 \
+               doc/man-pages/man8 ; \
+       fi
+       for i in doc/man-pages/pod*/*.pod.in; do \
+           /bin/rm -f $${i%.in}; \
+       done
 
 maintainer-clean: pristine
index 0d260d199857de7dd47e9b3856a6618f13acc0ea..16abc10b7a2a4534a4441cafb30e5bcb0a18fd64 100644 (file)
@@ -66,9 +66,8 @@ dest: libafshcrypto.la libafshcrypto.a
 
 clean:
        $(LT_CLEAN)
-       $(RM) -f ${OBJECTS} rand-fortuna_lwp.o \
-               libafshcrypto.a libafshcrypto_lwp.a libafshcrypto.exp \
-               test_cipher test_cipher.o
+       $(RM) -f *.o libafshcrypto.a libafshcrypto_lwp.a libafshcrypto.exp \
+               test_cipher
 
 $(LT_objs): $(HEADERS)
 
index c3c57f15f397b42dcb850d954dc49fbf02402e2c..b773205c01992580d6749970849e67737b1a9670 100644 (file)
@@ -269,5 +269,5 @@ clean:
        $(LT_CLEAN)
        $(RM) -f *.o libsys.a xfsinode iinc idec icreate iopen istat core \
        rmtsysc rmtsyss *.o rmtsys.ss.c rmtsys.cs.c rmtsys.xdr.c rmtsys.h \
-       rmtsysd AFS_component_version_number.c \
+       rmtsysd AFS_component_version_number.c syscall.c \
        afs.exp afsl.exp libafssetpag.* Krmtsys.cs.c Krmtsys.h Krmtsys.xdr.c
index 046d81a8c2d2145a7a790ae060179b618390db9d..88812b2ac479cdf8ae86b77407210e65e2b08e6c 100644 (file)
@@ -194,7 +194,7 @@ dest: volserver
 
 clean:
        $(LT_CLEAN)
-       $(RM) -f *.o volserver core AFS_component_version_number.c \
+       $(RM) -f *.o vos volserver core AFS_component_version_number.c \
                vl_errors.c vlserver.h
 
 include ../config/Makefile.version
index a6e56bd447505cce9e0ada043fd95ef9cbe2334b..667df2afe367ab96e01acd093f2fa1b4eda7c709 100644 (file)
@@ -7,7 +7,6 @@
 
 srcdir=@srcdir@
 include @TOP_OBJDIR@/src/config/Makefile.config
-include @TOP_OBJDIR@/src/config/Makefile.libtool
 include @TOP_OBJDIR@/src/config/Makefile.pthread
 top_builddir=@top_builddir@
 
@@ -30,16 +29,16 @@ all test:  fulltest owntest idtest getinitparams
 install:
 dest:
 
-fulltest: fulltest.lo
-       $(LT_LDRULE_static) $@.lo $(LT_deps) $(LT_libs)
-owntest: owntest.lo
-       $(LT_LDRULE_static) $@.lo $(LT_deps) $(LT_libs)
-idtest: idtest.lo
-       $(LT_LDRULE_static) $@.lo $(LT_deps) $(LT_libs)
-getinitparams: getinitparams.lo
-       $(LT_LDRULE_static) $@.lo $(LT_deps) $(LT_libs)
+fulltest: fulltest.o
+       $(LT_LDRULE_static) $@.o $(LT_deps) $(LT_libs)
+owntest: owntest.o
+       $(LT_LDRULE_static) $@.o $(LT_deps) $(LT_libs)
+idtest: idtest.o
+       $(LT_LDRULE_static) $@.o $(LT_deps) $(LT_libs)
+getinitparams: getinitparams.o
+       $(LT_LDRULE_static) $@.o $(LT_deps) $(LT_libs)
 
 clean:
        $(LT_CLEAN)
-       $(RM) -f fulltest owntest idtest getinitparams
+       $(RM) -f *.o fulltest owntest idtest getinitparams
 
index 5e7057cd2e57253124ff909212c303a22f1ffb0b..7625eb43a49f89b14ad0f967e387acfaa13cfd0e 100644 (file)
@@ -33,4 +33,5 @@ uuid-t: uuid-t.o
        $(LT_LDRULE_static) uuid-t.o ../tap/libtap.a $(LIBS) $(XLIBS)
 
 clean distclean:
+       $(LT_CLEAN)
        $(RM) -f $(tests) *.o core
index f629d1bf7fd39bcabe90cf9075bb4b322fd0bc60..f5b4cf924434b55276aeeab99dd8563b3b21057b 100644 (file)
@@ -19,5 +19,5 @@ event-t: event-t.o $(LIBS)
 install:
 
 clean distclean:
-       $(LT_clean)
+       $(LT_CLEAN)
        $(RM) -f $(tests) *.o core