diff --git a/lang/go/bootstrap.mk b/lang/go/bootstrap.mk index e09f436bc168..746a94ea7639 100644 --- a/lang/go/bootstrap.mk +++ b/lang/go/bootstrap.mk @@ -1,7 +1,9 @@ -# $NetBSD: bootstrap.mk,v 1.8 2022/03/09 15:15:59 bacon Exp $ +# $NetBSD: bootstrap.mk,v 1.9 2023/01/28 12:34:30 jperkin Exp $ .if !defined(GOROOT_BOOTSTRAP) || !exists(${GOROOT_BOOTSTRAP}/bin/go) -. if ${MACHINE_ARCH} == "aarch64" || ${OPSYS} == "Darwin" && ${OPSYS_VERSION} >= 120000 +. if ${MACHINE_ARCH} == "aarch64" || \ + (${OPSYS} == "Darwin" && ${OPSYS_VERSION} >= 120000) || \ + (${OPSYS} == "SunOS" && ${OS_VARIANT} != "Solaris") BUILD_DEPENDS+= go-bin-[0-9]*:../../lang/go-bin GOROOT_BOOTSTRAP= ${PREFIX}/go-bin . else diff --git a/lang/go/version.mk b/lang/go/version.mk index 193865284d49..fc1e76b73f7d 100644 --- a/lang/go/version.mk +++ b/lang/go/version.mk @@ -1,4 +1,4 @@ -# $NetBSD: version.mk,v 1.169 2023/01/11 17:24:29 bsiegert Exp $ +# $NetBSD: version.mk,v 1.170 2023/01/28 12:34:30 jperkin Exp $ # # If bsd.prefs.mk is included before go-package.mk in a package, then this @@ -50,7 +50,13 @@ GOOPT= GOARM=6 .elif ${MACHINE_ARCH} == "earmv7hf" GOOPT= GOARM=7 .endif + +.if ${OPSYS} == "SunOS" && ${OS_VARIANT} != "Solaris" +GO_PLATFORM= illumos_${GOARCH} +.else GO_PLATFORM= ${LOWER_OPSYS}_${GOARCH} +.endif + PLIST_SUBST+= GO_PLATFORM=${GO_PLATFORM:Q} GOARCH=${GOARCH:Q} PLIST_SUBST+= GOCHAR=${GOCHAR:Q}