Skip to contentSkip to conversation

URGENT: libnetfilter_queue-1.0.4 fails to build

PATCH New Duncan Roe 2 participants 9 messages Jun 6, 2020 – Jun 8, 2020

Subsystems (2)
lore
Share & tools
lore

Duncan Roe

author
#0 lore raw

cover URGENT: libnetfilter_queue-1.0.4 fails to build

'make' says: No rule to build ../fixmanpages.sh: stop Maybe you can push out a re-release before anyone else notices? Do what you must,

Cheers ... Duncan.

Duncan Roe (1):
build: dist: Add fixmanpages.sh to distribution tree

 Makefile.am | 1 +
 1 file changed, 1 insertion(+)

v2: Move fixmanpages.sh into the doxygen directory
Compare Slackware built package to v1: no significant diffs. (diffs are: "Generated on" lines in html files differ
binary gzipped man pages differ, but zdiff compares equal)

Signature · 1 line
2.14.5
author
#1 lore raw

PATCH v2 1/1 build: dist: Add fixmanpages.sh to distribution tree

Also move fixmanpages.sh into the doxygen directory

Tested by running Slackware package builder on libnetfilter_queue-1.0.4.tar.bz2 created by 'make dist' after applying the patch. Works now, failed before.

---
 Makefile.am                              | 1 +
 doxygen/Makefile.am                      | 4 ++--
 fixmanpages.sh => doxygen/fixmanpages.sh | 2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)
 rename fixmanpages.sh => doxygen/fixmanpages.sh (99%)
Makefile.am +1 -0
index a5b347b..7d3bf23 100644
@@ -10,3 +10,4 @@ pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = libnetfilter_queue.pc
 
 EXTRA_DIST += Make_global.am
+EXTRA_DIST += doxygen/fixmanpages.sh
doxygen/Makefile.am +2 -2
index ef468e0..a4db804 100644
@@ -8,8 +8,8 @@ doc_srcs = $(top_srcdir)/src/libnetfilter_queue.c  \
            $(top_srcdir)/src/extra/udp.c           \
            $(top_srcdir)/src/extra/pktbuff.c
 
-doxyfile.stamp: $(doc_srcs) $(top_srcdir)/fixmanpages.sh
-	rm -rf html man && cd .. && doxygen doxygen.cfg && ./fixmanpages.sh
+doxyfile.stamp: $(doc_srcs) fixmanpages.sh
+	rm -rf html man && (cd .. && doxygen doxygen.cfg) && ./fixmanpages.sh
 	touch doxyfile.stamp
 
 CLEANFILES = doxyfile.stamp
doxygen/fixmanpages.sh renamed from fixmanpages.sh +1 -1
similarity index 99%
rename from fixmanpages.sh
rename to doxygen/fixmanpages.sh
index dd8b3a4..38e97ba 100755
@@ -3,7 +3,7 @@
 function main
 {
   set -e
-  cd doxygen/man/man3
+  cd man/man3
   rm -f _*
   setgroup LibrarySetup nfq_open
     add2group nfq_close nfq_bind_pf nfq_unbind_pf
Signature · 1 line
2.14.5
maintainer Applied
#2 lore raw

Re: [PATCH libnetfilter_queue v2 1/1] build: dist: Add fixmanpages.sh to distribution tree

Quoted 4 lines · Duncan Roe

Also move fixmanpages.sh into the doxygen directory

Tested by running Slackware package builder on libnetfilter_queue-1.0.4.tar.bz2 created by 'make dist' after applying the patch. Works now, failed before.

Applied, thanks.

#3 lore raw

Re: [PATCH libnetfilter_queue v2 1/1] build: dist: Add fixmanpages.sh to distribution tree

Quoted 7 lines · Pablo Neira Ayuso
Quoted 4 lines · Duncan Roe

Also move fixmanpages.sh into the doxygen directory

Tested by running Slackware package builder on libnetfilter_queue-1.0.4.tar.bz2 created by 'make dist' after applying the patch. Works now, failed before.

Applied, thanks.

Side note: I had to move EXTRA_DIST to doxygen/Makefile.am so make distcheck works.

#4 lore raw

Re: [PATCH libnetfilter_queue v2 1/1] build: dist: Add fixmanpages.sh to distribution tree

Quoted 11 lines · Pablo Neira Ayuso
Quoted 7 lines · Pablo Neira Ayuso
Quoted 4 lines · Duncan Roe

Also move fixmanpages.sh into the doxygen directory

Tested by running Slackware package builder on libnetfilter_queue-1.0.4.tar.bz2 created by 'make dist' after applying the patch. Works now, failed before.

Applied, thanks.

Side note: I had to move EXTRA_DIST to doxygen/Makefile.am so make distcheck works.

Sorry, I quickly looked to fix it but it still does not work with make distcheck here for some reason.

author
#5 lore raw

cover Force 'make distcheck' to pass

Hi Pablo,

Patch 1 below is the same as I sent previously.

Patch 2 forces 'make distcheck' to pass. The generated tar.bz2 is good. The patch is not pretty, but the best I could do.

Cheers ... Duncan.

Duncan Roe (2):
build: dist: Add fixmanpages.sh to distribution tree
build: dist: Force 'make distcheck' to pass

 Makefile.am                              |  1 +
 doxygen/Makefile.am                      | 18 +++++++++++++++---
 fixmanpages.sh => doxygen/fixmanpages.sh |  2 +-
 3 files changed, 17 insertions(+), 4 deletions(-)
 rename fixmanpages.sh => doxygen/fixmanpages.sh (99%)
Signature · 1 line
2.14.5
author
#6 lore raw

PATCH 1/2 build: dist: Add fixmanpages.sh to distribution tree

Also move fixmanpages.sh into the doxygen directory

Tested by running Slackware package builder on libnetfilter_queue-1.0.4.tar.bz2 created by 'make dist' after applying the patch. Works now, failed before.

---
 Makefile.am                              | 1 +
 doxygen/Makefile.am                      | 4 ++--
 fixmanpages.sh => doxygen/fixmanpages.sh | 2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)
 rename fixmanpages.sh => doxygen/fixmanpages.sh (99%)
