summaryrefslogtreecommitdiff
path: root/libexpat/build.sh
blob: c0d4c53acaa64688dd6e85a1a3b3a93b12e19891 (plain) (blame)
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
#!/bin/bash
name=libexpat
version=2.2.9
revision=0
sources=(
    "https://github.com/${name}/${name}/archive/R_${version//./_}.tar.gz"
)
build_depends=(
    "autoconf"
    "automake"
    "libtool"
    "m4"
    "gettext"
)
depends=()


function prepare() {
    tar xf R_${version//./_}.tar.gz
    cd ${name}-R_${version//./_}/expat

    if [[ $(uname -s) == Darwin ]]; then
        LDFLAGS="-L${_runtime}"
    fi
}

function build() {
    autoreconf -i
    ./configure --prefix="${_prefix}" \
        --libdir="${_prefix}/lib"
    make -j${_maxjobs}
}

function package() {
    make install DESTDIR="${_pkgdir}"
}