Commit 562089b5 authored by Alexandre Julliard's avatar Alexandre Julliard

Link with libdl only where needed.

parent 8ae5761d
......@@ -113,11 +113,13 @@ AC_CHECK_FUNCS(openpty,,
LIBS="$LIBS -lutil"]
)])
DLLIBS=""
AC_SUBST(DLLIBS)
AC_CHECK_HEADERS(dlfcn.h,
[AC_CHECK_FUNCS(dlopen,,
[AC_CHECK_LIB(dl,dlopen,
[AC_DEFINE(HAVE_DLOPEN,1,[Define if you have dlopen])
LIBS="$LIBS -ldl"],
DLLIBS="-ldl"],
LIBEXT="a")]
)],
LIBEXT="a"
......
......@@ -7,6 +7,7 @@ LIBEXT = @LIBEXT@
MODULE = none
SOVERSION = 1.0
SONAME = libwine.so
EXTRALIBS = @DLLIBS@
C_SRCS = \
debug.c \
......@@ -20,7 +21,7 @@ all: libwine.$(LIBEXT)
@MAKE_RULES@
libwine.so.$(SOVERSION): $(OBJS)
$(LDSHARED) $(OBJS) $(LIBS) -o $@
$(LDSHARED) $(OBJS) $(EXTRALIBS) $(LIBS) -o $@
libwine.so: libwine.so.$(SOVERSION)
$(RM) $@ && $(LN_S) libwine.so.$(SOVERSION) $@
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment