Browse Source

check if we need -ldl to get dlopen

git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-merge-1.4.x@864 152afb58-edef-0310-8abb-c4023f1b3aa9
svn/tags/lighttpd-1.4.8
Jan Kneschke 16 years ago
parent
commit
230e670078
  1. 11
      SConstruct
  2. 2
      src/SConscript

11
SConstruct

@ -92,13 +92,13 @@ opts.AddOptions(
env = Environment(
env = os.environ,
options = opts,
CCFLAGS = Split('-Wall -O2 -g -W -pedantic -Wunused -Wshadow'),
CPPPATH = Split('#/build'),
# LIBS = [ 'dl' ]
CPPPATH = Split('#/build')
)
env['package'] = package
env['version'] = version
if env['CC'] == 'gcc':
env.Append(CCFLAGS = Split('-Wall -O2 -g -W -pedantic -Wunused -Wshadow -std=gnu99'))
# cache configure checks
if 1:
@ -153,7 +153,7 @@ if 1:
autoconf.env.Append( LIBSQLITE3 = '', LIBXML2 = '', LIBMYSQL = '', LIBZ = '',
LIBBZ2 = '', LIBCRYPT = '', LIBMEMCACHE = '', LIBFCGI = '',
LIBLDAP = '', LIBLBER = '', LIBLUA = '')
LIBLDAP = '', LIBLBER = '', LIBLUA = '', LIBDL = '')
if env['with_fam']:
if autoconf.CheckLibWithHeader('fam', 'fam.h', 'C'):
@ -195,6 +195,9 @@ if 1:
if autoconf.CheckLibWithHeader('fcgi', 'fastcgi.h', 'C'):
autoconf.env.Append(LIBFCGI = 'fcgi')
if autoconf.CheckLibWithHeader('dl', 'dlfcn.h', 'C'):
autoconf.env.Append(LIBDL = 'dl')
if autoconf.CheckType('socklen_t', '#include <unistd.h>\n#include <sys/socket.h>\n#include <sys/types.h>'):
autoconf.env.Append(CPPFLAGS = [ '-DHAVE_SOCKLEN_T' ])

2
src/SConscript

@ -45,7 +45,7 @@ else:
else:
bin_linkflags += [ '-Wl,--export-dynamic' ]
instbin = env.Program(bin_targets, src, LINKFLAGS = bin_linkflags, LIBS= [ env['LIBS'], common_lib ])
instbin = env.Program(bin_targets, src, LINKFLAGS = bin_linkflags, LIBS= [ env['LIBS'], common_lib, env['LIBDL'] ])
env.Depends(instbin, configparser)
spawn_fcgi = env.Program("spawn-fcgi", "spawn-fcgi.c")

Loading…
Cancel
Save