1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-25 09:13:06 +00:00

(trunk) #3230 "configure: libevent not found" -- honor user-specified LIBEVENT_CFLAGS and LIBEVENT_LDFLAGS arguments

This commit is contained in:
Charles Kerr 2010-05-25 19:46:28 +00:00
parent f3a5eed32b
commit 9b653523bb

View file

@ -202,15 +202,26 @@ AC_CHECK_LIB([rt],
[libevent_extra_libs="-lrt"], [libevent_extra_libs="-lrt"],
[libevent_extra_libs=""]) [libevent_extra_libs=""])
dnl libevent dnl libevent
AC_CHECK_LIB([event],[evutil_vsnprintf], dnl if the user specified LIBEVENT_LIBS or
[], if test -n "$LIBEVENT_LIBS"; then
[AC_MSG_ERROR(libevent not found!)], user_specified_libevent=yes
[$libevent_extra_libs]) elif test -n "$LIBEVENT_CFLAGS"; then
AC_CHECK_HEADER([event-config.h],[], user_specified_libevent=yes
[AC_MSG_ERROR(event-config.h not found!)]) fi
LIBEVENT_CFLAGS="" if test "x$user_specified_libevent" == "xyes"; then
LIBEVENT_LIBS="-levent $libevent_extra_libs" AC_MSG_NOTICE([Using user-specified LIBEVENT_LIBS and LIBEVENT_CFLAGS])
else
AC_CHECK_LIB([event],[evutil_vsnprintf],
[],
[AC_MSG_ERROR(libevent not found!)],
[$libevent_extra_libs])
AC_CHECK_HEADER([event-config.h],[],
[AC_MSG_ERROR(event-config.h not found!)])
LIBEVENT_CFLAGS=""
LIBEVENT_LIBS="-levent $libevent_extra_libs"
fi
AC_ARG_VAR([LIBEVENT_CFLAGS], [C compiler flags for LIBEVENT, overriding pkg-config])dnl AC_ARG_VAR([LIBEVENT_CFLAGS], [C compiler flags for LIBEVENT, overriding pkg-config])dnl
AC_ARG_VAR([LIBEVENT_LIBS], [linker flags for LIBEVENT, overriding pkg-config])dnl AC_ARG_VAR([LIBEVENT_LIBS], [linker flags for LIBEVENT, overriding pkg-config])dnl
@ -500,16 +511,14 @@ Configuration:
Build GTK+ client: ${build_gtk} Build GTK+ client: ${build_gtk}
dbus support: ${use_dbus_glib} Optional dependencies for GTK+ client:
gio for watchdir support: ${use_gio}
libnotify for 'download completed' popups: ${use_libnotify}
libcanberra for 'download completed' sounds: ${use_canberra}
gconf2 to tell GNOME we handle magnet links: ${use_gconf2}
libappindicator for Ubuntu-style system tray: ${use_libappindicator}
THESE ARE ALL OPTIONAL. If you're a packager * dbus support: ${use_dbus_glib}
or user who doesn't want these dependencies, * gio for watchdir support: ${use_gio}
use the ones you want and skip all the rest. * libnotify for 'download completed' popups: ${use_libnotify}
* libcanberra for 'download completed' sounds: ${use_canberra}
* gconf2 to register as a magnet link handler: ${use_gconf2}
* libappindicator for an Ubuntu-style tray: ${use_libappindicator}
Build Daemon: ${build_daemon} Build Daemon: ${build_daemon}