split 'libosmocore' from openbsc codebase

This library is intended to collect all generic/common funcitionality
of all Osmocom.org projects, including OpenBSC but also OsmocomBB

The library currently includes the following modules:

bitvec, comp128, gsm_utils, msgb, select, signal, statistics, talloc, timer,
tlv_parse, linuxlist

msgb allocation error debugging had to be temporarily disabled as it depends on
'debug.c' functionality which at the moment remains in OpenBSC
diff --git a/openbsc/src/Makefile.am b/openbsc/src/Makefile.am
index ba3d280..2edaf00 100644
--- a/openbsc/src/Makefile.am
+++ b/openbsc/src/Makefile.am
@@ -7,43 +7,43 @@
 noinst_HEADERS = vty/cardshell.h
 
 bscdir = $(libdir)
-bsc_LIBRARIES = liblaf0rge1.a libsccp.a
-
-liblaf0rge1_a_SOURCES = msgb.c timer.c talloc.c select.c signal.c debug.c
+bsc_LIBRARIES = libsccp.a
 
 libbsc_a_SOURCES = abis_rsl.c abis_nm.c gsm_data.c gsm_04_08_utils.c \
-		chan_alloc.c \
+		chan_alloc.c debug.c \
 		gsm_subscriber_base.c subchan_demux.c bsc_rll.c transaction.c \
-		trau_frame.c trau_mux.c paging.c e1_config.c e1_input.c tlv_parser.c \
-		input/misdn.c input/ipaccess.c signal.c gsm_utils.c \
-		talloc_ctx.c system_information.c bitvec.c rest_octets.c \
-		rtp_proxy.c statistics.c bts_siemens_bs11.c bts_ipaccess_nanobts.c \
+		trau_frame.c trau_mux.c paging.c e1_config.c e1_input.c \
+		input/misdn.c input/ipaccess.c \
+		talloc_ctx.c system_information.c rest_octets.c \
+		rtp_proxy.c bts_siemens_bs11.c bts_ipaccess_nanobts.c \
 		bts_unknown.c
 
 libmsc_a_SOURCES = gsm_subscriber.c db.c telnet_interface.c \
 		mncc.c gsm_04_08.c gsm_04_11.c transaction.c \
 		token_auth.c rrlp.c gsm_04_80.c ussd.c silent_call.c \
-		handover_logic.c handover_decision.c meas_rep.c comp128.c
+		handover_logic.c handover_decision.c meas_rep.c
 
 libvty_a_SOURCES = vty/buffer.c vty/command.c vty/vector.c vty/vty.c
 
 libsccp_a_SOURCES = sccp/sccp.c
 
 bsc_hack_SOURCES = bsc_hack.c bsc_init.c vty_interface.c vty_interface_layer3.c
-bsc_hack_LDADD = libmsc.a libbsc.a libmsc.a libvty.a liblaf0rge1.a -ldl -ldbi $(LIBCRYPT)
+bsc_hack_LDADD = libmsc.a libbsc.a libmsc.a libvty.a -losmocore -ldl -ldbi $(LIBCRYPT)
 
-bs11_config_SOURCES = bs11_config.c abis_nm.c gsm_data.c msgb.c debug.c \
-		      select.c timer.c rs232.c tlv_parser.c signal.c talloc.c \
-		      bts_siemens_bs11.c
+bs11_config_SOURCES = bs11_config.c abis_nm.c gsm_data.c debug.c \
+		      rs232.c bts_siemens_bs11.c
+bs11_config_LDADD = -losmocore
 
-ipaccess_find_SOURCES = ipaccess/ipaccess-find.c select.c timer.c
+ipaccess_find_SOURCES = ipaccess/ipaccess-find.c
+ipaccess_find_LDADD = -losmocore
 
 ipaccess_config_SOURCES = ipaccess/ipaccess-config.c ipaccess/ipaccess-firmware.c
-ipaccess_config_LDADD = libbsc.a libmsc.a libbsc.a libvty.a liblaf0rge1.a -ldl -ldbi $(LIBCRYPT)
+ipaccess_config_LDADD = libbsc.a libmsc.a libbsc.a libvty.a -losmocore -ldl -ldbi $(LIBCRYPT)
 
 isdnsync_SOURCES = isdnsync.c
 
-bsc_mgcp_SOURCES = mgcp/mgcp_main.c mgcp/mgcp_protocol.c msgb.c talloc.c debug.c select.c timer.c telnet_interface.c
-bsc_mgcp_LDADD = libvty.a liblaf0rge1.a
+bsc_mgcp_SOURCES = mgcp/mgcp_main.c mgcp/mgcp_protocol.c debug.c telnet_interface.c
+bsc_mgcp_LDADD = libvty.a -losmocore
 
-ipaccess_proxy_SOURCES = ipaccess/ipaccess-proxy.c msgb.c select.c talloc.c debug.c timer.c
+ipaccess_proxy_SOURCES = ipaccess/ipaccess-proxy.c debug.c
+ipaccess_proxy_LDADD = -losmocore