--- /tmp/gtk-doc.make	2004-07-24 21:10:21.000000000 -0700
+++ gtk-doc.make	2004-07-24 21:19:53.000000000 -0700
@@ -3,6 +3,8 @@
 ####################################
 # Everything below here is generic #
 ####################################
+htmldir = $(shell if test "x$(TARGET_DIR)" = x ; then echo @htmldir@/$(DOC_MODULE) ; else echo $(TARGET_DIR) ; fi)
+html_DATA = $(wildcard html/*)
 
 if GTK_DOC_USE_LIBTOOL
 GTKDOC_CC = $(LIBTOOL) --mode=compile $(CC) $(INCLUDES) $(AM_CFLAGS) $(CFLAGS)
@@ -19,15 +21,13 @@
 #
 GPATH = $(srcdir)
 
-TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)
-
-EXTRA_DIST = 				\
+EXTRA_DIST = $(wildcard			\
 	$(content_files)		\
 	$(HTML_IMAGES)			\
 	$(DOC_MAIN_SGML_FILE)		\
 	$(DOC_MODULE).types		\
 	$(DOC_MODULE)-sections.txt	\
-	$(DOC_MODULE)-overrides.txt
+	$(DOC_MODULE)-overrides.txt     )
 
 DOC_STAMPS=scan-build.stamp tmpl-build.stamp sgml-build.stamp html-build.stamp \
 	   $(srcdir)/tmpl.stamp $(srcdir)/sgml.stamp $(srcdir)/html.stamp
@@ -112,23 +112,6 @@
 maintainer-clean-local: clean
 	cd $(srcdir) && rm -rf xml html $(DOC_MODULE)-decl-list.txt $(DOC_MODULE)-decl.txt
 
-install-data-local:
-	installfiles=`echo $(srcdir)/html/*`; \
-	if test "$$installfiles" = '$(srcdir)/html/*'; \
-	then echo '-- Nothing to install' ; \
-	else \
-	  $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR); \
-	  for i in $$installfiles; do \
-	    echo '-- Installing '$$i ; \
-	    $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR); \
-	  done; \
-	  echo '-- Installing $(srcdir)/html/index.sgml' ; \
-	  $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR) || :; \
-	fi
-
-uninstall-local:
-	rm -f $(DESTDIR)$(TARGET_DIR)/*
-
 #
 # Require gtk-doc when making dist
 #
