2015-12-15 14:10:31 +00:00
|
|
|
SUBDIRS = hnbap rua ranap tests
|
|
|
|
|
2016-01-03 15:22:16 +00:00
|
|
|
# Build {hnbap,rua,ranap}_{encoder,decoder}.c using asn1tostruct
|
2015-12-15 14:10:31 +00:00
|
|
|
ASN1_ROOT = $(top_builddir)/asn1/
|
|
|
|
ASN1TOSTRUCT = $(ASN1_ROOT)/utils/asn1tostruct.py
|
2016-01-03 15:22:16 +00:00
|
|
|
BUILT_SOURCES = hnbap_decoder.c hnbap_encoder.c rua_decoder.c rua_encoder.c ranap_decoder.c ranap_encoder.c
|
|
|
|
|
2016-01-05 11:59:13 +00:00
|
|
|
hnbap_encoder.c hnbap_decoder.c hnbap_ies_defs.h: $(ASN1_ROOT)/hnbap/HNBAP-PDU-Contents.asn $(ASN1TOSTRUCT)
|
2016-01-03 15:22:16 +00:00
|
|
|
$(ASN1TOSTRUCT) -f $<
|
|
|
|
|
2016-01-05 11:59:13 +00:00
|
|
|
rua_encoder.c rua_decoder.c rua_ies_defs.h: $(ASN1_ROOT)/rua/RUA-PDU-Contents.asn $(ASN1TOSTRUCT)
|
2016-01-03 15:22:16 +00:00
|
|
|
$(ASN1TOSTRUCT) -p RUA_ -f $<
|
|
|
|
|
2016-01-05 14:19:44 +00:00
|
|
|
ranap_encoder.c ranap_decoder.c: $(ASN1_ROOT)/ranap/RANAP-PDU-Contents.asn $(ASN1TOSTRUCT)
|
2016-01-03 15:22:16 +00:00
|
|
|
$(ASN1TOSTRUCT) -p RANAP_ -f $<
|
2016-01-05 14:19:44 +00:00
|
|
|
mv ranap_ies_defs.h $(includedir)/osmocom/ranap/
|
|
|
|
# this is ugly ^. ranap_ies_defs.h is generated from asn1tostruct.py here, but
|
|
|
|
# it should live in include/osmocom/ranap/.
|
|
|
|
# We also need to replace the include in the newly generated .c files:
|
|
|
|
sed -i 's,^#include "ranap_ies_defs.h",#include <osmocom/ranap/ranap_ies_defs.h>,' ranap_encoder.c ranap_decoder.c
|
2016-01-06 18:53:48 +00:00
|
|
|
sed -i 's,^#include "ranap_common.h",#include <osmocom/ranap/ranap_common.h>,' ranap_encoder.c ranap_decoder.c
|
2015-12-15 14:10:31 +00:00
|
|
|
|
2016-01-04 17:03:31 +00:00
|
|
|
AM_CFLAGS = $(OSMOCORE_CFLAGS) $(OSMOVTY_CFLAGS) $(OSMOGSM_CFLAGS) $(OSMONETIF_CFLAGS) $(ASN1C_CFLAGS) $(OSMOSIGTRAN_CFLAGS) -I../include
|
2015-12-15 14:10:31 +00:00
|
|
|
COMMON_LDADD = -lsctp
|
|
|
|
|
2016-01-03 15:22:16 +00:00
|
|
|
# build the shared RANAP library
|
|
|
|
#
|
|
|
|
RANAP_LIBVERSION=0:0:0
|
2016-01-03 14:39:11 +00:00
|
|
|
lib_LTLIBRARIES = libosmo-ranap.la
|
|
|
|
libosmo_ranap_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(RANAP_LIBVERSION)
|
|
|
|
libosmo_ranap_la_LIBADD = $(OSMOCORE_LIBS) $(OSMOGSM_LIBS) $(ASN1C_LIBS) $(COMMON_LDADD) ranap/libosmo-asn1-ranap.la
|
2016-01-05 14:05:03 +00:00
|
|
|
libosmo_ranap_la_SOURCES = ranap_common.c ranap_encoder.c ranap_decoder.c ranap_msg_factory.c iu_helpers.c \
|
|
|
|
ranap_common_cn.c
|
2016-01-03 14:39:11 +00:00
|
|
|
|
2016-01-03 15:22:16 +00:00
|
|
|
# build the actual HomeNodeB gateway
|
|
|
|
#
|
|
|
|
bin_PROGRAMS = osmo-hnbgw
|
2015-12-22 11:21:16 +00:00
|
|
|
|
2016-01-03 15:22:16 +00:00
|
|
|
noinst_HEADERS = hnbap_common.h hnbap_ies_defs.h \
|
|
|
|
rua_common.h rua_ies_defs.h \
|
|
|
|
context_map.h hnbgw.h hnbgw_cn.h \
|
2016-01-03 16:54:24 +00:00
|
|
|
hnbgw_hnbap.h hnbgw_rua.h hnbgw_ranap.h \
|
|
|
|
sccp_helpers.h
|
2015-12-15 14:10:31 +00:00
|
|
|
|
2016-01-03 15:22:16 +00:00
|
|
|
osmo_hnbgw_SOURCES = hnbap_encoder.c hnbap_decoder.c hnbap_common.c \
|
|
|
|
rua_encoder.c rua_decoder.c rua_common.c \
|
2016-01-03 17:04:28 +00:00
|
|
|
rua_msg_factory.c sccp_helpers.c \
|
2016-01-03 15:22:16 +00:00
|
|
|
hnbgw.c hnbgw_hnbap.c hnbgw_rua.c hnbgw_ranap.c \
|
|
|
|
context_map.c hnbgw_cn.c
|
2015-12-15 14:10:31 +00:00
|
|
|
|
2016-01-03 15:22:16 +00:00
|
|
|
osmo_hnbgw_LDADD = $(OSMOCORE_LIBS) $(OSMOVTY_LIBS) $(OSMOGSM_LIBS) \
|
|
|
|
$(ASN1C_LIBS) $(OSMOSIGTRAN_LIBS) $(COMMON_LDADD) \
|
|
|
|
hnbap/libosmo-asn1-hnbap.a rua/libosmo-asn1-rua.a \
|
|
|
|
libosmo-ranap.la
|
2016-01-04 14:23:09 +00:00
|
|
|
|
|
|
|
|
|
|
|
regen: regenerate-from-asn1-source
|
|
|
|
|
|
|
|
regenerate-from-asn1-source:
|
|
|
|
make -C hnbap regen
|
|
|
|
make -C ranap regen
|
|
|
|
make -C rua regen
|