summaryrefslogtreecommitdiffstats
path: root/abs/core/wget/PKGBUILD
blob: c53153533cf8ce7ee202206b60cb993d0318a842 (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
# $Id$
# Maintainer: Eric BĂ©langer <eric@archlinux.org>

pkgname=wget
pkgver=1.16
pkgrel=2
pkgdesc="A network utility to retrieve files from the Web"
arch=('i686' 'x86_64')
url="http://www.gnu.org/software/wget/wget.html"
license=('GPL3')
depends=('openssl' 'libidn' 'libutil-linux')
checkdepends=('perl-http-daemon' 'perl-io-socket-ssl' 'python')
optdepends=('ca-certificates: HTTPS downloads')
backup=('etc/wgetrc')
install=wget.install
source=(ftp://ftp.gnu.org/gnu/${pkgname}/${pkgname}-${pkgver}.tar.xz{,.sig}
        wget-1.16-fix-test-proxied-https-auth.patch)
sha1sums=('08d991acc80726abe57043a278f9da469c454503'
          'SKIP'
          'a324d1910a6440552a3745c873da9e3dff7d7ec9')

prepare() {
  cd ${pkgname}-${pkgver}
  patch -p1 -i "${srcdir}/wget-1.16-fix-test-proxied-https-auth.patch"
  sed -i 's/--no-check-certificate/& --no-http-keep-alive/' \
    tests/Test-proxied-https-auth.px
  cat >> doc/sample.wgetrc <<EOF

# default root certs location
ca_certificate=/etc/ssl/certs/ca-certificates.crt
EOF
}

build() {
  cd ${pkgname}-${pkgver}
  ./configure --prefix=/usr --sysconfdir=/etc --enable-nls --with-ssl=openssl
  make
}

check() {
  cd ${pkgname}-${pkgver}
  make check
}

package() {
  cd ${pkgname}-${pkgver}
  make DESTDIR="${pkgdir}" install
}