aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <holger@moiji-mobile.com>2013-10-06 13:34:43 +0200
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2013-10-06 13:37:08 +0200
commite58d33153dd2bed3629b9a09fd6add58f296bd6a (patch)
tree5b426114f8986229563cfc9768f1eb6005045b15
parent2bfc01dfd8830cf36bb8f7564604f7f357c0a0fb (diff)
ortp: Fix the version check for ORTP by not using the cached result
The second check used the cached result for ORTP. Store the result in ORTP_VERSION and my system properly detects that it is running on < 0.21. The HAVE_ORTP_021 will always be defined so just use #if and not the #ifdef to fix the build.
-rw-r--r--configure.ac2
-rw-r--r--src/trau/osmo_ortp.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index c285dad8..3dac5022 100644
--- a/configure.ac
+++ b/configure.ac
@@ -35,7 +35,7 @@ PKG_CHECK_MODULES(LIBOSMOVTY, libosmovty >= 0.3.0)
PKG_CHECK_MODULES(LIBOSMOGSM, libosmogsm >= 0.3.10)
PKG_CHECK_MODULES([ORTP], [ortp >= 0.13.1],
[
- PKG_CHECK_MODULES([ORTP], [ortp >= 0.21],
+ PKG_CHECK_MODULES([ORTP_VERSION], [ortp >= 0.21],
[AC_DEFINE(HAVE_ORTP_021, 1,
[libortp >= 0.21])],
[AC_DEFINE(HAVE_ORTP_021, 0,
diff --git a/src/trau/osmo_ortp.c b/src/trau/osmo_ortp.c
index 7dcff60c..2f2f26ca 100644
--- a/src/trau/osmo_ortp.c
+++ b/src/trau/osmo_ortp.c
@@ -349,7 +349,7 @@ struct osmo_rtp_socket *osmo_rtp_socket_create(void *talloc_ctx, unsigned int fl
int osmo_rtp_socket_bind(struct osmo_rtp_socket *rs, const char *ip, int port)
{
int rc;
-#ifdef HAVE_ORTP_021
+#if HAVE_ORTP_021
rc = rtp_session_set_local_addr(rs->sess, ip, port, port+1);
#else
rc = rtp_session_set_local_addr(rs->sess, ip, port);