# -*- 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 java 1.0 name LanguageTool version 6.5 revision 0 categories aqua textproc java license LGPL-2.1 maintainers {amake @amake} openmaintainer description Proofreading tool for numerous languages long_description LanguageTool is an Open Source proofreading software for English, French, \ German, Polish, Russian, and more than 20 other languages. It finds many \ errors that a simple spell checker cannot detect. homepage https://languagetool.org/ platforms {darwin any} supported_archs noarch master_sites https://languagetool.org/download/ checksums rmd160 d830debac81e8a0eaa38f1e4aee695a37b5c7cc0 \ sha256 27f3ae5a29efbc8267a5a266908dfec205d16d312af8516e0b5bcec871edea0b \ size 248160977 java.version 1.8+ use_zip yes use_configure no build {} destroot { set name_lower [string tolower ${name}] xinstall -m 0755 -d ${destroot}${prefix}/share/java set target_dir ${prefix}/share/java/${name} copy ${worksrcpath} ${destroot}/${target_dir} # CLI wrapper script set cli_bin ${destroot}${prefix}/bin/${name_lower} xinstall -m 0755 ${filespath}/${name}_cli_bin ${cli_bin} reinplace "s|@@JAR@@|${target_dir}/${name_lower}-commandline.jar|g" ${cli_bin} # Server wrapper script set server_bin ${destroot}${prefix}/bin/${name_lower}-server xinstall -m 0755 ${filespath}/${name}_server_bin ${server_bin} reinplace "s|@@JAR@@|${target_dir}/${name_lower}-server.jar|g" ${server_bin} set app ${destroot}${applications_dir}/${name}.app xinstall -d ${app}/Contents/MacOS xinstall -d ${app}/Contents/Resources xinstall -m 0644 ${filespath}/Info.plist ${app}/Contents/ reinplace "s|@@VERSION@@|${version}|g" ${app}/Contents/Info.plist xinstall -m 0644 ${filespath}/${name}.icns ${app}/Contents/Resources/ set app_bin ${app}/Contents/MacOS/${name} xinstall -m 0755 ${filespath}/${name}_app_bin ${app_bin} reinplace "s|@@JAVA_VERSION@@|${java.version}|g" ${app_bin} reinplace "s|@@ICON@@|${applications_dir}/${name}.app/Contents/Resources/${name}.icns|g" ${app_bin} reinplace "s|@@NAME@@|${name}|g" ${app_bin} reinplace "s|@@JAR@@|${target_dir}/${name_lower}.jar|g" ${app_bin} } universal_variant no startupitem.create yes startupitem.executable ${prefix}/bin/languagetool-server --http --port 8081 --allow-origin "*" livecheck.type regex livecheck.url ${master_sites} livecheck.regex ${name}-(\\d+(\\.\\d+)?)\\.zip