]> git.cworth.org Git - glaze/commitdiff
Add a version script for libglaze
authorCarl Worth <cworth@cworth.org>
Tue, 24 Sep 2013 22:38:45 +0000 (15:38 -0700)
committerCarl Worth <cworth@cworth.org>
Thu, 18 Dec 2014 15:01:08 +0000 (07:01 -0800)
Explicitly listing the very few functions we want to export globally
in libfips.so, ensuring that everything else is kepy local.

Makefile
libglaze.sym [new file with mode: 0644]

index d881b38df1901deb9b8ee54fc64c7654dcd993af..b679e99116b42b9a4ccbba5e8718bd4ebd6a4875 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -50,10 +50,10 @@ glaze: glaze.c $(LIBGLAZE_LINKER_NAME)
        $(CC) $(GLAZE_CFLAGS) -I. -L. -o $@ $< -ldl -lglaze
 
 $(LIBGLAZE_32_LIBNAME): libglaze.c
-       $(CC) $(GLAZE_CFLAGS) -m32 -fPIC -shared -Wl,-Bsymbolic,-soname=$(LIBGLAZE_SONAME) -ldl -ltalloc -o $@ $<
+       $(CC) $(GLAZE_CFLAGS) -m32 -fPIC -shared -Wl,--version-script=libglaze.sym,-soname=$(LIBGLAZE_SONAME) -ldl -ltalloc -o $@ $<
 
 $(LIBGLAZE_LIBNAME): libglaze.c
-       $(CC) $(GLAZE_CFLAGS) -m64 -fPIC -shared -Wl,-Bsymbolic,-soname=$(LIBGLAZE_SONAME) -ldl -ltalloc -o $@ $<
+       $(CC) $(GLAZE_CFLAGS) -m64 -fPIC -shared -Wl,--version-script=libglaze.sym,-soname=$(LIBGLAZE_SONAME) -ldl -ltalloc -o $@ $<
 
 $(LIBGLAZE_LINKER_NAME): $(LIBGLAZE_LIBNAME)
        ln -sf $(LIBGLAZE_LIBNAME) $@
diff --git a/libglaze.sym b/libglaze.sym
new file mode 100644 (file)
index 0000000..9a773da
--- /dev/null
@@ -0,0 +1,8 @@
+{
+global:
+       glaze_execute;
+       glaze_lookup;
+       glaze_set_first_gl_call_callback;
+local:
+       *;
+};