forked from macports/macports-ports
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Portfile
75 lines (55 loc) · 2.43 KB
/
Portfile
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
PortSystem 1.0
PortGroup github 1.0
name upx
categories archivers
platforms darwin
license GPL-2+
maintainers {l2dy @l2dy} openmaintainer
description compress or expand executable files
long_description UPX is a free, portable, extendable, high-performance \
executable packer for several executable formats.
homepage https://upx.github.io/
if {${name} eq ${subport}} {
github.setup upx upx 3.96 v
github.tarball_from releases
distname upx-${version}-src
use_xz yes
checksums rmd160 ca7267db80cff02d50ecbf259906b64f119dfb56 \
sha256 47774df5c958f2868ef550fb258b97c73272cb1f44fe776b798e393465993714 \
size 792524
conflicts upx-devel
}
subport upx-devel {
github.setup upx upx b4558e2049653c832cfde6c9a23d28455743853e
github.livecheck.branch devel
version 20211127
fetch.type git
post-fetch {
system -W ${worksrcpath} "git submodule update --init"
}
conflicts upx
compiler.cxx_standard \
2014
}
use_configure no
depends_lib port:ucl port:zlib
post-configure {
reinplace "s|CXXFLAGS += -fno-delete-null-pointer-checks||" ${worksrcpath}/src/Makefile
reinplace "s|CXXFLAGS_NO_DELETE_NULL_POINTER_CHECKS ?= -fno-delete-null-pointer-checks||" ${worksrcpath}/src/Makefile
reinplace "s| -Wvla||" ${worksrcpath}/src/Makefile
}
variant universal {}
build.env CXX=${configure.cxx} \
"CXXFLAGS_OPTIMIZE=${configure.cxxflags} [get_canonical_archflags cxx]" \
CXXFLAGS_WERROR=
destroot {
xinstall -m 755 ${worksrcpath}/src/upx.out ${destroot}${prefix}/bin/upx
xinstall -m 644 ${worksrcpath}/doc/upx.1 ${destroot}${prefix}/share/man/man1
xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
xinstall -m 644 -W ${worksrcpath}/doc upx.doc upx.html ${destroot}${prefix}/share/doc/${name}
xinstall -m 644 -W ${worksrcpath} BUGS COPYING LICENSE NEWS README README.1ST README.SRC THANKS ${destroot}${prefix}/share/doc/${name}
if {${name} eq ${subport}} {
xinstall -m 644 -W ${worksrcpath} PROJECTS ${destroot}${prefix}/share/doc/${name}
}
}