# cabal/cfg - "Build" settings for package #--------------------------------------------------------------------- [technotes] 1. This package builds and installs "cabal" 3.4.0.0 as an executable named "cabal". #--------------------------------------------------------------------- 2. If everything is working correctly, it should be possible to build this package offline. In other words, the build procedure shouldn't try to download any files. In fact, it's probably best that DNS be turned off while this package is being built. This will prevent most attempts by the "build" proce- dure to go online. To turn DNS off: sudo killany dnsmasq To turn DNS back on: sudo service dnsmasq restart #--------------------------------------------------------------------- 3. OldCoder says: It wasn't easy to make this work. The initial bootstrap involved man- ual downloads of source tarballs for "cabal" 2.4.0.0 dependencies and patching the sources because they weren't compatible with the release of "ghc" that we were using (8.6.5). Subsequently, we built a temporary copy of "cabal" 2.4.0.0 and used it to download source tarballs for "cabal" 3.4.0.0 dependencies. Next step, build a temporary copy of "cabal" 3.4.0.0. After that, we used "cabal" 3.4.0.0 to download source tarballs for applications to be built later (such as "pandoc"). Finally, we modified the ".cabal" tree that the two "cabals" had cre- ated so as to make it the equivalent of an offline source-only reposi- tory. Sure, Haskell and "cabal" win the award for offline build support. Not. #--------------------------------------------------------------------- 4. This package should never be updated without review of compatibili- ty issues related to the exact releases of "ghc", the bootstrap copy of "cabal", and the final copy of "cabal" involved. Short version: Updates mean horrible fates. #--------------------------------------------------------------------- [buildtimes] 00.13 hours (or 008.10 minutes) - 2023 dedi Xeon E3-1200 v3 4x2 32GB RAM 00.16 hours (or 009.33 minutes) - 2021 L.A. dedi box: 6x2 CPU 32GB RAM 00.20 hours (or 011.77 minutes) - 2021 Utah dedi box: 4x2 CPU 32GB RAM #--------------------------------------------------------------------- [settings] configure = none defer = glibc64 license = tbd nosyslinks = yes proddir = none purge = no shareddir = yes strip = no tmpsize = 1M unpack = none setpaths = \ gcc ghc0865 libffi libgmp libicu ncurses numactl zlib #--------------------------------------------------------------------- [depends] cabal2400:strict ghc0865:strict libffi libgmp libicu ncurses numactl zlib #--------------------------------------------------------------------- [build] export LD=ld . srcpkgpaths fontconfig freetype2 lapack libgmp libpng xorg PP=$PRODTREE/ghc0865 BINDIR=$PP/bin DOCDIR=$PP/doc LOCDIR=$PP/local LOCBIN=$LOCDIR/bin MODHOME=$PP/home MODBIN=$MODHOME/.cabal/bin mkdir -p $BINDIR $DOCDIR $LOCBIN $MODBIN #--------------------------------------------------------------------- export HOME=$MODHOME mkdir -p $MODHOME cd $MODHOME tar zxf $PKGDIR_SPECIAL/src-cabal3400.tgz #--------------------------------------------------------------------- rm -fr /tmp/cabal rm -fr /usr/local/bin/cabal rm -fr $BINDIR/cabal rm -fr $LOCBIN/cabal rm -fr $MODHOME/.cabal/bin/cabal #--------------------------------------------------------------------- cabal2400 \ --bindir=$HOME/.cabal/bin \ --symlink-bindir=/tmp \ install cabal-install-3.4.0.0 strip $MODBIN/cabal upx --lzma $MODBIN/cabal || true ln -nsf $MODBIN/cabal $BINDIR/ #--------------------------------------------------------------------- # Original URLs. These URLs were valid at one point, but may have died # since then. If you download newer versions of tarballs [etc.], don't # delete the original versions, as you may not be able to replace # them. [urls] url_debian = tbd url_home = tbd url_lfs = tbd url_tarball = n/a #--------------------------------------------------------------------- [history] 180318 Added package. Started with 2.0.0.1. 181012 Updated "cabal" from 2.0.0.1 to 2.4.0.0 181013 Added "pandoc" and numerous library modules 181014 Moved "/usr/local/" Haskell tree into "ghc*/local/" 210205 Restructured distro Haskell packages 210620 More work. 211027 Ugh. Updates to this package aren't recommended.