mirror of
https://github.com/matrix-construct/construct
synced 2024-11-29 10:12:39 +01:00
Check for the -rpath linker flag.
This makes it build on MacOS X which neither supports nor needs this flag.
This commit is contained in:
parent
ac48b7c300
commit
794816af01
3 changed files with 14 additions and 2 deletions
11
configure.ac
11
configure.ac
|
@ -1020,6 +1020,17 @@ if test "$shared_modules" = yes; then
|
|||
fi
|
||||
fi
|
||||
|
||||
# rpath, for finding libratbox.so at run time
|
||||
hold_ldflags=$LDFLAGS
|
||||
AC_MSG_CHECKING(for the ld -rpath flag)
|
||||
LDFLAGS="${LDFLAGS} -Wl,-rpath=${libdir}"
|
||||
AC_LINK_IFELSE(AC_LANG_PROGRAM([],[int i;]), found=yes, found=no)
|
||||
LDFLAGS=$hold_ldflags
|
||||
AC_MSG_RESULT($found)
|
||||
if test "$found" = yes; then
|
||||
LDFLAGS="${LDFLAGS} -Wl,-rpath=\${libdir}"
|
||||
fi
|
||||
|
||||
# This must be down here, or it will mess up checks like the ones
|
||||
# for -Wl,-export-dynamic
|
||||
# -- jilles
|
||||
|
|
|
@ -33,7 +33,7 @@ PROGS = $(IRCD_EXE)
|
|||
SSL_LIBS = @SSL_LIBS@
|
||||
SSL_INCLUDES = @SSL_INCLUDES@
|
||||
|
||||
IRCDLIBS = @MODULES_LIBS@ -Wl,-rpath=@libdir@ -L../libratbox/src/.libs -lratbox @LIBS@ $(SSL_LIBS)
|
||||
IRCDLIBS = @MODULES_LIBS@ -L../libratbox/src/.libs -lratbox @LIBS@ $(SSL_LIBS)
|
||||
|
||||
INCLUDES = -I../include -I../libratbox/include $(SSL_INCLUDES)
|
||||
CPPFLAGS = ${INCLUDES} @CPPFLAGS@
|
||||
|
|
|
@ -20,13 +20,14 @@ RM = @RM@
|
|||
prefix = @prefix@
|
||||
exec_prefix = @exec_prefix@
|
||||
bindir = @bindir@
|
||||
libdir = @libdir@
|
||||
libexecdir = @libexecdir@
|
||||
confdir = @confdir@
|
||||
localstatedir = @localstatedir@
|
||||
|
||||
ZIP_LIB = @ZLIB_LD@
|
||||
|
||||
IRCDLIBS = @MODULES_LIBS@ -Wl,-rpath=@libdir@ -L../libratbox/src/.libs -lratbox @LIBS@ $(SSL_LIBS) $(ZIP_LIB)
|
||||
IRCDLIBS = @MODULES_LIBS@ -L../libratbox/src/.libs -lratbox @LIBS@ $(SSL_LIBS) $(ZIP_LIB)
|
||||
|
||||
INCLUDES = -I. -I../include -I../libratbox/include $(SSL_INCLUDES)
|
||||
CPPFLAGS = ${INCLUDES} @CPPFLAGS@
|
||||
|
|
Loading…
Reference in a new issue