move asn1 headers to include/ dir (1/5)
Add move-asn1-header-files.sh to do header file moving and sed'ding the include
statements. The file moving part is disabled until a later commit, to make
reading the diffs easier.
Call shell script from src/{hnbap,ranap,rua}/Makefile.am regen targets.
Add convenience regen target to src/Makefile.am, calling regen in the three subdirs.
This change is split over several commits to ease diff reading. Subsequent
commits show, in steps:
- the "unmoved" effect of sed,
- header moves,
- adjust build system and include statements.
diff --git a/src/hnbap/Makefile.am b/src/hnbap/Makefile.am
index 0362871..274a30b 100644
--- a/src/hnbap/Makefile.am
+++ b/src/hnbap/Makefile.am
@@ -232,7 +232,7 @@
PrivateMessage.h \
IE.h
-AM_CFLAGS = $(ASN1C_CFLAGS) $(OSMOCORE_CFLAGS) -I.
+AM_CFLAGS = $(ASN1C_CFLAGS) $(OSMOCORE_CFLAGS) -I../../include
noinst_LIBRARIES=libosmo-asn1-hnbap.a
libosmo_asn1_hnbap_a_SOURCES=$(ASN_MODULE_SOURCES)
@@ -244,4 +244,6 @@
regenerate-from-asn1-source:
asn1c -gen-PER -fnative-types ../../asn1/hnbap/HNBAP-CommonDataTypes.asn ../../asn1/hnbap/HNBAP-Constants.asn ../../asn1/hnbap/HNBAP-IEs.asn ../../asn1/hnbap/HNBAP-PDU.asn
# remove the local copy of the runtime code
- @rm ANY.* BOOLEAN.* INTEGER.* NativeEnumerated.* NativeInteger.* OBJECT_IDENTIFIER.* asn_* OCTET_STRING.* converter-sample.c per_* xer_* constr* der_* ber_* BIT_STRING.*
+ -rm ANY.* BOOLEAN.* INTEGER.* NativeEnumerated.* NativeInteger.* OBJECT_IDENTIFIER.* asn_* OCTET_STRING.* converter-sample.c per_* xer_* constr* der_* ber_* BIT_STRING.*
+# change include style to `#include <dir/foo.h>'
+ ../../move-asn1-header-files.sh osmocom/osmo-iuh/hnbap $(ASN_MODULE_INC)