glslang: Only export public interface for SOs
authorBen Clayton <bclayton@google.com>
Mon, 29 Jun 2020 13:20:19 +0000 (14:20 +0100)
committerBen Clayton <bclayton@google.com>
Tue, 30 Jun 2020 16:06:17 +0000 (17:06 +0100)
commitd64e8599870ac1e3eb401610b08ff65d97f879bd
treedae9588df3d6221e692c1884d61520401a0991d6
parentc858d7bd811edaa758cca5479a7d12a2cf851a6a
glslang: Only export public interface for SOs

Default to `-fvisibility=hidden`, and annotate the public glslang interface with `GLSLANG_EXPORT` to change the visibility of these cherry-picked symbols to default.
This is also used by Windows builds for `__declspec(dllexport)`-ing the public DLL interface.

This allows us to classify API changes into those that are publicly backwards compatible, and those that are not.

Note that `libSPIRV` will likely need similar treatment.

Issues: #2283, #1484
CMakeLists.txt
StandAlone/StandAlone.cpp
glslang/CMakeLists.txt
glslang/Public/ShaderLang.h