blob: 27560d838312a242541248f0dee632108e214cd5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
# Maintainer: Rudy Matela <rudy@matela.com.br>
#
# Contributor: Rudy Matela <rudy@matela.com.br>
#
# This package can coexist with the latest version of GHC.
# If you would like to compile GHC yourself (AUR: ghc8.10),
# you can use this to bootstrap compilation.
pkgname=ghc8.10-bin
pkgver=8.10.7
pkgrel=1
pkgdesc='Legacy binary GHC 8.10 installed on /usr/bin/ghc-8.10 (Mar/2020 - Feb/2021).'
arch=('x86_64')
url='http://www.haskell.org/ghc/'
license=('custom')
depends=('gcc' 'gmp' 'libffi' 'perl')
makedepends=('ghc' 'perl' 'libxslt' 'docbook-xsl' 'ncurses5-compat-libs')
checkdepends=('python2')
install='ghc.install'
options=('staticlibs')
provides=('ghc8.10')
conflicts=('ghc8.10')
source=("https://www.haskell.org/ghc/dist/${pkgver}/ghc-${pkgver}-x86_64-deb10-linux.tar.xz")
noextract=("ghc-${pkgver}-${CARCH}-deb10-linux.tar.xz")
sha256sums=('a13719bca87a0d3ac0c7d4157a4e60887009a7f1a8dbe95c4759ec413e086d30')
prepare() {
# for some reason, bsdtar cannot unpack this file:
tar -xf "ghc-${pkgver}-${CARCH}-deb10-linux.tar.xz"
# see https://wiki.archlinux.org/index.php/PKGBUILD#noextract
}
build() {
cd ghc-${pkgver}
sed -i 's,"$bindir/ghc","$bindir/ghc-8.10",' utils/runghc/runghc.wrapper
./configure \
--prefix=/usr \
--docdir=/usr/share/doc/ghc-8.10
}
package() {
cd ghc-${pkgver}
make DESTDIR=${pkgdir} install
mv ${pkgdir}/usr/bin/ghc ${pkgdir}/usr/bin/ghc-8.10
mv ${pkgdir}/usr/bin/ghci ${pkgdir}/usr/bin/ghci-8.10
mv ${pkgdir}/usr/bin/ghc-pkg ${pkgdir}/usr/bin/ghc-pkg-8.10
mv ${pkgdir}/usr/bin/haddock ${pkgdir}/usr/bin/haddock-ghc-8.10
mv ${pkgdir}/usr/bin/hp2ps ${pkgdir}/usr/bin/hp2ps-ghc-8.10
mv ${pkgdir}/usr/bin/hpc ${pkgdir}/usr/bin/hpc-ghc-8.10
mv ${pkgdir}/usr/bin/hsc2hs ${pkgdir}/usr/bin/hsc2hs-ghc-8.10
mv ${pkgdir}/usr/bin/runghc ${pkgdir}/usr/bin/runghc-8.10
rm ${pkgdir}/usr/bin/runhaskell # use runghc-8.10 instead
mv ${pkgdir}/usr/share/man/man1/ghc.1 ${pkgdir}/usr/share/man/man1/ghc-8.10
install -d ${pkgdir}/usr/share/licenses/ghc-8.10
install -m644 LICENSE ${pkgdir}/usr/share/licenses/ghc-8.10
}
|