# -*- 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/ddev/ddev 1.23.5 v go.offline_build no fetch.type git categories devel license Apache-2 maintainers {@jlorenzetti} openmaintainer description Local PHP development environment management tool long_description DDEV is an open source tool for launching local PHP web development \ environments in minutes. It helps developers create and manage \ Docker-based development environments with support for multiple PHP \ versions, web servers, databases, and other tools. homepage https://ddev.com # Dependencies depends_build-append \ port:gmake depends_run port:mkcert # Build configuration build.env-append CGO_ENABLED=0 build.env-append GOFLAGS=-mod=vendor\ -buildvcs=false build.cmd ${prefix}/bin/gmake # Set build target based on architecture if {${build_arch} eq "x86_64"} { set go_arch "amd64" } elseif {${build_arch} eq "arm64"} { set go_arch "arm64" } build.target darwin_${go_arch} destroot { # Install binary xinstall -m 755 ${worksrcpath}/.gotmp/bin/darwin_${go_arch}/ddev ${destroot}${prefix}/bin/ # Generate shell completions system -W ${worksrcpath} "GOFLAGS=-buildvcs=false ${build.cmd} completions" # Extract completions system -W ${worksrcpath} "mkdir -p .gotmp/bin/completions_extracted" system -W ${worksrcpath} "tar xzf .gotmp/bin/completions.tar.gz -C .gotmp/bin/completions_extracted" # Install shell completions xinstall -d ${destroot}${prefix}/share/bash-completion/completions xinstall -m 644 ${worksrcpath}/.gotmp/bin/completions_extracted/ddev_bash_completion.sh \ ${destroot}${prefix}/share/bash-completion/completions/ddev xinstall -d ${destroot}${prefix}/share/zsh/site-functions xinstall -m 644 ${worksrcpath}/.gotmp/bin/completions_extracted/ddev_zsh_completion.sh \ ${destroot}${prefix}/share/zsh/site-functions/_ddev xinstall -d ${destroot}${prefix}/share/fish/vendor_completions.d xinstall -m 644 ${worksrcpath}/.gotmp/bin/completions_extracted/ddev_fish_completion.sh \ ${destroot}${prefix}/share/fish/vendor_completions.d/ddev.fish } test.run yes test.cmd ${build.cmd} test.target test github.livecheck.regex {([0-9.]+)}