1
0
mirror of https://github.com/golang/go synced 2024-09-30 04:34:33 -06:00
go/misc
Michael Hudson-Doyle 77fc03f4cd cmd/internal/ld, runtime: abort on shared library ABI mismatch
This:

1) Defines the ABI hash of a package (as the SHA1 of the __.PKGDEF)
2) Defines the ABI hash of a shared library (sort the packages by import
   path, concatenate the hashes of the packages and SHA1 that)
3) When building a shared library, compute the above value and define a
   global symbol that points to a go string that has the hash as its value.
4) When linking against a shared library, read the abi hash from the
   library and put both the value seen at link time and a reference
   to the global symbol into the moduledata.
5) During runtime initialization, check that the hash seen at link time
   still matches the hash the global symbol points to.

Change-Id: Iaa54c783790e6dde3057a2feadc35473d49614a5
Reviewed-on: https://go-review.googlesource.com/8773
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Michael Hudson-Doyle <michael.hudson@canonical.com>
2015-05-12 01:30:40 +00:00
..
android misc/android: choose the right subdirectory for bin under GOPATH. 2015-01-16 22:02:52 +00:00
arm
cgo cmd/internal/ld, runtime: abort on shared library ABI mismatch 2015-05-12 01:30:40 +00:00
chrome/gophertool misc/chrome/gophertool: update for the git/gerrit transition 2014-12-18 07:34:46 +00:00
git
ios misc/ios: fix plist indentation and whitespace 2015-05-05 21:04:05 +00:00
linkcheck misc/linkcheck: better redirect handling, use meaningful exit code 2013-10-25 17:31:02 +03:00
makerelease misc/makerelease: send file size when uploading 2015-01-20 04:09:23 +00:00
nacl cmd/api: re-enable TestGolden on nacl 2015-04-08 06:36:36 +00:00
swig misc/swig/callback: fix test for SWIG -cgo support 2015-03-06 15:28:50 +00:00
trace misc/trace: add license for the trace-viewer 2015-05-11 06:09:10 +00:00
benchcmp all: use golang.org/x/... import paths 2014-11-10 09:15:57 +11:00
editors all: don't refer to code.google.com/p/go{,-wiki}/ 2015-02-06 14:41:47 +00:00