Build: always link explicitly agrainst lib rt
This improves sane library dependencies, as mandated by debian policy. Some of the librt functions are in such wide use, that we'd get them through transitive dependencies anyway. But linking explicitly against a function adds the DT_NEEDED for this library to our build artefacts. This is correct, since we're actually using these functions ourselves, making them into direct dependencies.
This commit is contained in:
parent
8defe47507
commit
1e04ee16ea
1 changed files with 4 additions and 6 deletions
|
|
@ -56,6 +56,10 @@ def configure(env):
|
|||
conf.env.Append(CPPFLAGS = ' -DHAVE_PTHREAD')
|
||||
conf.env.Append(CCFLAGS = ' -pthread')
|
||||
|
||||
if not conf.CheckLib(symbol='clock_gettime', library='rt'):
|
||||
problems.append('We expect the POSIX realtime extensions to be available through librt. ' +
|
||||
'Unable to use clock_gettime()')
|
||||
|
||||
if conf.CheckCHeader('execinfo.h'):
|
||||
conf.env.Append(CPPFLAGS = ' -DHAVE_EXECINFO_H')
|
||||
|
||||
|
|
@ -89,12 +93,6 @@ def configure(env):
|
|||
problems.append('We need the boost regular expression lib (incl. binary lib for linking).')
|
||||
|
||||
|
||||
if conf.CheckLib(symbol='clock_gettime'):
|
||||
print 'Using function clock_gettime() as defined in the C-lib...'
|
||||
else:
|
||||
if not conf.CheckLib(symbol='clock_gettime', library='rt'):
|
||||
problems.append('No library known to provide the clock_gettime() function.')
|
||||
|
||||
if not conf.CheckPkgConfig('gavl', 1.0):
|
||||
problems.append('Did not find Gmerlin Audio Video Lib [http://gmerlin.sourceforge.net/gavl.html].')
|
||||
else:
|
||||
|
|
|
|||
Loading…
Reference in a new issue