# -*- 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           golang 1.0

go.setup            github.com/anchore/quill 0.4.1 v
revision            0

description         Simple macOS binary signing from any platform

long_description    {*}${description}

categories          security sysutils
installs_libs       no
license             Apache-2
maintainers         {gmail.com:herby.gillot @herbygillot} \
                    openmaintainer

checksums           rmd160  6857aaa3d62abbc29a67c5a43de757f0f216d879 \
                    sha256  8748fda02404711af62d839058e67927afa0eef810227e274f8cc24e07ca5d08 \
                    size    169422

go.offline_build no

build.pre_args-append \
    -ldflags \" \
        -w -s -extldflags '-static' \
        -X ${go.package}/internal/version.version=v${version} \
    \" \
    -o _bin/${name}

build.args          ./cmd/${name}

destroot {
    xinstall -m 0755 ${worksrcpath}/_bin/${name} ${destroot}${prefix}/bin/
}