Makefile.am +1 -0
index a5b347b..7d3bf23 100644
@@ -10,3 +10,4 @@ pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = libnetfilter_queue.pc
 
 EXTRA_DIST += Make_global.am
+EXTRA_DIST += doxygen/fixmanpages.sh
doxygen/Makefile.am +2 -2
index ef468e0..a4db804 100644
@@ -8,8 +8,8 @@ doc_srcs = $(top_srcdir)/src/libnetfilter_queue.c  \
            $(top_srcdir)/src/extra/udp.c           \
            $(top_srcdir)/src/extra/pktbuff.c
 
-doxyfile.stamp: $(doc_srcs) $(top_srcdir)/fixmanpages.sh
-	rm -rf html man && cd .. && doxygen doxygen.cfg && ./fixmanpages.sh
+doxyfile.stamp: $(doc_srcs) fixmanpages.sh
+	rm -rf html man && (cd .. && doxygen doxygen.cfg) && ./fixmanpages.sh
 	touch doxyfile.stamp
 
 CLEANFILES = doxyfile.stamp
doxygen/fixmanpages.sh renamed from fixmanpages.sh +1 -1
similarity index 99%
rename from fixmanpages.sh
rename to doxygen/fixmanpages.sh
index dd8b3a4..38e97ba 100755
@@ -3,7 +3,7 @@
 function main
 {
   set -e
-  cd doxygen/man/man3
+  cd man/man3
   rm -f _*
   setgroup LibrarySetup nfq_open
     add2group nfq_close nfq_bind_pf nfq_unbind_pf
Signature · 1 line
2.14.5
author
#7 lore raw

PATCH 2/2 build: dist: Force 'make distcheck' to pass

In reply to Duncan Roe

'make distcheck' was failing because fixmanpages.sh was not present in the test build directory.
While this can be addressed, it has no chance of working because make has already deleted the generated man pages.
To solve this problem, this patch makes the Makefile become "aware" that is being run by 'make distcheck' and keep going if so.
The Makefile also has to take special action so 'make distcleancheck' passes.

This does mean that 'make distcheck' doesn't test fixmanpages.sh.

---
 doxygen/Makefile.am | 16 ++++++++++++++--
 1 file changed, 14 insertions(+), 2 deletions(-)
doxygen/Makefile.am +14 -2
index a4db804..9c06983 100644
@@ -9,7 +9,12 @@ doc_srcs = $(top_srcdir)/src/libnetfilter_queue.c  \
            $(top_srcdir)/src/extra/pktbuff.c
 
 doxyfile.stamp: $(doc_srcs) fixmanpages.sh
-	rm -rf html man && (cd .. && doxygen doxygen.cfg) && ./fixmanpages.sh
+# Hack so 'make distcheck' passes:
+# just keep going if fixmanpages.sh is missing
+# as an extra check, ensure penultimate 2 components of cwd are "_build/sub"
+	rm -rf html man && (cd .. && doxygen doxygen.cfg) &&\
+	[ ! -x ./fixmanpages.sh -a "$$(pwd|rev|cut -d/ -f2-3|rev)" = _build/sub ] ||\
+	./fixmanpages.sh
 	touch doxyfile.stamp
 
 CLEANFILES = doxyfile.stamp
@@ -19,5 +24,12 @@ clean-local:
 	rm -rf $(top_srcdir)/doxygen/man $(top_srcdir)/doxygen/html
 install-data-local:
 	mkdir -p $(DESTDIR)$(mandir)/man3
-	cp --no-dereference --preserve=links,mode,timestamps man/man3/*.3 $(DESTDIR)$(mandir)/man3/
+# Need another hack so 'make distcleancheck' passes :(
+# No need to check directory tree again
+	if [ ! -x ./fixmanpages.sh ];\
+	then\
+		rm -rf html;\
+	else\
+		cp --no-dereference --preserve=links,mode,timestamps man/man3/*.3 $(DESTDIR)$(mandir)/man3/;\
+	fi
 endif
Signature · 1 line
2.14.5
#8 lore raw

Re: [PATCH libnetfilter_queue 0/2] Force 'make distcheck' to pass

In reply to Duncan Roe
Quoted 6 lines · Duncan Roe

Hi Pablo,

Patch 1 below is the same as I sent previously.

Patch 2 forces 'make distcheck' to pass. The generated tar.bz2 is good. The patch is not pretty, but the best I could do.

Thanks. I also spent a bit of time and I failed to make this work without the hacks.

I decided to:

* Disable doxygen by default, as it was in the <= 1.0.3 releases. Users can still enable this via --with-doxygen.

* Add this manpage fixup script to EXTRA_DIST.

Patch are already upstream.