Index: tests/gtk-doc.make
===================================================================
--- tests/gtk-doc.make	(revision 614)
+++ tests/gtk-doc.make	(working copy)
@@ -145,7 +145,7 @@
 	  done; \
 	  echo '-- Installing $(srcdir)/html/index.sgml' ; \
 	  $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR) || :; \
-	  which gtkdoc-rebase >/dev/null && \
+	  ! which gtkdoc-rebase >/dev/null 2>&1 || \
 	    gtkdoc-rebase --relative --dest-dir=$(DESTDIR) --html-dir=$(DESTDIR)$(TARGET_DIR) ; \
 	fi
 
@@ -167,6 +167,7 @@
 	-cp $(srcdir)/$(DOC_MODULE).types $(distdir)/
 	-cp $(srcdir)/$(DOC_MODULE)-sections.txt $(distdir)/
 	cd $(distdir) && rm -f $(DISTCLEANFILES)
-	-gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
+	! which gtkdoc-rebase >/dev/null 2>&1 || \
+	  gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
 
 .PHONY : dist-hook-local docs
Index: tests/gtk-doc.notmpl.make
===================================================================
--- tests/gtk-doc.notmpl.make	(revision 614)
+++ tests/gtk-doc.notmpl.make	(working copy)
@@ -130,7 +130,7 @@
 	  done; \
 	  echo '-- Installing $(srcdir)/html/index.sgml' ; \
 	  $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR) || :; \
-	  which gtkdoc-rebase >/dev/null && \
+	  ! which gtkdoc-rebase >/dev/null 2>&1 || \
 	    gtkdoc-rebase --relative --dest-dir=$(DESTDIR) --html-dir=$(DESTDIR)$(TARGET_DIR) ; \
 	fi
 
@@ -148,6 +148,7 @@
 	-cp $(srcdir)/$(DOC_MODULE).types $(distdir)/
 	-cp $(srcdir)/$(DOC_MODULE)-sections.txt $(distdir)/
 	cd $(distdir) && rm -f $(DISTCLEANFILES)
-	-gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
+	! which gtkdoc-rebase >/dev/null 2>&1 || \
+	  gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
 
 .PHONY : dist-hook-local docs
Index: gtk-doc.make
===================================================================
--- gtk-doc.make	(revision 614)
+++ gtk-doc.make	(working copy)
@@ -157,7 +157,7 @@
 	    mv -f $${installdir}/$(DOC_MODULE).devhelp \
 	      $${installdir}/$(DOC_MODULE)-$(DOC_MODULE_VERSION).devhelp; \
 	  fi; \
-	  which gtkdoc-rebase >/dev/null && \
+	  ! which gtkdoc-rebase >/dev/null 2>&1 || \
 	    gtkdoc-rebase --relative --dest-dir=$(DESTDIR) --html-dir=$${installdir} ; \
 	fi
 
@@ -190,6 +190,7 @@
 	-cp $(srcdir)/$(DOC_MODULE).types $(distdir)/
 	-cp $(srcdir)/$(DOC_MODULE)-sections.txt $(distdir)/
 	cd $(distdir) && rm -f $(DISTCLEANFILES)
-	-gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
+	! which gtkdoc-rebase >/dev/null 2>&1 || \
+	  gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
 
 .PHONY : dist-hook-local docs
Index: gtk-doc.notmpl.make
===================================================================
--- gtk-doc.notmpl.make	(revision 614)
+++ gtk-doc.notmpl.make	(working copy)
@@ -142,7 +142,7 @@
 	    mv -f $${installdir}/$(DOC_MODULE).devhelp \
 	      $${installdir}/$(DOC_MODULE)-$(DOC_MODULE_VERSION).devhelp; \
 	  fi; \
-	  which gtkdoc-rebase >/dev/null && \
+	  ! which gtkdoc-rebase >/dev/null 2>&1 || \
 	    gtkdoc-rebase --relative --dest-dir=$(DESTDIR) --html-dir=$${installdir} ; \
 	fi
 
@@ -171,6 +171,7 @@
 	-cp $(srcdir)/$(DOC_MODULE).types $(distdir)/
 	-cp $(srcdir)/$(DOC_MODULE)-sections.txt $(distdir)/
 	cd $(distdir) && rm -f $(DISTCLEANFILES)
-	-gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
+	! which gtkdoc-rebase >/dev/null 2>&1 || \
+	  gtkdoc-rebase --online --relative --html-dir=$(distdir)/html
 
 .PHONY : dist-hook-local docs
