source: trunk/dports/archivers/unzip/Portfile

Last change on this file was 127838, checked in by ryandesign@…, 3 years ago

unzip: use the right -arch flags when not building universal (see https://lists.macosforge.org/pipermail/macports-users/2014-November/037090.html)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 1.7 KB
Line 
1# $Id: Portfile 127838 2014-11-05 03:11:30Z ryandesign@macports.org $
2
3PortSystem              1.0
4
5name                    unzip
6version                 6.0
7maintainers             nomaintainer
8categories              archivers sysutils
9platforms               darwin freebsd
10license                 BSD
11installs_libs   no
12description             Decompression compatible with pkunzip
13
14long_description \
15        UnZip is an extraction utility for archives compressed in .zip \
16        format (also called \"zipfiles\"). Although highly compatible both \
17        with PKWARE's PKZIP and PKUNZIP utilities for MS-DOS and with Info-ZIP's \
18        own Zip program, our primary objectives have been portability and \
19        non-MSDOS functionality.
20
21homepage                http://www.info-zip.org/pub/infozip/UnZip.html
22master_sites            sourceforge:infozip
23distname                ${name}[strsed $version g/\\.//]
24
25checksums           md5     62b490407489521db863b523a7f86375 \
26                    sha1    abf7de8a4018a983590ed6f5cbd990d4740f8a22 \
27                    rmd160  48af66606e9472e45fbb94bc4e285da23d1b89ba
28
29post-patch {
30    reinplace -E "/-O3/s|(LF2=\")|\\1[get_canonical_archflags ld]|" \
31        ${worksrcpath}/unix/Makefile
32}
33
34use_configure   no
35
36variant universal {}
37
38set localflags      [get_canonical_archflags cc]
39
40build.target    macosx
41build.args          -f unix/Makefile \
42                CC="${configure.cc}"
43pre-build {
44    # have to add this here so variants can modify it
45    build.args-append LOCAL_UNZIP="${localflags}"
46}
47
48eval destroot.args      ${build.args} \
49                                BINDIR=${destroot}${prefix}/bin \
50                                MANDIR=${destroot}${prefix}/share/man/man1
51
52post-destroot {
53        set docdir ${prefix}/share/doc/${name}-${version}
54        xinstall -d ${destroot}${docdir}
55        xinstall -m 0644 -W ${worksrcpath} BUGS LICENSE README ToDo \
56                ${destroot}${docdir}
57}
58
59platform darwin 8 {
60    append localflags " -DNO_LCHMOD"
61}
62
63livecheck.type  regex
64livecheck.url   ${homepage}
65livecheck.regex "UnZip (\\d+(?:\\.\\d+)*)"
Note: See TracBrowser for help on using the repository browser.