Merge pull request #11119 from jeremyd2019/fix-go-clangarm64

go: add upstream fixes for usage in CLANGARM64
This commit is contained in:
jeremyd2019
2022-03-28 19:08:26 -07:00
committed by GitHub
3 changed files with 17 additions and 12 deletions

View File

@@ -5,17 +5,23 @@ _realname=go
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=1.18
pkgrel=1
pkgrel=2
pkgdesc="Go Lang (mingw-w64)"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64')
license=('BSD')
url="https://www.golang.org/"
depends=()
makedepends=("${MINGW_PACKAGE_PREFIX}-cc" "${MINGW_PACKAGE_PREFIX}-${_realname}")
makedepends=("git"
"${MINGW_PACKAGE_PREFIX}-cc"
"${MINGW_PACKAGE_PREFIX}-${_realname}")
options=('!strip')
source=("https://storage.googleapis.com/golang/go${pkgver}.src.tar.gz")
sha256sums=('38f423db4cc834883f2b52344282fa7a39fbb93650dc62a11fdf0be6409bdad6')
source=("https://storage.googleapis.com/golang/go${pkgver}.src.tar.gz"
"0001-no-dwarf-label-symbols.patch"::"https://github.com/golang/go/commit/cccfb8ffdb97224aed5cc718d4bac3f3df9e55ed.patch"
"0002-sort-relocations.patch"::"https://github.com/golang/go/commit/1a9972ec87de1eba7f9f71c8ed4afa88b0c122d4.patch")
sha256sums=('38f423db4cc834883f2b52344282fa7a39fbb93650dc62a11fdf0be6409bdad6'
'469a86967472989e24e986bb2f21122180ad59da06d10c6d41f9873e068bd289'
'3da855f4ada0bdef7b0ba8531a918086fc819401730da6684937e2a2c1d70b87')
noextract=(go${pkgver}.src.tar.gz)
# Helper macros to help make tasks easier #
@@ -34,6 +40,9 @@ prepare() {
mv "${srcdir}"/${_realname} "${srcdir}"/${_realname}-${pkgver}
cd "${srcdir}/${_realname}-${pkgver}"
apply_patch_with_msg \
0001-no-dwarf-label-symbols.patch \
0002-sort-relocations.patch
}
build() {

View File

@@ -4,7 +4,7 @@ _realname=hugo
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=0.93.2
pkgrel=2
pkgrel=3
pkgdesc='A Fast and Flexible Static Site Generator built with love by bep, spf13 and friends in Go. (mingw-w64)'
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64')
@@ -25,12 +25,8 @@ build() {
export CGO_CXXFLAGS="${CXXFLAGS}"
export CGO_LDFLAGS="${LDFLAGS}"
export GO_LDFLAGS="-s -w"
export GOFLAGS="-trimpath -mod=readonly -modcacherw"
# work around a link error in aarch64
# .debug_frame+1MB: addpesym: could not map .debug_frame+1MB symbol with non .text or .rdata or .data section
if [[ "${CARCH}" != "aarch64" ]]; then
GOFLAGS+=" -ldflags=-linkmode=external"
fi
export GOFLAGS="-trimpath -mod=readonly -modcacherw -ldflags=-linkmode=external"
go build
}

View File

@@ -9,7 +9,7 @@ pkgver=1.58.0
pkgrel=2
pkgdesc='Cloud-aware file synchonization utility (mingw-w64)'
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64')
url='https://rclone.org/'
license=('MIT')
makedepends=("git"