Hi, I've just noticed I've somehow messed up my commits right before sending the v2, disregard this one and 7/8 is two commits squashed together it seems. I'll resend. Cheers, Lukas On Mon, 2019-01-14 at 17:38 +0100, Lukáš Hrázký wrote: > This commits adds the -export-dynamic linker flag to export dynamic > symbols to be used by the streaming agent's plugins. It also adds the > -fvisibility=hidden compiler flag to hide all symbols by default (along > with -fvisibility-inline-hidden for C++ inline functions). > > Then it adds the visibility("default") attribute to the namespace > containing the Error class, as that one needs to be exported and have > its typeinfo defined for exception catching to work. > > Signed-off-by: Lukáš Hrázký <lhrazky@xxxxxxxxxx> > Acked-by: Frediano Ziglio <fziglio@xxxxxxxxxx> > --- > include/spice-streaming-agent/error.hpp | 2 +- > src/Makefile.am | 4 ++++ > 2 files changed, 5 insertions(+), 1 deletion(-) > > diff --git a/include/spice-streaming-agent/error.hpp b/include/spice-streaming-agent/error.hpp > index 3202d78..c0d4755 100644 > --- a/include/spice-streaming-agent/error.hpp > +++ b/include/spice-streaming-agent/error.hpp > @@ -11,7 +11,7 @@ > #include <string> > > > -namespace spice { > +namespace spice __attribute__ ((visibility ("default"))) { > namespace streaming_agent { > > class Error : public std::runtime_error > diff --git a/src/Makefile.am b/src/Makefile.am > index dc64c29..bae3f9d 100644 > --- a/src/Makefile.am > +++ b/src/Makefile.am > @@ -22,10 +22,13 @@ AM_CPPFLAGS = \ > $(NULL) > > AM_CFLAGS = \ > + -fvisibility=hidden \ > $(WARN_CFLAGS) \ > $(NULL) > > AM_CXXFLAGS = \ > + -fvisibility=hidden \ > + -fvisibility-inlines-hidden \ > $(WARN_CXXFLAGS) \ > $(NULL) > > @@ -38,6 +41,7 @@ libstreaming_utils_a_SOURCES = \ > $(NULL) > > spice_streaming_agent_LDFLAGS = \ > + -export-dynamic \ > $(RELRO_LDFLAGS) \ > $(NO_INDIRECT_LDFLAGS) \ > $(NULL) _______________________________________________ Spice-devel mailing list Spice-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/spice-devel