[Git][haskell-team/DHG_packages][experimental] hadrian: Do not use cabal-install
Ilias Tsitsimpis (@iliastsi)
gitlab at salsa.debian.org
Sat Sep 27 22:14:10 BST 2025
Ilias Tsitsimpis pushed to branch experimental at Debian Haskell Group / DHG_packages
Commits:
5141bf78 by Ilias Tsitsimpis at 2025-09-28T00:10:21+03:00
hadrian: Do not use cabal-install
cabal tries to access the network even when we use the --offline flag.
Fallback to manually building ghc-platform, ghc-toolchain and hadrian.
- - - - -
4 changed files:
- p/haskell-hadrian/debian/changelog
- p/haskell-hadrian/debian/control
- + p/haskell-hadrian/debian/hadrian.install
- p/haskell-hadrian/debian/rules
Changes:
=====================================
p/haskell-hadrian/debian/changelog
=====================================
@@ -1,3 +1,9 @@
+haskell-hadrian (9.10.3-1~exp2) experimental; urgency=medium
+
+ * Do not use cabal-install
+
+ -- Ilias Tsitsimpis <iliastsi at debian.org> Sat, 27 Sep 2025 23:59:04 +0300
+
haskell-hadrian (9.10.3-1~exp1) experimental; urgency=medium
* New upstream version.
=====================================
p/haskell-hadrian/debian/control
=====================================
@@ -8,7 +8,6 @@ Rules-Requires-Root: no
Build-Depends:
debhelper-compat (= 13),
ghc (>= 9.6),
- cabal-install,
libghc-extra-dev (>= 1.4.7),
libghc-shake-dev (>= 0.18.3),
libghc-shake-dev (<< 0.20),
=====================================
p/haskell-hadrian/debian/hadrian.install
=====================================
@@ -0,0 +1 @@
+tmp/bin/hadrian usr/bin
=====================================
p/haskell-hadrian/debian/rules
=====================================
@@ -1,33 +1,35 @@
#!/usr/bin/make -f
-# Set home directory needed by cabal-install
-HOME=$(CURDIR)/debian/home
-PROJECT_DIR=$(CURDIR)/hadrian
+SETUP := $(CURDIR)/setup
+PKG_DB := $(CURDIR)/debian/packages.conf/
+INSTDIR := $(CURDIR)/tmp/
+
+define build
+ $(SETUP) configure --package-db=$(PKG_DB) --prefix=$(INSTDIR) -O ${1} \
+ && $(SETUP) build --builddir=dist \
+ && $(SETUP) install --builddir=dist
+endef
+
%:
dh $@
-.PHONY: override_dh_auto_build
-override_dh_auto_configure:
- cd $(PROJECT_DIR) && \
- cabal configure --offline --disable-tests -f-selftest -f-threaded -O
-
.PHONY: override_dh_auto_build
override_dh_auto_build:
- cd $(PROJECT_DIR) && \
- cabal build --offline
-
-.PHONY: override_dh_auto_install
-override_dh_auto_install:
- mkdir -p debian/hadrian/usr/bin
- cd $(PROJECT_DIR) && \
- cp "$$(cabal list-bin exe:hadrian)" ../debian/hadrian/usr/bin/
- dh_auto_install
+ ghc -O -o $(SETUP) hadrian/Setup.hs
+ ghc-pkg init $(PKG_DB)
+ cd libraries/ghc-platform/ && $(call build)
+ cd utils/ghc-toolchain/ && $(call build)
+ cd hadrian && $(call build, -f-selftest -f-threaded)
.PHONY: override_dh_auto_clean
override_dh_auto_clean:
dh_auto_clean
- rm -rf debian/home/ dist-newstyle/
+ rm -f $(SETUP) hadrian/Setup.o hadrian/Setup.hi
+ rm -rf libraries/ghc-platform/dist
+ rm -rf utils/ghc-toolchain/dist
+ rm -rf hadrian/dist
+ rm -rf $(PKG_DB) $(INSTDIR)
.PHONY: override_dh_strip
override_dh_strip:
View it on GitLab: https://salsa.debian.org/haskell-team/DHG_packages/-/commit/5141bf78ba342e188f364360f2062165f55eaa91
--
View it on GitLab: https://salsa.debian.org/haskell-team/DHG_packages/-/commit/5141bf78ba342e188f364360f2062165f55eaa91
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-haskell-commits/attachments/20250927/b787d502/attachment-0001.htm>
More information about the Pkg-haskell-commits
mailing list