grim/guifications3

Parents 0b5513f16fc8
Children ec87bdb43d05
cleaned up some of the built sources rules to be a bit more easier to maintain, as well as a bit more error proof
--- a/gflib/gflib/Makefile.am Sat Oct 10 18:24:48 2009 -0500
+++ b/gflib/gflib/Makefile.am Sat Oct 10 18:28:05 2009 -0500
@@ -117,13 +117,6 @@
MARSHALSOURCES = gf_marshallers.c gf_marshallers.h
ENUMSOURCES = gf_enum.c gf_enum.h
-CLEANFILES = \
- $(ENUMSOURCES) \
- $(MARSHALSOURCES) \
- gf_lib.h
-
-DISTCLEANFILES =
-
enum_headers = \
gf_connection.h \
gf_log.h \
@@ -140,18 +133,25 @@
$(GLIB_MKENUMS) --template $@.template $(enum_headers) > $@.tmp && mv $@.tmp $@
gf_lib.h: gflib-genheader $(gfinc_HEADERS)
- @echo "Generating gf_lib.h ... "
- ./gflib-genheader -s GF_LIB_H -d gflib $(gfinc_HEADERS) > gf_lib.h
+ @echo "Generating $@ ... "
+ ./gflib-genheader -s GF_LIB_H -d gflib $(gfinc_HEADERS) > $@.tmp && mv $@.tmp $@
gf_marshallers.h: gf_marshallers.list
- @echo "Generating gf_marshallers.h ..."
- $(GLIB_GENMARSHAL) --prefix=gf_marshal gf_marshallers.list --header > gf_marshallers.h
+ @echo "Generating $@ ..."
+ $(GLIB_GENMARSHAL) --prefix=gf_marshal gf_marshallers.list --header > $@.tmp && mv $@.tmp $@
gf_marshallers.c: gf_marshallers.list gf_marshallers.h
- @echo "Generating gf_marshallers.c ..."
- $(GLIB_GENMARSHAL) --prefix=gf_marshal gf_marshallers.list --body > gf_marshallers.c
+ @echo "Generating $@ ..."
+ $(GLIB_GENMARSHAL) --prefix=gf_marshal gf_marshallers.list --body > $@.tmp && mv $@.tmp $@
-BUILT_SOURCES = gf_enum.c gf_enum.h gf_lib.h gf_marshallers.c gf_marshallers.h
+BUILT_SOURCES = \
+ $(ENUMSOURCES) \
+ $(MARSHALSOURCES) \
+ gf_lib.h
+
+CLEANFILES = $(BUILT_SOURCES)
+
+DISTCLEANFILES =
install-exec-hook:
@if [ `id -u` == 0 ] ; then echo -n "Running ldconfig... "; ldconfig; echo "done"; else echo "Not running ldconfig since you are not root."; fi