summaryrefslogtreecommitdiff
path: root/libs/giflib/MAKEPKG
blob: c087d414ad5f4ab449c385cb677bf85c8bef79cf (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
#!/bin/mkpkg
# description: Library for reading and writing GIF images
# url: https://giflib.sourceforge.net

name=giflib
version=6.1.3
release=1
source=(https://downloads.sourceforge.net/project/giflib/giflib-6.x/$name-$version.tar.gz)

sha256sums=(
    "b65b66b99f0424b93525f987386f22fc5efb9da2bfc92ad4a532249aaffbab0e"
)

build() {
    cd ${name}-${version}

    # Remove doc build from all target (needs xmlto/ImageMagick)
    sed -i '/-C doc/d' Makefile

    # Remove install-doc from install target (builds and installs HTML docs)
    sed -i 's/ install-doc//' Makefile

    # Install prebuilt man pages instead of xml sources
    sed -e 's|giflib.xml|giflib.7|' \
        -re 's|doc/(.*).xml|doc/\1.1|g' \
        -i Makefile

    make CC=cc PREFIX=/usr
    make PREFIX=/usr DESTDIR=$PKG install

    # gif2rgb dropped from install target in 6.x
    install -m755 gif2rgb $PKG/usr/bin/
    install -m644 doc/gif2rgb.1 $PKG/usr/share/man/man1/

    rm -f $PKG/usr/lib/libgif.a
}

signify() {
    untrusted comment: public key
    RWTZ9IduCSQ/mL8337TEUinPwT92xFEUpD92hkS7IxcOnzTt9QdpohT3
}

# vim: filetype=sh