SCons: fix the remaining shared linking problems on Ubuntu-Precise
Our libraries constitute a clear dependency hierarchy, we do not want circular dependencies. Declaring these dependencies while creating the shared libraries would allow strict checking by the linker; but unfortunately this also creates transitive depdendencies stored as DT_NEEDED tags. While basically this would be just fine, the resolution of $ORIGIN on gets confused in case of transitively defined library dependencies over multiple hops, especially in case when actually no symbol of this transitive dependency is used. Since these newer systems set the --as-needed switch for linking by default, these unnecessary DT_NEEDED entries will be purged from the executable, but of course not from the shared library causing the transitive dependencies. As a consequence, when loading the executable, the $ORIGIN resolution mechanism doesn't act on the dependencies recorded in the library, causing the shared loader to abort with an "unresolved dependency" So the resolution for these problems is not to use transitive dependencies on libraries intended to be found via $ORIGIN
This commit is contained in:
parent
56d42e9b04
commit
0710d51aaf
1 changed files with 5 additions and 5 deletions
|
|
@ -11,12 +11,12 @@ Import('env icons config')
|
|||
|
||||
# define the source file/dirs comprising each artifact to be built.
|
||||
|
||||
lLib = env.SharedLibrary('lumiera', srcSubtree('lib'), install=True)
|
||||
lApp = env.SharedLibrary('lumieracommon', srcSubtree('common'), install=True, LIBS=lLib)
|
||||
lBack = env.SharedLibrary('lumierabackend', srcSubtree('backend'),install=True)
|
||||
lProc = env.SharedLibrary('lumieraproc', srcSubtree('proc'), install=True)
|
||||
lLib = env.SharedLibrary('lumiera', srcSubtree('lib'), install=True)
|
||||
lApp = env.SharedLibrary('lumieracommon', srcSubtree('common'), install=True)
|
||||
lBack = env.SharedLibrary('lumierabackend', srcSubtree('backend'), install=True)
|
||||
lProc = env.SharedLibrary('lumieraproc', srcSubtree('proc'), install=True)
|
||||
|
||||
core = lLib+lApp+lBack+lProc
|
||||
core = lProc+lBack+lApp+lLib # in reverse dependency order
|
||||
core_lib = core
|
||||
support_lib = lLib
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue