From 9f7613f5ffc82505a7519e9759cc7d1dc6478b13 Mon Sep 17 00:00:00 2001 From: Lucas Schwiderski Date: Sun, 1 Jan 2023 18:05:27 +0100 Subject: [PATCH] Update 'Obtaining the Oodle library on Linux' --- Obtaining-the-Oodle-library-on-Linux.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Obtaining-the-Oodle-library-on-Linux.md b/Obtaining-the-Oodle-library-on-Linux.md index b7f087a..b83a3e2 100644 --- a/Obtaining-the-Oodle-library-on-Linux.md +++ b/Obtaining-the-Oodle-library-on-Linux.md @@ -94,10 +94,14 @@ find $TEMP -type f -exec ./elf_unhide.py --symfile symbols.txt "{}" \; ar rcs $NEW_ARCHIVE $TEMP/*.o rm -r $TEMP -echo "$(basefile $NEW_ARCHIVE) made" +echo "$(basename $NEW_ARCHIVE) made" ``` **Create the shared library**: + +Create the files above, as well as a file `symbols.txt`, where each line lists one symbol you want to make available for linking. +Then run: + ```shell ./elf_unhide.sh liboo2corelinux64.a liboo2corelinux64_out.a g++ -shared -o liboo2corelinux64.so -Wl,--whole-archive ./liboo2corelinux64_out.a -Wl,--no-whole-archive