summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@gnumonks.org>2011-07-05 20:17:12 +0200
committerPablo Neira Ayuso <pablo@gnumonks.org>2011-07-05 20:17:12 +0200
commit0c3e9bd3666bbf8c87baf73f20d4604121fe2768 (patch)
tree7596a65555c00a995997e318efda6deea37534cb
parentef8fc3bf28634d361adeec5490f807efb0ab3341 (diff)
src: use standalone libtallocpablo/talloc
With this patch, we check for the libtalloc version installed in the system. We don't use our own copy in libosmocore anymore. This patch also replaces all references to: by: I did this with this command: find ./ -type f -exec sed -i "s/osmocom\/core\/talloc.h/talloc.h/g" {} \; Make sure you skip .git directory in this replacement, otherwise you'll get a corrupted git repository.
-rw-r--r--configure.ac1
-rw-r--r--src/Makefile.am2
-rw-r--r--src/m2ua_msg.c2
-rw-r--r--src/sccp.c2
4 files changed, 4 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index b16b1f3..e0b1ccb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -15,6 +15,7 @@ AC_PROG_INSTALL
AC_PROG_RANLIB
PKG_CHECK_MODULES(LIBOSMOCORE, libosmocore >= 0.3.0)
+PKG_CHECK_MODULES(LIBTALLOC, talloc >= 2.0.1)
# The following test is taken from WebKit's webkit.m4
saved_CFLAGS="$CFLAGS"
diff --git a/src/Makefile.am b/src/Makefile.am
index c7451ad..2154889 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,5 +1,5 @@
INCLUDES = $(all_includes) -I$(top_srcdir)/include -I$(top_builddir)
-AM_CFLAGS=-Wall $(LIBOSMOCORE_CFLAGS)
+AM_CFLAGS=-Wall $(LIBOSMOCORE_CFLAGS) $(LIBTALLOC_CFLAGS)
sccpdir = $(libdir)
sccp_LIBRARIES = libsccp.a libmtp.a libm2ua.a
diff --git a/src/m2ua_msg.c b/src/m2ua_msg.c
index c04586f..6156a71 100644
--- a/src/m2ua_msg.c
+++ b/src/m2ua_msg.c
@@ -20,7 +20,7 @@
#include <osmocom/core/msgb.h>
#include <osmocom/core/logging.h>
-#include <osmocom/core/talloc.h>
+#include <talloc.h>
#include <arpa/inet.h>
diff --git a/src/sccp.c b/src/sccp.c
index e061d37..9af36fb 100644
--- a/src/sccp.c
+++ b/src/sccp.c
@@ -25,7 +25,7 @@
#include <string.h>
#include <osmocom/core/msgb.h>
-#include <osmocom/core/talloc.h>
+#include <talloc.h>
#include <osmocom/core/logging.h>
#include <osmocom/gsm/tlv.h>