-Wl,--no-undefined
linker option can be used when building shared library, undefined symbols will be shown as linker errors.
g++ -shared -Wl,-soname,libmylib.so.5 -Wl,--no-undefined \
-o libmylib.so.1.1 mylib.o -lthirdpartylib
More Related Contents:
- When to use dynamic vs. static libraries
- Using includes with c++ shared libraries
- How to add additional libraries to Visual Studio project?
- Difference between static and shared libraries?
- C/C++ with GCC: Statically add resource files to executable/library
- What happens to global and static variables in a shared library when it is dynamically linked?
- Static linking vs dynamic linking
- C++ Dynamic Shared Library on Linux
- What do linkers do?
- Call Go functions from C
- Linking two shared libraries with some of the same symbols
- How do you find what version of libstdc++ library is installed on your linux machine?
- Linking a shared library with another shared lib in linux
- Compilation fails with “relocation R_X86_64_32 against `.rodata.str1.8′ can not be used when making a shared object”
- How to check what shared libraries are loaded at run time for a given process?
- Elegantly call C++ from C
- How to create a shared library with cmake?
- How to link using GCC without -l nor hardcoding path for a library that does not follow the libNAME.so naming convention?
- Static analysis tool to detect ABI breaks in C++ [closed]
- What are good practices regarding shared libraries on Linux?
- “relocation R_X86_64_32S against ” linking Error
- cmake find_package specify path
- Static and Dynamic/Shared Linking with MinGW
- Why is CMake designed so that it removes runtime path when installing
- Load 32-bit shared library from 64-bit application?
- Convert a Static Library to a Shared Library (create libsome.so from libsome.a): where’s my symbols?
- What does exactly the warning mean about hidden symbol being referenced by DSO?
- String comparison operators
- How to include libraries in Visual Studio 2012?
- What is the datatype of string literal in C++?