Source: opensp
Version: 1.5.2-10
Severity: wishlist
Tags: patch

As the subject says: the attached patch adds a bootstrap build profile to 
opensp to resolve the dependency cycle that opensp and openjade both have 
Build-Depends on each other.
-- 
Daniel Schepler
diff -urN opensp-1.5.2.old/debian/rules opensp-1.5.2/debian/rules
--- opensp-1.5.2.old/debian/rules	2014-02-09 10:25:14.000000000 -0800
+++ opensp-1.5.2/debian/rules	2014-02-09 10:28:21.334209884 -0800
@@ -51,6 +51,12 @@
 export CFLAGS
 export CXXFLAGS
 
+ifeq (,$(findstring stage1,$(DEB_BUILD_PROFILES)))
+enable_doc_build := --enable-full-doc-build
+else
+enable_doc_build := --disable-doc-build
+endif
+
 # flags to get automake to use the above
 inst_flags	:= INSTALL='$(install_)'
 inst_flags	+= INSTALL_PROGRAM='$(install_program)'
@@ -110,7 +116,7 @@
 	   --enable-http --enable-shared --enable-static \
 	   --enable-default-catalog=$(default-catalogs) \
 	   --enable-default-search-path=$(default-sgml-path) \
-	   --disable-dtddecl --enable-full-doc-build
+	   --disable-dtddecl $(enable_doc_build)
 	touch $@
 
 configure: config-stamp
@@ -168,8 +174,18 @@
 	( sed -e 's/unicode.sd/unicode.decl/' catalog > catalog.tmp && \
 	mv -f catalog.tmp catalog ) && \
 	chmod +x gensyntax.pl
+ifeq (,$(findstring stage1,$(DEB_BUILD_PROFILES)))
 	# Ugly fix for man page generation error
 	sed 's~\.HP.*\[\\fIsysid\\fR\.\.\.\]~[\\fIsysid\\fR...]~' $(DESTDIR)/usr/share/man/man1/onsgmls.1 > $(DESTDIR)/usr/share/man/man1/onsgmls.1.tmp && mv $(DESTDIR)/usr/share/man/man1/onsgmls.1.tmp $(DESTDIR)/usr/share/man/man1/onsgmls.1
+else
+	mkdir -p $(DESTDIR)/usr/share/man/man1 $(DESTDIR)/usr/share/doc/OpenSP
+	for f in onsgmls.1 osgmlnorm.1 ospam.1 ospcat.1 ospent.1 osx.1; do \
+		touch $(DESTDIR)/usr/share/man/man1/$$f; \
+	done
+	for ext in html pdf ps; do \
+		touch $(DESTDIR)/usr/share/doc/OpenSP/releasenotes.$$ext; \
+	done
+endif
 	touch $@
 
 install: build install-stamp $(install-common)

Reply via email to