dev-lang/go: Upgrade go to v1.19.3.

BUG=b/254691844
TEST=presubmit
RELEASE_NOTE=Upgraded dev-lang/go to v1.19.3.

Change-Id: I69da10de01a33009a0f3a2b7f699323633e88917
Reviewed-on: https://cos-review.googlesource.com/c/third_party/overlays/chromiumos-overlay/+/38650
Tested-by: Cusky Presubmit Bot <presubmit@cos-infra-prod.iam.gserviceaccount.com>
Reviewed-by: Oleksandr Tymoshenko <ovt@google.com>
Reviewed-by: Robert Kolchmeyer <rkolchmeyer@google.com>
diff --git a/dev-lang/go/Manifest b/dev-lang/go/Manifest
index dc2515b..2ae807a 100644
--- a/dev-lang/go/Manifest
+++ b/dev-lang/go/Manifest
@@ -1,2 +1,2 @@
-DIST go1.17.1.src.tar.gz 22181735 BLAKE2B 77ce952e14c101776935c625aa39596a6b8923ca5ac264c72ed08a578f08fbbbc1825315a5dd84f9fa1412aaa7400b31e73117d5919aeb527c084173d8e11504 SHA512 23d4e003651204c5bcc5cf41437134e07a3fe3c188eb129f2d6366a7445a7919d6a7319c57483e91b3415fd28aa55df8d58eec398434f20ce6accd587925a14b
+DIST go1.19.3.src.tar.gz 26535494 BLAKE2B 369f2fe45cda19f3c5e840a7d737a45268c6d5a63f25b99d221793cea00c50ffc72f88944e8e137ae8128563d8f562cc3e49c3399a75adb2437d877e4ba0c222 SHA512 9aa8548597d52455afad8bf3b882eeeb9992814721ff2b9d8ed1f0e1ee0fec74aecd9d4e8c9c00eafbfe690bcdc50f3ad0b00bc4818b87e9d584cce7df97ee76
 DIST go1.4-bootstrap-20170531.tar.gz 11315348 BLAKE2B bdc66bc1aca3f86ca8deaa01f598db955d6de6dd069bc2ae095a4335a9b113079aff93a23310c3bb6ea7e91b0ce0ef45394ce7094d234f7daffc088af4c1b6e0 SHA512 f04b4822aae0953ec2982ab9e8ad02dde588bbf3cf27ad294178f7faa7c3359ee20e77c2c06b293e88d9b680b79c4b5958f1f772f0710637324a3b8c024c1bc3
diff --git a/dev-lang/go/go-1.17.1-r1.ebuild b/dev-lang/go/go-1.17.1-r1.ebuild
deleted file mode 120000
index a3e2ea0..0000000
--- a/dev-lang/go/go-1.17.1-r1.ebuild
+++ /dev/null
@@ -1 +0,0 @@
-go-1.17.1.ebuild
\ No newline at end of file
diff --git a/dev-lang/go/go-1.19.3-r1.ebuild b/dev-lang/go/go-1.19.3-r1.ebuild
new file mode 120000
index 0000000..e599432
--- /dev/null
+++ b/dev-lang/go/go-1.19.3-r1.ebuild
@@ -0,0 +1 @@
+go-1.19.3.ebuild
\ No newline at end of file
diff --git a/dev-lang/go/go-1.17.1.ebuild b/dev-lang/go/go-1.19.3.ebuild
similarity index 86%
rename from dev-lang/go/go-1.17.1.ebuild
rename to dev-lang/go/go-1.19.3.ebuild
index d81562e..e1cdf49 100644
--- a/dev-lang/go/go-1.17.1.ebuild
+++ b/dev-lang/go/go-1.19.3.ebuild
@@ -1,7 +1,7 @@
-# Copyright 2016 The Chromium OS Authors. All rights reserved.
+# Copyright 2022 The ChromiumOS Authors
 # Distributed under the terms of the GNU General Public License v2.
 
-EAPI=5
+EAPI=7
 
 inherit eutils toolchain-funcs
 
@@ -17,7 +17,7 @@
 SLOT="0"
 KEYWORDS="*"
 IUSE=""
-RESTRICT="binchecks strip"
+RESTRICT="binchecks"
 
 is_cross() {
 	[[ "${CATEGORY}" == cross-* ]]
@@ -45,7 +45,7 @@
 }
 
 get_goarch() {
-	case "$(tc-arch $1)" in
+	case "$(tc-arch "$1")" in
 		amd64) echo "amd64" ;;
 		x86) echo "386" ;;
 		arm) echo "arm" ;;
@@ -67,10 +67,10 @@
 
 src_compile() {
 	einfo "Building the bootstrap compiler."
-	cd "${GOROOT_BOOTSTRAP}/src"
+	cd "${GOROOT_BOOTSTRAP}/src" || die
 	./make.bash || die
 
-	cd "${S}/src"
+	cd "${S}/src" || die
 	einfo "Building the cross compiler for ${CTARGET}."
 	local go_target_cc="$(tc-getTARGET_CC)"
 	local go_target_cxx="$(tc-getTARGET_CXX)"
@@ -85,7 +85,7 @@
 
 	if is_cross ; then
 		einfo "Building the standard library with -buildmode=pie."
-		GOOS="linux" GOARCH="$(get_goarch ${CTARGET})" CGO_ENABLED="1" \
+		GOOS="linux" GOARCH="$(get_goarch "${CTARGET}")" CGO_ENABLED="1" \
 			CC="$(tc-getTARGET_CC)" \
 			CXX="$(tc-getTARGET_CXX)" \
 			GOROOT="${S}" \
@@ -95,7 +95,7 @@
 
 src_install() {
 	local goroot="$(get_goroot)"
-	local tooldir="pkg/tool/linux_$(get_goarch ${CBUILD})"
+	local tooldir="pkg/tool/linux_$(get_goarch "${CBUILD}")"
 
 	insinto "${goroot}"
 	doins -r src lib
@@ -105,9 +105,9 @@
 
 	insinto "${goroot}/pkg"
 	doins -r "pkg/include"
-	doins -r "pkg/linux_$(get_goarch ${CTARGET})"
+	doins -r "pkg/linux_$(get_goarch "${CTARGET}")"
 	if is_cross ; then
-		doins -r "pkg/linux_$(get_goarch ${CTARGET})_shared"
+		doins -r "pkg/linux_$(get_goarch "${CTARGET}")_shared"
 	fi
 
 	exeinto "${goroot}/${tooldir}"
@@ -129,7 +129,7 @@
 	fi
 
 	# Fill in variable values in the compiler wrapper.
-	sed -e "s:@GOARCH@:$(get_goarch ${CTARGET}):" \
+	sed -e "s:@GOARCH@:$(get_goarch "${CTARGET}"):" \
 		-e "s:@CC@:$(tc-getTARGET_CC):" \
 		-e "s:@CXX@:$(tc-getTARGET_CXX):" \
 		-e "s:@GOTOOL@:${GOROOT_FINAL}/bin/go:" \