1 | # -*- coding: utf-8; mode: tcl; tab-width: 8; truncate-lines: t; indent-tabs-mode: nil; c-basic-offset: 4 |
---|
2 | # vim: set fileencoding=utf-8 tabstop=8 shiftwidth=4 softtabstop=4 noexpandtab filetype=tcl : |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | |
---|
6 | #PortGroup github 1.0 |
---|
7 | |
---|
8 | name pdftk-java |
---|
9 | set git_project pdftk |
---|
10 | set git_commit 1aab675b178baf38601f8898ca3530dc222bed97 |
---|
11 | set git_date 20190702 |
---|
12 | version ${git_date} |
---|
13 | |
---|
14 | categories textproc graphics pdf java |
---|
15 | maintainers nomaintainer |
---|
16 | license GPL-2 |
---|
17 | platforms darwin |
---|
18 | description A port of pdftk into java |
---|
19 | long_description ${description} |
---|
20 | supported_archs noarch |
---|
21 | |
---|
22 | homepage https://gitlab.com/pdftk-java/${git_project} |
---|
23 | master_sites https://gitlab.com/pdftk-java/${git_project}/-/archive/${git_commit}/ |
---|
24 | |
---|
25 | checksums rmd160 02546b6b1553348f4b5b74fd421a8ed2a84bd282 \ |
---|
26 | sha256 306c73693bc24fa7b6ea32967a7028cb027b4658f4eae96cb3a046c413da07d8 \ |
---|
27 | size 1360035 |
---|
28 | |
---|
29 | depends_build bin:ant:apache-ant port:bcprov port:commons-lang3 |
---|
30 | |
---|
31 | worksrcdir ${git_project}-${git_commit} |
---|
32 | |
---|
33 | use_configure no |
---|
34 | |
---|
35 | pre-build { |
---|
36 | file mkdir ${worksrcpath}/lib |
---|
37 | system "cd ${worksrcpath}/lib && ln -s ${prefix}/share/java/bcprov/bcprov.jar" |
---|
38 | system "cd ${worksrcpath}/lib && ln -s ${prefix}/share/java/commons-lang3.jar" |
---|
39 | } |
---|
40 | |
---|
41 | build.cmd ant |
---|
42 | build.target jar |
---|
43 | |
---|
44 | destroot { |
---|
45 | set javadir ${destroot}${prefix}/share/java |
---|
46 | xinstall -d -m 755 -d ${javadir}/${name} |
---|
47 | xinstall -m 644 ${worksrcpath}/build/jar/${git_project}.jar ${javadir}/${name}/${git_project}.jar |
---|
48 | |
---|
49 | # Install the wrapper script |
---|
50 | xinstall -m 755 ${filespath}/pdftk-java ${destroot}${prefix}/bin/${name} |
---|
51 | reinplace "s|_PREFIX_|${prefix}|g" ${destroot}${prefix}/bin/${name} |
---|
52 | } |
---|
53 | |
---|