Opened 8 years ago
Closed 5 years ago
#52036 closed defect (fixed)
go @1.7_0: crypto/x509 build fails with "'SecCertificateCopyNormalizedSubjectContent' is unavailable"
Reported by: | iefdev (Eric F) | Owned by: | ci42 |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.3.4 |
Keywords: | lion | Cc: | ryandesign (Ryan Carsten Schmidt) |
Port: | go |
Description
Latest go failed to build… and then tried to reinstall it with:
$ sudo port clean --all go $ sudo port -v -s upgrade go
Last part:
# crypto/x509 crypto/x509/root_cgo_darwin.go:114:28: error: 'SecCertificateCopyNormalizedSubjectContent' is unavailable CFDataRef subjectName = SecCertificateCopyNormalizedSubjectContent(cert, &errRef); ^ /System/Library/Frameworks/Security.framework/Headers/SecCertificate.h:459:11: note: function has been explicitly marked unavailable here CFDataRef SecCertificateCopyNormalizedSubjectContent(SecCertificateRef certificate, CFErrorRef *error) ^ crypto/x509/root_cgo_darwin.go:119:27: error: 'SecCertificateCopyNormalizedIssuerContent' is unavailable CFDataRef issuerName = SecCertificateCopyNormalizedIssuerContent(cert, &errRef); ^ /System/Library/Frameworks/Security.framework/Headers/SecCertificate.h:442:11: note: function has been explicitly marked unavailable here CFDataRef SecCertificateCopyNormalizedIssuerContent(SecCertificateRef certificate, CFErrorRef *error) ^ 2 errors generated. cmd/link cmd/compile/internal/gc cmd/compile/internal/amd64 cmd/compile/internal/arm64 cmd/compile/internal/arm cmd/compile/internal/ppc64 cmd/compile/internal/mips64 cmd/compile/internal/s390x cmd/compile/internal/x86 cmd/compile Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_go/go/work/go/src" && ./make.bash Exit code: 2 Error: org.macports.build for port go returned: command execution failed Warning: targets not executed for go: org.macports.install org.macports.build org.macports.destroot Please see the log file for port go for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_go/go/main.log Error: Unable to upgrade port: 1 To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets
Attaching the log file.
Attachments (2)
Change History (8)
Changed 8 years ago by iEFdev
Attachment: | go@1.7-main.log added |
---|
comment:1 Changed 8 years ago by larryv (Lawrence Velázquez)
Keywords: | lion added |
---|---|
Owner: | changed from macports-tickets@… to ciserlohn@… |
Port: | go added |
Summary: | go @1.7 build error → go @1.7_0: crypto/x509 build fails on Lion |
comment:2 Changed 8 years ago by larryv (Lawrence Velázquez)
Cc: | ryandesign@… added |
---|---|
Summary: | go @1.7_0: crypto/x509 build fails on Lion → go @1.7_0: crypto/x509 build fails with "'SecCertificateCopyNormalizedSubjectContent' is unavailable" |
Changed 8 years ago by iEFdev
Attachment: | go@1.7.1-main.log added |
---|
comment:4 Changed 8 years ago by scottm@…
This issue seems to be caused by line 10 of src/crypto/x509/root_cgo_darwin.go file, which appears as:
#cgo CFLAGS: -mmacosx-version-min=10.6 -D__MAC_OS_X_VERSION_MAX_ALLOWED=1060
The value of 1060 for __MAC_OS_X_VERSION_MAX_ALLOWED represents OSX 10.6, which conflicts with compiling it on lion. Removing this restriction allows successful compilation.
I didn't research beyond just getting it to build on my box -- but from the look of it, I don't understand how it could be compiled anywhere.
comment:5 Changed 8 years ago by iEFdev
Last version: go@1.7.3
return this error:
Error: go 1.7.3 requires Mac OS X 10.8 or greater. Error: org.macports.fetch for port go returned: incompatible Mac OS X version
Unless there will be a fix/patch that, you can close this now since I'm on Lion.
· Eric
comment:6 Changed 5 years ago by kencu (Ken)
Resolution: | → fixed |
---|---|
Status: | new → closed |
somewhere along the way this has been fixed for Lion:
$ port -v installed go The following ports are currently installed: go @1.12.7_0 (active) platform='darwin 11' archs='x86_64' date='2019-07-10T11:19:34-0700'
Has duplicate #52047.