Discussion:
libosmo-netif: build system cleanups
Jan Engelhardt
2014-10-02 22:03:43 UTC
Permalink
The following changes since commit 603f6c40d55b87f81fbd8ff1ad7b9568f3b962ff:

build: rename INCLUDES to AM_CPPFLAGS in Makefile.am to avoid warnings (2014-09-11 18:22:02 +0200)

are available in the git repository at:

git://git.inai.de/libosmo-netif HEAD

for you to fetch changes up to 226e99483234c100e5a18ea12838d98a3b091de6:

build: remove all_includes (2014-10-02 23:22:55 +0200)

----------------------------------------------------------------
Jan Engelhardt (2):
build: put dependency libraries in the right place in Makefiles
build: remove all_includes

Makefile.am | 1 -
examples/Makefile.am | 2 +-
examples/channel/Makefile.am | 2 +-
src/Makefile.am | 6 +++---
src/channel/abis/Makefile.am | 5 +++--
tests/Makefile.am | 2 +-
tests/osmo-pcap-test/Makefile.am | 2 +-
7 files changed, 10 insertions(+), 10 deletions(-)
Jan Engelhardt
2014-10-02 22:03:45 UTC
Permalink
This variable is never set and could therefore be removed.
---
Makefile.am | 1 -
examples/Makefile.am | 2 +-
examples/channel/Makefile.am | 2 +-
src/Makefile.am | 2 +-
src/channel/abis/Makefile.am | 2 +-
tests/Makefile.am | 2 +-
6 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index c8a05a3..519d1ae 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,7 +1,6 @@
AUTOMAKE_OPTIONS = foreign dist-bzip2 1.6
ACLOCAL_AMFLAGS = -I m4

-AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/include
SUBDIRS = include src examples tests

pkgconfigdir = $(libdir)/pkgconfig
diff --git a/examples/Makefile.am b/examples/Makefile.am
index f8cfc8f..ddfaa48 100644
--- a/examples/Makefile.am
+++ b/examples/Makefile.am
@@ -1,4 +1,4 @@
-AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/include
+AM_CPPFLAGS = -I$(top_srcdir)/include
AM_CFLAGS=-Wall -g $(LIBOSMOCORE_CFLAGS) $(LIBOSMOGSM_CFLAGS) $(LIBOSMOABIS_CFLAGS) $(COVERAGE_CFLAGS)
AM_LDFLAGS = $(COVERAGE_LDFLAGS)

diff --git a/examples/channel/Makefile.am b/examples/channel/Makefile.am
index 4191c94..c417909 100644
--- a/examples/channel/Makefile.am
+++ b/examples/channel/Makefile.am
@@ -1,4 +1,4 @@
-AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/include
+AM_CPPFLAGS = -I$(top_srcdir)/include
AM_CFLAGS=-Wall -g $(LIBOSMOCORE_CFLAGS) $(LIBOSMOGSM_CFLAGS) $(LIBOSMOABIS_CFLAGS) $(COVERAGE_CFLAGS)
AM_LDFLAGS = $(COVERAGE_LDFLAGS)

diff --git a/src/Makefile.am b/src/Makefile.am
index ca40152..7fbdaf2 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -2,7 +2,7 @@
# Please read Chapter 6 "Library interface versions" of the libtool documentation before making any modification
LIBVERSION=2:0:0

-AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/include -I$(top_builddir)
+AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_builddir)
AM_CFLAGS= -fPIC -Wall $(LIBOSMOCORE_CFLAGS) $(LIBOSMOGSM_CFLAGS) $(LIBOSMOVTY_CFLAGS) $(COVERAGE_CFLAGS)
AM_LDFLAGS = $(COVERAGE_LDFLAGS)

diff --git a/src/channel/abis/Makefile.am b/src/channel/abis/Makefile.am
index 7b744f2..9ccce1d 100644
--- a/src/channel/abis/Makefile.am
+++ b/src/channel/abis/Makefile.am
@@ -1,4 +1,4 @@
-AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/include -I$(top_builddir)
+AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_builddir)
AM_CFLAGS= -fPIC -Wall $(LIBOSMOCORE_CFLAGS) $(LIBOSMOGSM_CFLAGS) $(LIBOSMOVTY_CFLAGS) $(COVERAGE_CFLAGS)
AM_LDFLAGS = $(COVERAGE_LDFLAGS)

