Your message dated Thu, 15 Feb 2018 13:18:28 -0800
with message-id <[email protected]>
and subject line [src:flex] FTCBFS: runs host arch binaries during build
has caused the Debian Bug report #762180,
regarding [src:flex] FTCBFS: runs host arch binaries during build
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
762180: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=762180
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: src:flex
Version: 2.5.39-8
Tags: patch
User: [email protected]
Usertags: rebootstrap
flex FTCBFS for any architecture, because the manual page generation
fails. help2man fails to execute ../flex, because in general host arch
executables cannot be run on during cross-build.
It is not obvious what the best solution to this problem is. I am
listing those, that I am aware of and attach a patch for one solution.
1. When cross building, run help2man on the system copy of flex. This
requires that flex is build natively before it can be cross built.
The attached patch implements this method. One bit is missing in the
patch: flex needs to gain a new Build-Depends on flex, but only when
cross building. This can be done using build profiles[1], but build
profile enabled packages cannot be uploaded to the archive. The
dependency that flex needs to gain, probably looks like:
Build-Depends: flex <profile.cross>
This still does not enforce that the flex package used to fulfil the
dependency has the same version as the flex package that is being
built, so the manual page can be outdated. An attempt to support
versioned Build-Depends was not met with enthusiasm by the dpkg
maintainer (#751437).
Nevertheless, this method makes flex somewhat cross-buildable today!
2. Add a nodoc build profile to flex that prevents documentation from
being built or installed. This approach cannot produce subtly wrong
packages (documentation for different version), but it also requires
build profiles and requires a larger diff to be carried. Multiple
places, both in the upstream build and the debian packaging, need to
learn that the documentation can go missing.
3. Do not rebuild manual pages during cross-build but take the pre-built
copy from the source tarball. Not building from source sounds like a
bad idea to me.
If you prefer a method other than 1., please tell me so I can write a
new patch.
Helmut
[1] https://wiki.debian.org/BuildProfileSpec
diff -Nru flex-2.5.39/debian/changelog flex-2.5.39/debian/changelog
--- flex-2.5.39/debian/changelog 2014-06-21 06:01:27.000000000 +0200
+++ flex-2.5.39/debian/changelog 2014-09-18 23:24:27.000000000 +0200
@@ -1,3 +1,10 @@
+flex (2.5.39-8.1) UNRELEASED; urgency=low
+
+ * Non-maintainer upload.
+ * Do not run host arch binaries during cross build. (Closes: #-1)
+
+ -- Helmut Grohne <[email protected]> Thu, 18 Sep 2014 23:08:01 +0200
+
flex (2.5.39-8) unstable; urgency=low
* Added a missing build depends on vm-super-minimal, reuired fro
diff -Nru flex-2.5.39/debian/patches/help2man-cross.patch
flex-2.5.39/debian/patches/help2man-cross.patch
--- flex-2.5.39/debian/patches/help2man-cross.patch 1970-01-01
01:00:00.000000000 +0100
+++ flex-2.5.39/debian/patches/help2man-cross.patch 2014-09-18
23:24:49.000000000 +0200
@@ -0,0 +1,32 @@
+From: Helmut Grohne <[email protected]>
+Subject: Run help2man on the system copy of flex when cross building
+Last-Modified: 2014-09-18
+
+Index: flex-2.5.39/configure.ac
+===================================================================
+--- flex-2.5.39.orig/configure.ac 2014-03-26 19:55:03.000000000 +0100
++++ flex-2.5.39/configure.ac 2014-09-18 23:06:59.199483266 +0200
+@@ -50,6 +50,12 @@
+
+ AC_PATH_PROG(BISON, bison,bison)
+ AC_PATH_PROG(HELP2MAN, help2man, help2man)
++if test "$cross_compiling" = yes; then
++FLEXexe='flex$(EXEEXT)'
++else
++FLEXexe='$(top_builddir)/flex$(EXEEXT)'
++fi
++AC_SUBST(FLEXexe)
+
+ # Check for a m4 that supports -P
+
+Index: flex-2.5.39/doc/Makefile.am
+===================================================================
+--- flex-2.5.39.orig/doc/Makefile.am 2014-03-26 13:46:44.000000000 +0100
++++ flex-2.5.39/doc/Makefile.am 2014-09-18 23:07:11.335481934 +0200
+@@ -27,5 +27,5 @@
+ for i in $(dist_man_MANS) ; do \
+ $(help2man) --name='$(PACKAGE_NAME)' \
+ --section=`echo $$i | sed -e 's/.*\.\([^.]*\)$$/\1/'` \
+- ../flex$(EXEEXT) > $$i || rm -f $$i ; \
++ $(FLEXexe) > $$i || rm -f $$i ; \
+ done
diff -Nru flex-2.5.39/debian/patches/series flex-2.5.39/debian/patches/series
--- flex-2.5.39/debian/patches/series 2014-06-21 06:01:27.000000000 +0200
+++ flex-2.5.39/debian/patches/series 2014-09-18 23:06:50.000000000 +0200
@@ -4,3 +4,4 @@
0003-ia64-buffer-fix-Some-more-fixes-for-the-ia64-buffer-.patch
0004-bison-test-fixes-Do-not-use-obsolete-bison-construct.patch
0005-fix-off-by-one-error-generatred-line-numbers-are-off.patch
+help2man-cross.patch
--- End Message ---
--- Begin Message ---
Package: flex
Verson: 2.6.4-2
The last upload fixed the cross compilation issue.
Manoj
--
No evil can happen to a good man. Plato
Manoj Srivastava <[email protected]>
4096R/C5779A1C E37E 5EC5 2A01 DA25 AD20 05B6 CF48 9438 C577 9A1C
smime.p7s
Description: S/MIME cryptographic signature
--- End Message ---