(trunk) #4732 "allow switching between internal and system libnatpmp" -- fixed with patch scarabeus and applied by me, so any patch breakage is probably mine... ;)
This commit is contained in:
parent
c56b12690c
commit
6d4858d8dd
|
@ -18,7 +18,7 @@ transmission_cli_SOURCES = cli.c
|
||||||
|
|
||||||
transmission_cli_LDADD = \
|
transmission_cli_LDADD = \
|
||||||
$(top_builddir)/libtransmission/libtransmission.a \
|
$(top_builddir)/libtransmission/libtransmission.a \
|
||||||
$(top_builddir)/third-party/libnatpmp/libnatpmp.a \
|
@LIBNATPMP_LIBS@ \
|
||||||
@LIBUPNP_LIBS@ \
|
@LIBUPNP_LIBS@ \
|
||||||
@DHT_LIBS@ \
|
@DHT_LIBS@ \
|
||||||
@LIBUTP_LIBS@ \
|
@LIBUTP_LIBS@ \
|
||||||
|
|
27
configure.ac
27
configure.ac
|
@ -309,6 +309,33 @@ AC_SUBST(LIBUPNP_LIBS)
|
||||||
AC_SUBST(LIBUPNP_LIBS_QT)
|
AC_SUBST(LIBUPNP_LIBS_QT)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
dnl ----------------------------------------------------------------------------
|
||||||
|
dnl
|
||||||
|
dnl Allow usage of system natpmp library
|
||||||
|
|
||||||
|
LIBNATPMP_CFLAGS="-I\$(top_srcdir)/third-party/libnatpmp/"
|
||||||
|
LIBNATPMP_LIBS="\$(top_builddir)/third-party/libnatpmp/libnatpmp.a"
|
||||||
|
LIBNATPMP_LIBS_QT="\$\${TRANSMISSION_TOP}/third-party/libnatpmp/libnatpmp.a"
|
||||||
|
build_bundled_natpmp="yes"
|
||||||
|
AC_ARG_ENABLE([external-natpmp],
|
||||||
|
AS_HELP_STRING([--enable-external-natpmp],[Use system external-natpmp]),
|
||||||
|
[want_external_natpmp=${enableval}],
|
||||||
|
[want_external_natpmp=no])
|
||||||
|
if test "x$want_external_natpmp" != "xno" ; then
|
||||||
|
dnl Would be lovely if it had pkgconfig
|
||||||
|
LIBNATPMP_CFLAGS=""
|
||||||
|
LIBNATPMP_LIBS="-lnatpmp"
|
||||||
|
LIBNATPMP_LIBS_QT="-lnatpmp"
|
||||||
|
build_bundled_natpmp="no"
|
||||||
|
fi
|
||||||
|
AM_CONDITIONAL([BUILD_NATPMP],[test "x$build_bundled_natpmp" = "xyes"])
|
||||||
|
AC_SUBST(LIBNATPMP_CFLAGS)
|
||||||
|
AC_SUBST(LIBNATPMP_LIBS)
|
||||||
|
AC_SUBST(LIBNATPMP_LIBS_QT)
|
||||||
|
|
||||||
|
|
||||||
dnl ----------------------------------------------------------------------------
|
dnl ----------------------------------------------------------------------------
|
||||||
dnl
|
dnl
|
||||||
dnl detection for the GTK+ client
|
dnl detection for the GTK+ client
|
||||||
|
|
|
@ -21,7 +21,7 @@ bin_PROGRAMS = \
|
||||||
LDADD = \
|
LDADD = \
|
||||||
$(top_builddir)/libtransmission/libtransmission.a \
|
$(top_builddir)/libtransmission/libtransmission.a \
|
||||||
@LIBUPNP_LIBS@ \
|
@LIBUPNP_LIBS@ \
|
||||||
$(top_builddir)/third-party/libnatpmp/libnatpmp.a \
|
@LIBNATPMP_LIBS@ \
|
||||||
@DHT_LIBS@ \
|
@DHT_LIBS@ \
|
||||||
@LIBUTP_LIBS@ \
|
@LIBUTP_LIBS@ \
|
||||||
@LIBEVENT_LIBS@ \
|
@LIBEVENT_LIBS@ \
|
||||||
|
|
|
@ -85,7 +85,7 @@ dist_man_MANS = transmission-gtk.1
|
||||||
transmission_gtk_LDADD = \
|
transmission_gtk_LDADD = \
|
||||||
$(top_builddir)/libtransmission/libtransmission.a \
|
$(top_builddir)/libtransmission/libtransmission.a \
|
||||||
@LIBUPNP_LIBS@ \
|
@LIBUPNP_LIBS@ \
|
||||||
$(top_builddir)/third-party/libnatpmp/libnatpmp.a \
|
@LIBNATPMP_LIBS@ \
|
||||||
@DHT_LIBS@ \
|
@DHT_LIBS@ \
|
||||||
@LIBUTP_LIBS@ \
|
@LIBUTP_LIBS@ \
|
||||||
@GTK_LIBS@ \
|
@GTK_LIBS@ \
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
AM_CPPFLAGS = \
|
AM_CPPFLAGS = \
|
||||||
-I. \
|
|
||||||
-I$(top_srcdir) \
|
-I$(top_srcdir) \
|
||||||
-I$(top_srcdir)/third-party/ \
|
|
||||||
-D__TRANSMISSION__ \
|
-D__TRANSMISSION__ \
|
||||||
-DPACKAGE_DATA_DIR=\""$(datadir)"\"
|
-DPACKAGE_DATA_DIR=\""$(datadir)"\"
|
||||||
|
|
||||||
|
@ -9,6 +7,7 @@ AM_CFLAGS = \
|
||||||
@DHT_CFLAGS@ \
|
@DHT_CFLAGS@ \
|
||||||
@LIBUTP_CFLAGS@ \
|
@LIBUTP_CFLAGS@ \
|
||||||
@LIBUPNP_CFLAGS@ \
|
@LIBUPNP_CFLAGS@ \
|
||||||
|
@LIBNATPMP_CFLAGS@ \
|
||||||
@LIBEVENT_CFLAGS@ \
|
@LIBEVENT_CFLAGS@ \
|
||||||
@LIBCURL_CFLAGS@ \
|
@LIBCURL_CFLAGS@ \
|
||||||
@OPENSSL_CFLAGS@ \
|
@OPENSSL_CFLAGS@ \
|
||||||
|
@ -91,7 +90,7 @@ noinst_HEADERS = \
|
||||||
magnet.h \
|
magnet.h \
|
||||||
makemeta.h \
|
makemeta.h \
|
||||||
metainfo.h \
|
metainfo.h \
|
||||||
natpmp.h \
|
natpmp_local.h \
|
||||||
net.h \
|
net.h \
|
||||||
peer-common.h \
|
peer-common.h \
|
||||||
peer-io.h \
|
peer-io.h \
|
||||||
|
@ -141,7 +140,7 @@ apps_ldflags = \
|
||||||
apps_ldadd = \
|
apps_ldadd = \
|
||||||
./libtransmission.a \
|
./libtransmission.a \
|
||||||
@LIBUPNP_LIBS@ \
|
@LIBUPNP_LIBS@ \
|
||||||
$(top_builddir)/third-party/libnatpmp/libnatpmp.a \
|
@LIBNATPMP_LIBS@ \
|
||||||
@INTLLIBS@ \
|
@INTLLIBS@ \
|
||||||
@DHT_LIBS@ \
|
@DHT_LIBS@ \
|
||||||
@LIBUTP_LIBS@ \
|
@LIBUTP_LIBS@ \
|
||||||
|
|
|
@ -17,10 +17,10 @@
|
||||||
#include <event2/util.h> /* evutil_inet_ntop() */
|
#include <event2/util.h> /* evutil_inet_ntop() */
|
||||||
|
|
||||||
#define ENABLE_STRNATPMPERR
|
#define ENABLE_STRNATPMPERR
|
||||||
#include <libnatpmp/natpmp.h>
|
#include "natpmp.h"
|
||||||
|
|
||||||
#include "transmission.h"
|
#include "transmission.h"
|
||||||
#include "natpmp.h"
|
#include "natpmp_local.h"
|
||||||
#include "net.h" /* tr_netCloseSocket */
|
#include "net.h" /* tr_netCloseSocket */
|
||||||
#include "port-forwarding.h"
|
#include "port-forwarding.h"
|
||||||
#include "utils.h"
|
#include "utils.h"
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
* This exemption does not extend to derived works not owned by
|
* This exemption does not extend to derived works not owned by
|
||||||
* the Transmission project.
|
* the Transmission project.
|
||||||
*
|
*
|
||||||
* $Id$
|
* $Id: natpmp.h 12204 2011-03-22 15:19:54Z jordan $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef __TRANSMISSION__
|
#ifndef __TRANSMISSION__
|
|
@ -18,7 +18,7 @@
|
||||||
#include <event2/event.h>
|
#include <event2/event.h>
|
||||||
|
|
||||||
#include "transmission.h"
|
#include "transmission.h"
|
||||||
#include "natpmp.h"
|
#include "natpmp_local.h"
|
||||||
#include "net.h"
|
#include "net.h"
|
||||||
#include "peer-mgr.h"
|
#include "peer-mgr.h"
|
||||||
#include "port-forwarding.h"
|
#include "port-forwarding.h"
|
||||||
|
|
|
@ -4,10 +4,13 @@ endif
|
||||||
if BUILD_MINIUPNP
|
if BUILD_MINIUPNP
|
||||||
MINIUPNP_DIR = miniupnp
|
MINIUPNP_DIR = miniupnp
|
||||||
endif
|
endif
|
||||||
|
if BUILD_NATPMP
|
||||||
|
NATPMP_DIR = libnatpmp
|
||||||
|
endif
|
||||||
|
|
||||||
SUBDIRS = \
|
SUBDIRS = \
|
||||||
dht \
|
dht \
|
||||||
libnatpmp \
|
$(NATPMP_DIR) \
|
||||||
$(MINIUPNP_DIR) \
|
$(MINIUPNP_DIR) \
|
||||||
$(UTP_DIR)
|
$(UTP_DIR)
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ dist_man_MANS = \
|
||||||
transmission_create_LDADD = \
|
transmission_create_LDADD = \
|
||||||
$(top_builddir)/libtransmission/libtransmission.a \
|
$(top_builddir)/libtransmission/libtransmission.a \
|
||||||
@LIBUPNP_LIBS@ \
|
@LIBUPNP_LIBS@ \
|
||||||
$(top_builddir)/third-party/libnatpmp/libnatpmp.a \
|
@LIBNATPMP_LIBS@ \
|
||||||
@INTLLIBS@ \
|
@INTLLIBS@ \
|
||||||
@DHT_LIBS@ \
|
@DHT_LIBS@ \
|
||||||
@LIBUTP_LIBS@ \
|
@LIBUTP_LIBS@ \
|
||||||
|
|
Loading…
Reference in New Issue