Tuesday, August 31, 2021

Re: [PATCH] devel/cabal-install: reduce brittleness through minor ghc upgrades

Hi Greg,

On Tue, Aug 17, 2021 at 11:34:01AM -0700, Greg Steuck wrote:
> While strict version checks for built-in ghc packages in cabal-install
> build procedure provide a modicum of extra safety, in practice for the
> ports tree they impose extra version tracking burden. The ports tree
> is already self-consistent. Cross-checks of version numbers cause
> false positives and add more toil.
>
> OK?

Yes, let's try it. (and sorry for the delay)

Ciao,
Kili

> ---
> devel/cabal-install/Makefile | 7 +-
> devel/cabal-install/files/openbsd-8.10.3.json | 1 -
> devel/cabal-install/files/openbsd.json | 260 ++++++++++++++++++
> 3 files changed, 262 insertions(+), 6 deletions(-)
> delete mode 100644 devel/cabal-install/files/openbsd-8.10.3.json
> create mode 100644 devel/cabal-install/files/openbsd.json
>
> diff --git a/devel/cabal-install/Makefile b/devel/cabal-install/Makefile
> index a75c7957aa4..9446b82f7c2 100644
> --- a/devel/cabal-install/Makefile
> +++ b/devel/cabal-install/Makefile
> @@ -4,7 +4,7 @@ COMMENT = command-line interface for Cabal and Hackage
>
> DISTNAME = cabal-install-3.4.0.0
> CATEGORIES = devel
> -REVISION = 1
> +REVISION = 2
>
> GH_ACCOUNT = haskell
> GH_TAGNAME = ${DISTNAME}
> @@ -75,11 +75,8 @@ post-extract:
> @ln -s ${FULLDISTDIR}/${_package}-${_version}_${_revision}.cabal ${WRKBUILD}/_build/tarballs/${_package}.cabal
> .endfor
>
> -# Uses the same fixed versions of packages as in _MANIFEST. The
> -# distributed package currently doesn't have a 8.10.3 variant. The
> -# json file is generated by following cabal bootstrap instructions.
> do-build:
> - @cd ${WRKBUILD} && ${MODPY_BIN} bootstrap/bootstrap.py -d ${FILESDIR}/openbsd-8.10.3.json
> + @cd ${WRKBUILD} && ${MODPY_BIN} bootstrap/bootstrap.py -d ${FILESDIR}/openbsd.json
>
> do-install:
> @install -m755 ${WRKBUILD}/_build/bin/cabal ${PREFIX}/bin
> diff --git a/devel/cabal-install/files/openbsd-8.10.3.json b/devel/cabal-install/files/openbsd-8.10.3.json
> deleted file mode 100644
> index 6949634f9e6..00000000000
> --- a/devel/cabal-install/files/openbsd-8.10.3.json
> +++ /dev/null
> @@ -1 +0,0 @@
> -{"builtin":[{"version":"1.0.1","package":"rts"},{"version":"0.6.1","package":"ghc-prim"},{"version":"1.0.3.0","package":"integer-gmp"},{"version":"4.14.3.0","package":"base"},{"version":"0.5.4.0","package":"array"},{"version":"1.4.4.0","package":"deepseq"},{"version":"0.10.12.0","package":"bytestring"},{"version":"0.6.5.1","package":"containers"},{"version":"0.8.8.0","package":"binary"},{"version":"1.4.2.1","package":"filepath"},{"version":"1.9.3","package":"time"},{"version":"2.7.2.2","package":"unix"},{"version":"1.3.6.0","package":"directory"},{"version":"0.5.6.2","package":"transformers"},{"version":"2.2.2","package":"mtl"},{"version":"8.10.6","package":"ghc-boot-th"},{"version":"1.1.3.6","package":"pretty"},{"version":"2.16.0.0","package":"template-haskell"},{"version":"1.2.4.1","package":"text"},{"version":"3.1.14.0","package":"parsec"},{"version":"1.6.13.2","package":"process"},{"version":"2.5.0.1","package":"stm"}],"dependencies":[{"flags":["-bundled-binary-generic"],"src_sha256":null,"version":"3.4.0.0","package":"Cabal","source":"local","revision":null,"cabal_sha256":null},{"flags":["-examples","+integer-gmp","+sse2","-sse41"],"src_sha256":"822e5413fbccca6ae884d3aba4066422c8b5d58d23d18b9ecb5c03273bb19ab4","version":"1.3.0.0","package":"hashable","source":"hackage","revision":2,"cabal_sha256":"d60cad00223d46172020c136e68acef0481a47d0302b2e74b1805b4f3a446a9b"},{"flags":["-bench"],"src_sha256":"4b4ab1ac82c45144d82c6daf6cb6ba45eab9957dad44787fa5e869e23d73bbff","version":"2.2.2","package":"async","source":"hackage","revision":1,"cabal_sha256":"a178c166856da7ff22fe4500337b54812e94fd2059409452187d72e057ede9cd"},{"flags":["-optimised-mixer"],"src_sha256":"46009f4b000c9e6613377767b8718bf38476469f2a8e2162d98cc246882d5a35","version":"0.1.0.3","package":"splitmix","source":"hackage","revision":0,"cabal_sha256":"fc3aae74c467f4b608050bef53aec17904a618731df9407e655d8f3bf8c32d5c"},{"flags":[],"src_sha256":"e4519cf7c058bfd5bdbe4acc782284acc9e25e74487208619ca83cbcd63fb9de","version":"1.2.0","package":"random","source":"hackage","revision":3,"cabal_sha256":"1e8140229d21489228aa79b820c23259f3c3a1b86e13e6f9c2ad0c48d86d1912"},{"flags":["-old-bytestring","-old-time"],"src_sha256":"b384449f62b2b0aa3e6d2cb1004b8060b01f21ec93e7b63e7af6d8fad8a9f1de","version":"0.5.1.1","package":"tar","source":"hackage","revision":2,"cabal_sha256":"7a715414c4d494c9048cfb6d7634e07e7732ca154cb8938dc85f6ea192192e8c"},{"flags":["-devel"],"src_sha256":"fcaa954445cb575ff04d088e719452e356324b6acb98c5aefd2541a069439d4a","version":"3.1.2.1","package":"network","source":"hackage","revision":1,"cabal_sha256":"188d6daea8cd91bc3553efd5a90a1e7c6d0425fa66a53baa74db5b6d9fd75c8b"},{"flags":[],"src_sha256":"a01c1389f15d2cc2e847914737f706133bb11f0c5f8ee89711a36a25b7afa723","version":"2.6.3.0","package":"network-uri","source":"hackage","revision":0,"cabal_sha256":"d2d9ff3a80d9b2d1ff317a354bc0c56cc109c69a4c2449e5fc712d3ddce83ede"},{"flags":["-conduit10","-mtl1","+network-uri","-warn-as-error","-warp-tests"],"src_sha256":"0d6b368e43001c046660e0e209bf9795dc990cb45016447fcf92e822c22e1594","version":"4000.3.15","package":"HTTP","source":"hackage","revision":2,"cabal_sha256":"2ba9cfc40afbb231326c4ff685ae678c4454e449fd41672e5ca75fd757fe6ae6"},{"flags":[],"src_sha256":"525689679d5cc80fa532c1d5cfeace0f62bbb54134fad514f1ba00d0e7fe69ba","version":"0.1.1.7","package":"base16-bytestring","source":"hackage","revision":3,"cabal_sha256":"0021256a9628971c08da95cb8f4d0d72192f3bb8a7b30b55c080562d17c43dd3"},{"flags":[],"src_sha256":"af09b17d072eb1391d91e30b4186dd1797330647ef79268ecd7fcce8f5afc638","version":"1.2.0.1","package":"base64-bytestring","source":"hackage","revision":0,"cabal_sha256":"f4f998235fc0825ab636ca9241b827de5805b336625eb1c7822f1798a238b6ac"},{"flags":["-exe"],"src_sha256":"52756435dbea248e344fbcbcc5df5307f60dfacf337dfd11ae30f1c7a4da05dd","version":"0.11.101.0","package":"cryptohash-sha256","source":"hackage","revision":4,"cabal_sha256":"b963d6308db096362d73d9c603b331cf188aa69310195f479dfedf6045d7e602"},{"flags":["-example"],"src_sha256":"704f07310f8272d170f8ab7fb2a2c13f15d8501ef8310801e36964c8eff485ef","version":"0.1.3","package":"echo","source":"hackage","revision":1,"cabal_sha256":"5490be9cfbea95e14a7a68b7d055ae8d295822e0b146d2ac8285b3e5a3e3282f"},{"flags":[],"src_sha256":"3e8885ee2f56ad4da940f043ae8f981ee2fe336b5e8e4ba3f7436cff4f526c4a","version":"0.2.2.1","package":"edit-distance","source":"hackage","revision":1,"cabal_sha256":"4d33a49cd383d50af090f1b888642d10116e43809f9da6023d9fc6f67d2656ee"},{"flags":["+no-donna","+test-doctests","+test-hlint","+test-properties"],"src_sha256":"d8a5958ebfa9309790efade64275dc5c441b568645c45ceed1b0c6ff36d6156d","version":"0.0.5.0","package":"ed25519","source":"hackage","revision":3,"cabal_sha256":"fb98b08de467d51f788f8bd9391f0e9ab9bd4d8dfc264296b895ffea0d822dfa"},{"flags":["+ofd-locking"],"src_sha256":"8a79d113dc0ccef16c24d83379cc457485943027e777529c46362fecc06607d2","version":"0.1.1.2","package":"lukko","source":"hackage","revision":0,"cabal_sha256":"c9d3fa30fb6ab2ba16e037586ca79be6e57ec5f00381b6ee5f293400dbdf5515"},{"flags":["-bundled-c-zlib","-non-blocking-ffi","-pkg-config"],"src_sha256":"04b5890dd69e992f8cd09570d81e9d5ecab19db8e82cbe47ba8e02c31c0631ba","version":"0.6.2.2","package":"zlib","source":"hackage","revision":0,"cabal_sha256":"eae95cb0cc80ff259de236b812072c4a74c6de398cb277ff0fba1148edc0253d"},{"flags":["+base48","+lukko","-mtl21","-old-directory","+use-network-uri"],"src_sha256":"9162b473af5a21c1ff32a50b972b9acf51f4c901604a22cf08a2dccac2f82f17","version":"0.6.0.1","package":"hackage-security","source":"hackage","revision":4,"cabal_sha256":"25e49fa21996bb3db92e2a978fc01586e6f4053fe86a5069d7312b7c2beea419"},{"flags":[],"src_sha256":"c41f82f5fc1157c961a4cbdc0cd5561e5aa44f339ce6e706d978d97e0ca6b914","version":"0.94.0.0","package":"regex-base","source":"hackage","revision":1,"cabal_sha256":"44aa95ca762294ffbb28cf0af9c567d93b5d2c56e4f38ce5385a257d899f968e"},{"flags":["-_regex-posix-clib"],"src_sha256":"251300f1a6bb2e91abb8bf513a21981f8fab79c98a65acea2bb6d6a524414521","version":"0.96.0.0","package":"regex-posix","source":"hackage","revision":1,"cabal_sha256":"690d1366e9ea6df71ded3daf49ca3d53c63eda3f95937962299b2391824dc3b3"},{"flags":[],"src_sha256":"81a2bafad484db123cf8d17a02d98bb388a127fd0f822fa022589468a0e64671","version":"0.1.2.0","package":"resolv","source":"hackage","revision":0,"cabal_sha256":"0a9a6dd29706258ae60a5c22aecc140a40743b8f08fc324fd9984e7dfbf3a80d"},{"flags":["-debug-conflict-sets","-debug-expensive-assertions","-debug-tracetree","+lukko","+native-dns"],"src_sha256":null,"version":"3.4.0.0","package":"cabal-install","source":"local","revision":null,"cabal_sha256":null}]}
> diff --git a/devel/cabal-install/files/openbsd.json b/devel/cabal-install/files/openbsd.json
> new file mode 100644
> index 00000000000..9f410e7fc6f
> --- /dev/null
> +++ b/devel/cabal-install/files/openbsd.json
> @@ -0,0 +1,260 @@
> +{
> + "_comment": [
> + "This file uses the same fixed versions of packages as _MANIFEST in Makefile. ",
> + "The contents was first generated by following cabal bootstrap instructions. ",
> + "Then builtin section got emptied out to reduce brittleness (while ",
> + "losing some safety) through GHC upgrades."
> + ],
> + "builtin": [],
> + "dependencies": [
> + {
> + "flags": [
> + "-bundled-binary-generic"
> + ],
> + "src_sha256": null,
> + "version": "3.4.0.0",
> + "package": "Cabal",
> + "source": "local",
> + "revision": null,
> + "cabal_sha256": null
> + },
> + {
> + "flags": [
> + "-examples",
> + "+integer-gmp",
> + "+sse2",
> + "-sse41"
> + ],
> + "src_sha256": "822e5413fbccca6ae884d3aba4066422c8b5d58d23d18b9ecb5c03273bb19ab4",
> + "version": "1.3.0.0",
> + "package": "hashable",
> + "source": "hackage",
> + "revision": 2,
> + "cabal_sha256": "d60cad00223d46172020c136e68acef0481a47d0302b2e74b1805b4f3a446a9b"
> + },
> + {
> + "flags": [
> + "-bench"
> + ],
> + "src_sha256": "4b4ab1ac82c45144d82c6daf6cb6ba45eab9957dad44787fa5e869e23d73bbff",
> + "version": "2.2.2",
> + "package": "async",
> + "source": "hackage",
> + "revision": 1,
> + "cabal_sha256": "a178c166856da7ff22fe4500337b54812e94fd2059409452187d72e057ede9cd"
> + },
> + {
> + "flags": [
> + "-optimised-mixer"
> + ],
> + "src_sha256": "46009f4b000c9e6613377767b8718bf38476469f2a8e2162d98cc246882d5a35",
> + "version": "0.1.0.3",
> + "package": "splitmix",
> + "source": "hackage",
> + "revision": 0,
> + "cabal_sha256": "fc3aae74c467f4b608050bef53aec17904a618731df9407e655d8f3bf8c32d5c"
> + },
> + {
> + "flags": [],
> + "src_sha256": "e4519cf7c058bfd5bdbe4acc782284acc9e25e74487208619ca83cbcd63fb9de",
> + "version": "1.2.0",
> + "package": "random",
> + "source": "hackage",
> + "revision": 3,
> + "cabal_sha256": "1e8140229d21489228aa79b820c23259f3c3a1b86e13e6f9c2ad0c48d86d1912"
> + },
> + {
> + "flags": [
> + "-old-bytestring",
> + "-old-time"
> + ],
> + "src_sha256": "b384449f62b2b0aa3e6d2cb1004b8060b01f21ec93e7b63e7af6d8fad8a9f1de",
> + "version": "0.5.1.1",
> + "package": "tar",
> + "source": "hackage",
> + "revision": 2,
> + "cabal_sha256": "7a715414c4d494c9048cfb6d7634e07e7732ca154cb8938dc85f6ea192192e8c"
> + },
> + {
> + "flags": [
> + "-devel"
> + ],
> + "src_sha256": "fcaa954445cb575ff04d088e719452e356324b6acb98c5aefd2541a069439d4a",
> + "version": "3.1.2.1",
> + "package": "network",
> + "source": "hackage",
> + "revision": 1,
> + "cabal_sha256": "188d6daea8cd91bc3553efd5a90a1e7c6d0425fa66a53baa74db5b6d9fd75c8b"
> + },
> + {
> + "flags": [],
> + "src_sha256": "a01c1389f15d2cc2e847914737f706133bb11f0c5f8ee89711a36a25b7afa723",
> + "version": "2.6.3.0",
> + "package": "network-uri",
> + "source": "hackage",
> + "revision": 0,
> + "cabal_sha256": "d2d9ff3a80d9b2d1ff317a354bc0c56cc109c69a4c2449e5fc712d3ddce83ede"
> + },
> + {
> + "flags": [
> + "-conduit10",
> + "-mtl1",
> + "+network-uri",
> + "-warn-as-error",
> + "-warp-tests"
> + ],
> + "src_sha256": "0d6b368e43001c046660e0e209bf9795dc990cb45016447fcf92e822c22e1594",
> + "version": "4000.3.15",
> + "package": "HTTP",
> + "source": "hackage",
> + "revision": 2,
> + "cabal_sha256": "2ba9cfc40afbb231326c4ff685ae678c4454e449fd41672e5ca75fd757fe6ae6"
> + },
> + {
> + "flags": [],
> + "src_sha256": "525689679d5cc80fa532c1d5cfeace0f62bbb54134fad514f1ba00d0e7fe69ba",
> + "version": "0.1.1.7",
> + "package": "base16-bytestring",
> + "source": "hackage",
> + "revision": 3,
> + "cabal_sha256": "0021256a9628971c08da95cb8f4d0d72192f3bb8a7b30b55c080562d17c43dd3"
> + },
> + {
> + "flags": [],
> + "src_sha256": "af09b17d072eb1391d91e30b4186dd1797330647ef79268ecd7fcce8f5afc638",
> + "version": "1.2.0.1",
> + "package": "base64-bytestring",
> + "source": "hackage",
> + "revision": 0,
> + "cabal_sha256": "f4f998235fc0825ab636ca9241b827de5805b336625eb1c7822f1798a238b6ac"
> + },
> + {
> + "flags": [
> + "-exe"
> + ],
> + "src_sha256": "52756435dbea248e344fbcbcc5df5307f60dfacf337dfd11ae30f1c7a4da05dd",
> + "version": "0.11.101.0",
> + "package": "cryptohash-sha256",
> + "source": "hackage",
> + "revision": 4,
> + "cabal_sha256": "b963d6308db096362d73d9c603b331cf188aa69310195f479dfedf6045d7e602"
> + },
> + {
> + "flags": [
> + "-example"
> + ],
> + "src_sha256": "704f07310f8272d170f8ab7fb2a2c13f15d8501ef8310801e36964c8eff485ef",
> + "version": "0.1.3",
> + "package": "echo",
> + "source": "hackage",
> + "revision": 1,
> + "cabal_sha256": "5490be9cfbea95e14a7a68b7d055ae8d295822e0b146d2ac8285b3e5a3e3282f"
> + },
> + {
> + "flags": [],
> + "src_sha256": "3e8885ee2f56ad4da940f043ae8f981ee2fe336b5e8e4ba3f7436cff4f526c4a",
> + "version": "0.2.2.1",
> + "package": "edit-distance",
> + "source": "hackage",
> + "revision": 1,
> + "cabal_sha256": "4d33a49cd383d50af090f1b888642d10116e43809f9da6023d9fc6f67d2656ee"
> + },
> + {
> + "flags": [
> + "+no-donna",
> + "+test-doctests",
> + "+test-hlint",
> + "+test-properties"
> + ],
> + "src_sha256": "d8a5958ebfa9309790efade64275dc5c441b568645c45ceed1b0c6ff36d6156d",
> + "version": "0.0.5.0",
> + "package": "ed25519",
> + "source": "hackage",
> + "revision": 3,
> + "cabal_sha256": "fb98b08de467d51f788f8bd9391f0e9ab9bd4d8dfc264296b895ffea0d822dfa"
> + },
> + {
> + "flags": [
> + "+ofd-locking"
> + ],
> + "src_sha256": "8a79d113dc0ccef16c24d83379cc457485943027e777529c46362fecc06607d2",
> + "version": "0.1.1.2",
> + "package": "lukko",
> + "source": "hackage",
> + "revision": 0,
> + "cabal_sha256": "c9d3fa30fb6ab2ba16e037586ca79be6e57ec5f00381b6ee5f293400dbdf5515"
> + },
> + {
> + "flags": [
> + "-bundled-c-zlib",
> + "-non-blocking-ffi",
> + "-pkg-config"
> + ],
> + "src_sha256": "04b5890dd69e992f8cd09570d81e9d5ecab19db8e82cbe47ba8e02c31c0631ba",
> + "version": "0.6.2.2",
> + "package": "zlib",
> + "source": "hackage",
> + "revision": 0,
> + "cabal_sha256": "eae95cb0cc80ff259de236b812072c4a74c6de398cb277ff0fba1148edc0253d"
> + },
> + {
> + "flags": [
> + "+base48",
> + "+lukko",
> + "-mtl21",
> + "-old-directory",
> + "+use-network-uri"
> + ],
> + "src_sha256": "9162b473af5a21c1ff32a50b972b9acf51f4c901604a22cf08a2dccac2f82f17",
> + "version": "0.6.0.1",
> + "package": "hackage-security",
> + "source": "hackage",
> + "revision": 4,
> + "cabal_sha256": "25e49fa21996bb3db92e2a978fc01586e6f4053fe86a5069d7312b7c2beea419"
> + },
> + {
> + "flags": [],
> + "src_sha256": "c41f82f5fc1157c961a4cbdc0cd5561e5aa44f339ce6e706d978d97e0ca6b914",
> + "version": "0.94.0.0",
> + "package": "regex-base",
> + "source": "hackage",
> + "revision": 1,
> + "cabal_sha256": "44aa95ca762294ffbb28cf0af9c567d93b5d2c56e4f38ce5385a257d899f968e"
> + },
> + {
> + "flags": [
> + "-_regex-posix-clib"
> + ],
> + "src_sha256": "251300f1a6bb2e91abb8bf513a21981f8fab79c98a65acea2bb6d6a524414521",
> + "version": "0.96.0.0",
> + "package": "regex-posix",
> + "source": "hackage",
> + "revision": 1,
> + "cabal_sha256": "690d1366e9ea6df71ded3daf49ca3d53c63eda3f95937962299b2391824dc3b3"
> + },
> + {
> + "flags": [],
> + "src_sha256": "81a2bafad484db123cf8d17a02d98bb388a127fd0f822fa022589468a0e64671",
> + "version": "0.1.2.0",
> + "package": "resolv",
> + "source": "hackage",
> + "revision": 0,
> + "cabal_sha256": "0a9a6dd29706258ae60a5c22aecc140a40743b8f08fc324fd9984e7dfbf3a80d"
> + },
> + {
> + "flags": [
> + "-debug-conflict-sets",
> + "-debug-expensive-assertions",
> + "-debug-tracetree",
> + "+lukko",
> + "+native-dns"
> + ],
> + "src_sha256": null,
> + "version": "3.4.0.0",
> + "package": "cabal-install",
> + "source": "local",
> + "revision": null,
> + "cabal_sha256": null
> + }
> + ]
> +}
> --
> 2.32.0
>

No comments:

Post a Comment