Closed mato closed 2 years ago
It seems like aspcud is broken in the current Debian 10 Buster stable release. The Opam version in Debian is 2.0.3, but the package relies on aspcud instead of using the internal solver. Anil and Louis had commented on the Debian bug tracker about the situation. Unfortunately the fix for Opam hasn't landed in stable yet.
The only viable solution currently is to use mccs as solver.
I've managed to build the Debian package on an almost clean VM, based on the Vagrant "debian/contrib-buster64" box. It only had build-essential already installed on top of the minimal base system. Only "main" was enabled in the sources.list.
After that I've installed the build dependencies:
apt install opam devscript libgmp-dev mccs
Then I've added --solver=mccs to all opam commands in the debian/rules file (I'm sure there is a nicer way. I don't have a clue about Makefiles :D). The diff is here.
And last but not least, I've followed your instructions and had an installable Debian package afterwards.
Hi @verbosemode,
It seems like aspcud is broken in the current Debian 10 Buster stable release. Anil and Louis had commented on the Debian bug tracker about the situation. Unfortunately the fix for opam hasn't landed in stable yet.
Indeed, that was the bug I was thinking of. Thanks for the pointer.
The only viable solution currently is to use mccs as solver.
I have some ideas about possible fixes that might be acceptable for Debian stable. Will discuss them in the above issue, and/or open a new Debian bug as #908203 is fixed in unstable and archived.
I've managed to build the Debian package on an almost clean VM, based on the Vagrant "debian/contrib-buster64" box. It only had build-essential already installed on top of the minimal base system. Only "main" was enabled in the sources.list.
Great, thanks for testing that!
After that I've installed the build dependencies:
apt install opam devscript libgmp-dev mccs
Then I've prefixed all opam commands with --solver=mccs in the debian/rules file (I'm sure there is a nicer way. I don't have a clue about Makefiles :D). The diff is here.
I've pushed a slightly different solution in c470d34, exporting OPAMEXTERNALSOLVER
in debian/rules
to force the same behaviour.
And last but not least, I've followed your instructions and had an installable Debian package afterwards.
That's good news, and confirms that this approach for building Debian packages works. Thanks.
So, in 1e8a60c I've re-worked things yet again to always use an own OPAMROOT
, plus some more tweaks to make the build work with pbuilder
and whalebuilder
. The package build process is now a bit different:
git clone -b debian git://github.com/mato/jackline
b. cd jackline && debian/rules x-source
This will generate debian/changelog
to match the Git version and produce a jackline_<VERSION>.dsc
and jackline_<VERSION>.tar.xz
in the parent directory.debuild
: dpkg-source -x jackline_<VERSION>.dsc && cd jackline_<VERSION> && debuild -us -uc
b. With pbuilder
: sudo pbuilder build --use-network yes jackline_<VERSION>.dsc
c. With whalebuilder
: whalebuilder build --network bridge <BASE_IMAGE> jackline_<VERSION>.dsc
debuild -us -uc
for an "in tree" build sould also just work after running debian/rules x-source
; this is useful for developing the package itself, but does not guarantee that the build is 100% clean.As of e2f48dd this now builds Debian packages on Travis CI. However, please don't merge anything until I give the green light -- still deciding on the best way to e.g. name/version the package in order to facilitate uploading to an APT repository.
thanks, a different approach (using dpkg-deb and orb) has been merged as 459cbe7 -- and binary packages will show up soon on https://builds.robur.coop
This is a counter-proposal to #206, with the following overall goals:
dh
/debhelper
, no need forgit-buildpackage
.orb
for Reproducible Builds in the future.Build-Depends
fromdebian/control
installed.Status
DH_OPTIONS
anddebian/source/options
to allow us to create the OPAM switch underdebian/
.Bulding the Debian package
See https://github.com/hannesm/jackline/pull/208#issuecomment-587081505.
Notable differences from #206
3.0 (native)
.debian/copyright
, etc. to pass alllintian
checks exceptbinary-without-manpage
.TODO
Thebuild
target indebian/rules
should (safely) depend onx-prepare
, i.e.debian/rules x-prepare
should not be required as a manual step.jackline
gets real releases. Something like0~YYYYMMDD+g1234567
. At the same time, we could update the timestamp indebian/changelog
.This should be possible by generatingEdit: Done, but conflicts with (1) above since without adebian/changelog
from a template.debian/changelog
present a bunch of the Debian tooling gets confused.opam
in Debian due to solver problems; I've seen this happen before, need to track down the upstream issue(s). Edit: See further comments, workaround in place.pbuilder
or similar./cc @hannesm @cfcs