summaryrefslogtreecommitdiffstats
path: root/main/putty/APKBUILD
blob: 2e7dbfbfb289deea3d571967b48adbe465c52bc4 (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
# Maintainer: Jeff Bilyk <jbilyk@alpinelinux.org>
pkgname=putty
pkgver=0.63
pkgrel=0
pkgdesc="SSH and telnet client"
url="http://www.chiark.greenend.org.uk/~sgtatham/putty/"
arch="all"
license="custom"
depends=
depends_dev=
makedepends="$depends_dev"
install=""
subpackages="$pkgname-doc"
source="http://the.earth.li/~sgtatham/putty/latest/putty-$pkgver.tar.gz"

_builddir="$srcdir"/putty-$pkgver/unix
prepare() {
	local i
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
		esac
	done
}

build() {
	cd "$_builddir"

	# We only make all-cli, so no need to try to install these`
	sed -i 's#$(INSTALL_PROGRAM) -m 755 pterm $(DESTDIR)$(bindir)/pterm##' Makefile.in
	sed -i 's#$(INSTALL_PROGRAM) -m 755 putty $(DESTDIR)$(bindir)/putty##' Makefile.in
	sed -i 's#$(INSTALL_PROGRAM) -m 755 puttytel $(DESTDIR)$(bindir)/puttytel##' Makefile.in

	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	install -dm755 $pkgdir/usr/bin
	install -dm755 $pkgdir/usr/share/man/man1
	make DESTDIR="$pkgdir" install || return 1
	install -D -m644 ../LICENCE $pkgdir/usr/share/licenses/$pkgname/LICENSE
}

md5sums="567207b590a149656454d6e6ea7af124  putty-0.63.tar.gz"
sha256sums="81e8eaaf31be7d9a46b4f3fb80d1d9540776f142cd89d0a11f2f8082dc68f8b5  putty-0.63.tar.gz"
sha512sums="a1f1d460f96e45ff08acd6631fef92f35c9da1d202bd0d54b299e323dbee71ca6bd8f242722d0fa765c5747d890ec2c8e41c35070bc532b98121165e487fb8a4  putty-0.63.tar.gz"