source: trunk/dports/textproc/seekanser/Portfile

Last change on this file was 121645, checked in by hum@…, 3 years ago

seekanswer: fix livecheck.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.1 KB
Line 
1# -*- 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
2# $Id: Portfile 121645 2014-07-03 09:20:31Z ryandesign@macports.org $
3
4PortSystem          1.0
5
6name                seekanser
7version             1.0.7
8categories          textproc java japanese
9platforms           darwin
10maintainers         hum openmaintainer
11license             LGPL-3
12
13homepage            http://seekanser.sourceforge.jp/
14description         a program to seek answers to a quiz in Japanese
15long_description    SeekAnser is ${description}.
16
17master_sites        sourceforge_jp:seekanser/54271/
18distname            SeekAnser(${version})
19use_zip             yes
20checksums           rmd160  a235ca06345903feaa42143bbbc8e219e98928fb \
21                    sha256  19548f35146c3a5a67fee3e803f56e45be05764a4887480bd4068554493afefd
22
23worksrcdir          SeekAnser
24
25depends_lib         port:chasen
26
27# directory where SeekAnser.jar is extracted.
28set jardir          ${worksrcpath}/seekanser-${version}
29set jarname         seekanser-${version}.jar
30set jarpatch        ${filespath}/patch-slothlib.properties.diff
31
32post-extract {
33    file mkdir ${jardir}
34    system -W ${jardir} "jar xf ../SeekAnser\\(${version}\\).jar"
35}
36
37post-patch {
38    system -W ${jardir} "patch < ${jarpatch}"
39    reinplace "s|/usr/|${prefix}/|g" ${jardir}/slothlib.properties
40}
41
42use_configure       no
43supported_archs     noarch
44
45build {
46    system "jar cmf ${jardir}/META-INF/MANIFEST.MF ${worksrcpath}/${jarname} -C ${jardir} ."
47}
48
49destroot {
50    set seekanserdir   ${prefix}/share/${name}
51    xinstall -m 755 -d ${destroot}${seekanserdir}
52    xinstall -m 644 -W ${worksrcpath} \
53        README.txt ${jarname} examples.txt \
54        ${destroot}${seekanserdir}
55    set dest_script    ${destroot}${prefix}/bin/seekanser
56    xinstall -m 755    ${filespath}/seekanser            ${dest_script}
57    reinplace "s|@JARPATH@|${seekanserdir}/${jarname}|g" ${dest_script}
58}
59
60notes "Please run 'seekanser' and have fun!"
61
62livecheck.type      regex
63livecheck.url       http://sourceforge.jp/projects/seekanser/releases/
64livecheck.regex     (\\d+\\.\\d+\\.\\d+)\\s*\\(ChaSen
Note: See TracBrowser for help on using the repository browser.