Hi, I wonder if the following solution would be accepted (see the two patches attached) : let the source package ship the two binaries (bootlx and net_aboot.nh). One can build aboot-base on amd64 then. The two binaries are generated from source if the source package is built on alpha. (The inspiration came from Helge Deller's palo package on hppa)
I tested so far that dpkg-buildpackage -B builds aboot (on alpha) and aboot-cross (on amd64), and that dpkg-builpackage -A builds aboot-base (on both). A bootable CD including a just compiled bootlx indeed booted an XP1000 alpha workstation. I hope it will help ! Regards, JH Chatenet
Description: Build-depends on opensp instead of sp (deprecated, removed) This is the concatenation of two patches from the thread of bug #832491 (see the discussion therein). Should close #832491 Forwarded: no Origin: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=832491#5 Origin: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=832491#23 Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=832491 Author: Neil Roeth <n...@debian.org> Author: jhcha54008 <jhcha5...@free.fr> diff -Naur aboot-1.0~pre20040408/debian/control aboot-1.0~pre20040408/debian/control --- aboot-1.0~pre20040408/debian/control +++ aboot-1.0~pre20040408/debian/control @@ -1,5 +1,5 @@ Source: aboot -Build-Depends: debhelper (>= 9), sp, sgmlspl, docbook-utils +Build-Depends: debhelper (>= 9), opensp, sgmlspl, docbook-utils Build-Depends-Indep: sgmltools-lite Section: admin Priority: standard diff -Naur aboot-1.0~pre20040408/doc/man/Makefile aboot-1.0~pre20040408/doc/man/Makefile --- aboot-1.0~pre20040408/doc/man/Makefile +++ aboot-1.0~pre20040408/doc/man/Makefile @@ -32,20 +32,20 @@ rm -f aboot.8 aboot.conf.5 abootconf.8 isomarkboot.1 sdisklabel.8 netabootwrap.1 manpage.log manpage.links manpage.refs aboot.8: aboot.sgml - nsgmls aboot.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls aboot.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl aboot.conf.5: aboot.conf.sgml - nsgmls aboot.conf.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls aboot.conf.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl abootconf.8: abootconf.sgml - nsgmls abootconf.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls abootconf.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl isomarkboot.1: isomarkboot.sgml - nsgmls isomarkboot.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls isomarkboot.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl netabootwrap.1: netabootwrap.sgml - nsgmls netabootwrap.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls netabootwrap.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl sdisklabel.8: sdisklabel.sgml - nsgmls sdisklabel.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls sdisklabel.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl diff -Naur aboot-1.0~pre20040408/doc/man/README aboot-1.0~pre20040408/doc/man/README --- aboot-1.0~pre20040408/doc/man/README 2003-05-30 16:57:34.000000000 +0000 +++ aboot-1.0~pre20040408/doc/man/README @@ -26,7 +26,7 @@ please contact me. Technical note: -To create the nroff version from the SGML sources, nsgml was used like - nsgmls abootconf.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl +To create the nroff version from the SGML sources, onsgmls was used like + onsgmls abootconf.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl Hannover, Germany, January 17th 2003 diff -Naur aboot-1.0~pre20040408/doc/man/de/Makefile aboot-1.0~pre20040408/doc/man/de/Makefile --- aboot-1.0~pre20040408/doc/man/de/Makefile +++ aboot-1.0~pre20040408/doc/man/de/Makefile @@ -1,35 +1,35 @@ all: srmbootraw.de.8 aboot.de.8 aboot.conf.de.5 abootconf.de.8 isomarkboot.de.1 sdisklabel.de.8 srmbootfat.de.1 e2writeboot.de.8 swriteboot.de.8 netabootwrap.de.1 aboot.de.8: aboot.sgml - nsgmls aboot.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls aboot.sgml | sgmlspl docbook2man-de-spec.pl mv aboot.8 aboot.de.8 aboot.conf.de.5: aboot.conf.sgml - nsgmls aboot.conf.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls aboot.conf.sgml | sgmlspl docbook2man-de-spec.pl mv aboot.conf.5 aboot.conf.de.5 abootconf.de.8: abootconf.sgml - nsgmls abootconf.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls abootconf.sgml | sgmlspl docbook2man-de-spec.pl mv abootconf.8 abootconf.de.8 netabootwrap.de.1: netabootwrap.sgml - nsgmls netabootwrap.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls netabootwrap.sgml | sgmlspl docbook2man-de-spec.pl mv netabootwrap.1 netabootwrap.de.1 isomarkboot.de.1: isomarkboot.sgml - nsgmls isomarkboot.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls isomarkboot.sgml | sgmlspl docbook2man-de-spec.pl mv isomarkboot.1 isomarkboot.de.1 sdisklabel.de.8: sdisklabel.sgml - nsgmls sdisklabel.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls sdisklabel.sgml | sgmlspl docbook2man-de-spec.pl mv sdisklabel.8 sdisklabel.de.8 srmbootfat.de.1: srmbootfat.sgml - nsgmls srmbootfat.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls srmbootfat.sgml | sgmlspl docbook2man-de-spec.pl mv srmbootfat.1 srmbootfat.de.1 srmbootraw.de.8: srmbootraw.sgml - nsgmls srmbootraw.sgml | sgmlspl docbook2man-de-spec.pl + onsgmls srmbootraw.sgml | sgmlspl docbook2man-de-spec.pl mv srmbootraw.8 srmbootraw.de.8 e2writeboot.de.8: e2writeboot.8 diff -Naur aboot-1.0~pre20040408/doc/man/de/docbook2man-de-spec.pl aboot-1.0~pre20040408/doc/man/de/docbook2man-de-spec.pl --- aboot-1.0~pre20040408/doc/man/de/docbook2man-de-spec.pl +++ aboot-1.0~pre20040408/doc/man/de/docbook2man-de-spec.pl @@ -7,7 +7,7 @@ The SGMLSpm package from CPAN. This contains the sgmlspl script which is used to grok this file. Use it like this: -nsgmls some-docbook-document.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl +onsgmls some-docbook-document.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl =head1 OPTIONS diff -Naur aboot-1.0~pre20040408/srmbootfat/Makefile aboot-1.0~pre20040408/srmbootfat/Makefile --- aboot-1.0~pre20040408/srmbootfat/Makefile +++ aboot-1.0~pre20040408/srmbootfat/Makefile @@ -14,10 +14,10 @@ $(CC) $(CFLAGS) $(LDFLAGS) -o srmbootraw srmbootraw.c srmbootfat.1: srmbootfat.sgml - nsgmls srmbootfat.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls srmbootfat.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl srmbootraw.8: srmbootraw.sgml - nsgmls srmbootraw.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl + onsgmls srmbootraw.sgml | sgmlspl sgmlspl-specs/docbook2man-spec.pl clean: rm -f srmbootfat srmbootraw srmbootfat.1 srmbootraw.8 manpage.links manpage.log manpage.refs
Description: Make dpkg-buildpackage -A build aboot-base on amd64 Include two needed binaries in the source package, so that the aboot-base binary package can be built on arch !alpha. The two binaries are generated from source if the source package is built on alpha. Should close #805988, #821332 Forwarded: not-needed Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=805988 Author: jhcha54008 <jhcha5...@free.fr> diff -Naur aboot-1.0~pre20040408/Makefile aboot-1.0~pre20040408/Makefile --- aboot-1.0~pre20040408/Makefile 2017-01-13 23:30:22.000000000 +0000 +++ aboot-1.0~pre20040408/Makefile 2017-01-13 22:04:17.536887277 +0000 @@ -156,3 +156,15 @@ echo "#define KERNEL_SIZE `ls -l vmlinux.nh | awk '{print $$5}'` > $@ dep: + +encode_base64: bootlx net_aboot.nh + base64 bootlx > bootlx.base64 + base64 net_aboot.nh > net_aboot.nh.base64 + +decode_base64: bootlx.base64 net_aboot.nh.base64 + base64 -d bootlx.base64 > bootlx + base64 -d net_aboot.nh.base64 > net_aboot.nh + +realclean: distclean + rm -f bootlx.base64 net_aboot.nh.base64 + diff -Naur aboot-1.0~pre20040408/debian/README.Debian aboot-1.0~pre20040408/debian/README.Debian --- aboot-1.0~pre20040408/debian/README.Debian 2017-01-13 23:30:22.000000000 +0000 +++ aboot-1.0~pre20040408/debian/README.Debian 2017-01-14 00:00:59.583608552 +0000 @@ -35,3 +35,19 @@ - install linux-libc-dev from unstable, and build the package against that instead of the linux-kernel-headers included in etch. +Notes for cross-building aboot-base +----------------------------------- +bootlx (required to boot from a CD-ROM or a disk) and net_aboot.nh (required +for a TFTP boot) are shipped in the aboot-base binary package. These two files +are compiled on alpha (or with a cross-compiler) as they contain alpha +code. + +A binary copy of them is now included in the source package to permit the build +of aboot-base on architectures other than alpha without the need of a cross compiler. +They are generated from source if the source package is built on alpha. It happens +in the clean target of debhelper just before creating the source package. + +This means that the source package must be built on an alpha (or with a +cross-compiler). + +(The inspiration came from the palo package of Helge Deller on hppa). diff -Naur aboot-1.0~pre20040408/debian/rules aboot-1.0~pre20040408/debian/rules --- aboot-1.0~pre20040408/debian/rules 2017-01-13 23:30:22.000000000 +0000 +++ aboot-1.0~pre20040408/debian/rules 2017-01-13 23:29:26.358220554 +0000 @@ -15,7 +15,7 @@ ifeq (alpha,$(DEB_HOST_GNU_CPU)) export DH_OPTIONS=-Naboot-cross else - export DH_OPTIONS=-paboot-cross +# export DH_OPTIONS=-paboot-cross endif ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS))) @@ -28,6 +28,8 @@ dh $@ override_dh_auto_build: +# bootlx and net_aboot.nh are restored in case we build aboot-base on !alpha + $(MAKE) decode_base64 ifeq (alpha,$(DEB_HOST_GNU_CPU)) $(MAKE) $(TESTING) all netabootwrap CC=$(CC) $(shell dpkg-buildflags --export=configure) $(MAKE) -C doc/man all @@ -42,9 +44,22 @@ $(MAKE) -C srmbootfat srmbootfat srmbootfat.1 CC=$(CC) $(shell dpkg-buildflags --export=configure) $(MAKE) -C doc/man isomarkboot.1 $(MAKE) -C doc/man/de isomarkboot.de.1 srmbootfat.de.1 + $(MAKE) net_pad + $(MAKE) -C doc/faq endif override_dh_auto_clean: +ifeq (alpha,$(DEB_HOST_GNU_CPU)) +# We remove everything and rebuild bootlx and net_aboot.nh from source on alpha + @echo "Rebuilding bootlx and net_aboot.nh from source on an alpha" + $(MAKE) realclean + $(MAKE) $(TESTING) bootlx net_aboot.nh CC=$(CC) $(shell dpkg-buildflags --export=configure) +# source package is Format: 1.0 : the diff must be represented as text + $(MAKE) encode_base64 +else + @echo "Using bootlx and net_aboot.nh shipped in the source (we are not on an alpha)" +endif +# We intentionnally keep bootlx.base64 and net_aboot.nh.base64 so they are available for cross-build of aboot-base $(MAKE) distclean $(MAKE) -C doc/man clean $(MAKE) -C doc/man/de clean @@ -65,9 +80,11 @@ rm -rf debian/aboot/usr/share/man/man1 endif else +ifneq (,$(filter aboot-cross, $(shell dh_listpackages))) install -m 755 tools/isomarkboot debian/aboot-cross/usr/bin install -m 755 srmbootfat/srmbootfat debian/aboot-cross/usr/bin endif +endif ifneq (,$(filter aboot-base, $(shell dh_listpackages))) install -m 644 bootlx debian/aboot-base/boot/bootlx install -m 644 net_aboot.nh debian/aboot-base/boot/