This commit is contained in:
e.khramov 2022-10-26 11:42:37 +03:00
parent 6682fbe295
commit 499d98d382

@ -12,35 +12,37 @@ deps_amd64=('git go')
build_deps=('git' 'go')
sources_amd64=("git+https://github.com/noisetorch/NoiseTorch.git#tag=v${version}"
"git+https://github.com/noisetorch/c-ringbuf.git"
"git+https://github.com/noisetorch/rnnoise.git")
#"git+https://github.com/noisetorch/c-ringbuf.git"
#"git+https://github.com/noisetorch/rnnoise.git"
)
checksums_amd64=('SKIP'
'SKIP'
'SKIP')
#'SKIP'
#'SKIP'
)
prepare() {
cd "${srcdir}"
git submodule init
git config submodule."c/c-ringbuf.url" "${srcdir}/c-ringbuf"
git config submodule."c/rnnoise.url" "${srcdir}/rnnoise"
git submodule update
#git submodule init
#git config submodule."c/c-ringbuf.url" "${srcdir}/c-ringbuf"
#git config submodule."c/rnnoise.url" "${srcdir}/rnnoise"
#git submodule update
}
build() {
cd "${srcdir}"
export GOPATH="${srcdir}/go"
pushd "c/ladspa"
#export GOPATH="${srcdir}/go"
#pushd "c/ladspa"
make
popd
vendor_flags="-X main.version=${version}"
export CGO_CPPFLAGS="${CPPFLAGS}"
export CGO_CFLAGS="${CFLAGS}"
export CGO_CXXFLAGS="${CXXFLAGS}"
export CGO_LDFLAGS="${LDFLAGS}"
export GOFLAGS="-buildmode=pie -trimpath -mod=readonly -modcacherw"
go generate
go build -ldflags "${vendor_flags} -linkmode=external" -o bin/noisetorch
go clean -modcache
#popd
#vendor_flags="-X main.version=${version}"
#export CGO_CPPFLAGS="${CPPFLAGS}"
#export CGO_CFLAGS="${CFLAGS}"
#export CGO_CXXFLAGS="${CXXFLAGS}"
#export CGO_LDFLAGS="${LDFLAGS}"
#export GOFLAGS="-buildmode=pie -trimpath -mod=readonly -modcacherw"
#go generate
#go build -ldflags "${vendor_flags} -linkmode=external" -o bin/noisetorch
#go clean -modcache
}
package() {