Ticket #17623: Portfile

File Portfile, 1.8 KB (added by 0xced (Cédric Luthi), 16 years ago)

Portfile with lzma variant

Line 
1# $Id$
2
3PortSystem 1.0
4
5name             upx
6version          3.03
7categories       archivers
8maintainers      cedric.luthi@gmail.com
9description      compress or expand executable files
10long_description UPX is a free, portable, extendable, high-performance \
11                 executable packer for several different executable formats
12homepage         http://upx.sourceforge.net
13platforms        darwin
14master_sites     ${homepage}/download/
15
16distname         ${name}-${version}-src
17use_bzip2        yes
18checksums        ${distname}${extract.suffix} md5 1d5830fff06537a129c923527c4ce205 \
19                 ${distname}${extract.suffix} sha1 b7e6f93d355e689e63776a2a94ce3c8cf5ef60dd \
20                 ${distname}${extract.suffix} rmd160 224f7d93e829b66d1786155522a7a43c0f11f3ce
21
22use_configure    no
23build.env        CPPFLAGS="-I${prefix}/include" LDFLAGS="-L${prefix}/lib"
24
25depends_lib      port:ucl
26
27destroot {
28    xinstall -m 755 ${worksrcpath}/src/upx.out ${destroot}${prefix}/bin/upx
29
30    xinstall -m 644 ${worksrcpath}/doc/upx.1 ${destroot}${prefix}/share/man/man1
31
32    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
33    xinstall -m 644 -W ${worksrcpath}/doc upx.doc upx.html ${destroot}${prefix}/share/doc/${name}   
34    xinstall -m 644 -W ${worksrcpath} BUGS COPYING LICENSE NEWS PROJECTS README README.1ST README.SRC THANKS TODO ${destroot}${prefix}/share/doc/${name}
35}
36
37variant lzma {
38    set lzma-distfile lzma457.tar.bz2
39    master_sites-append sourceforge:sevenzip:lzma
40    distfiles-append    ${lzma-distfile}:lzma
41    checksums-append    ${lzma-distfile} md5 fc7a12a396ade1772e959604d6eb31e1 \
42                        ${lzma-distfile} sha1 bd1b46ba42fe1ad7351a39c131e8b7657e909001 \
43                        ${lzma-distfile} rmd160 9a3b8577e99f4ae4e62e75e1f3bbd3f1626e140f
44    build.env-append    UPX_LZMADIR="${workpath}"
45}