github.com/geraldss/go/src@v0.0.0-20210511222824-ac7d0ebfc235/runtime/cgo/libcgo_windows.h (about) 1 // Copyright 2020 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 // Ensure there's one symbol marked __declspec(dllexport). 6 // If there are no exported symbols, the unfortunate behavior of 7 // the binutils linker is to also strip the relocations table, 8 // resulting in non-PIE binary. The other option is the 9 // --export-all-symbols flag, but we don't need to export all symbols 10 // and this may overflow the export table (#40795). 11 // See https://sourceware.org/bugzilla/show_bug.cgi?id=19011 12 __declspec(dllexport) int _cgo_dummy_export;