diff --git a/tests/Makefile.am b/tests/Makefile.am
index 0c1fed3..a986940 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -1,4 +1,4 @@
-AM_CFLAGS = -Wall $(all_includes) -I$(top_srcdir)/include $(LIBOSMOCORE_CFLAGS)
+AM_CFLAGS = -Wall -I$(top_srcdir)/include $(LIBOSMOCORE_CFLAGS)
AM_LDFLAGS = $(LIBOSMOCORE_LDFLAGS)

check_PROGRAMS = osmux/osmux_test
--
2.0.0
Jan Engelhardt
2014-10-02 22:03:44 UTC
Permalink
Libs must be in _LDADD/_LIBADD and not in _LDFLAGS.
---
src/Makefile.am | 4 ++--
src/channel/abis/Makefile.am | 3 ++-
tests/osmo-pcap-test/Makefile.am | 2 +-
3 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/src/Makefile.am b/src/Makefile.am
index 8b4b58e..ca40152 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -4,13 +4,13 @@ LIBVERSION=2:0:0

AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/include -I$(top_builddir)
AM_CFLAGS= -fPIC -Wall $(LIBOSMOCORE_CFLAGS) $(LIBOSMOGSM_CFLAGS) $(LIBOSMOVTY_CFLAGS) $(COVERAGE_CFLAGS)
-AM_LDFLAGS = $(LIBOSMOCORE_LIBS) $(LIBOSMOGSM_LIBS) $(LIBOSMOVTY_LIBS) $(COVERAGE_LDFLAGS)
+AM_LDFLAGS = $(COVERAGE_LDFLAGS)

SUBDIRS = channel

lib_LTLIBRARIES = libosmonetif.la

-libosmonetif_la_LIBADD = channel/abis/libosmonetif-abis.la
+libosmonetif_la_LIBADD = channel/abis/libosmonetif-abis.la $(LIBOSMOCORE_LIBS) $(LIBOSMOGSM_LIBS) $(LIBOSMOVTY_LIBS)
libosmonetif_la_LDFLAGS = -version-info $(LIBVERSION) -no-undefined

libosmonetif_la_SOURCES = amr.c \
diff --git a/src/channel/abis/Makefile.am b/src/channel/abis/Makefile.am
index e4d93a3..7b744f2 100644
--- a/src/channel/abis/Makefile.am
+++ b/src/channel/abis/Makefile.am
@@ -1,8 +1,9 @@
AM_CPPFLAGS = $(all_includes) -I$(top_srcdir)/include -I$(top_builddir)
AM_CFLAGS= -fPIC -Wall $(LIBOSMOCORE_CFLAGS) $(LIBOSMOGSM_CFLAGS) $(LIBOSMOVTY_CFLAGS) $(COVERAGE_CFLAGS)
-AM_LDFLAGS = $(LIBOSMOCORE_LIBS) $(LIBOSMOGSM_LIBS) $(LIBOSMOVTY_LIBS) $(COVERAGE_LDFLAGS)
+AM_LDFLAGS = $(COVERAGE_LDFLAGS)

noinst_LTLIBRARIES = libosmonetif-abis.la

libosmonetif_abis_la_SOURCES = ipa_stream_server.c \
ipa_stream_client.c
+libosmonetif_abis_la_LIBADD = $(LIBOSMOCORE_LIBS) $(LIBOSMOGSM_LIBS) $(LIBOSMOVTY_LIBS)
diff --git a/tests/osmo-pcap-test/Makefile.am b/tests/osmo-pcap-test/Makefile.am
index 0be6fc4..a256005 100644
--- a/tests/osmo-pcap-test/Makefile.am
+++ b/tests/osmo-pcap-test/Makefile.am
@@ -9,6 +9,6 @@ osmo_pcap_test_SOURCES = proto.c \
osmux_test.c \
pcap.c

-osmo_pcap_test_LDFLAGS = -lpcap \
+osmo_pcap_test_LDADD = -lpcap \
-losmocore \
-losmonetif
--
2.0.0
Loading...