summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2020-06-09 18:19:07 +0200
committerGravatar Martin Szulecki2020-06-09 18:19:07 +0200
commitc14849987d893999c03f165b49257e108d07bad3 (patch)
treee9e8769873b113494958b669700ce107b132a644
parent65a7ffbfb124c2a0acf94b5e88911d6bf95d6009 (diff)
downloadlibplist-c14849987d893999c03f165b49257e108d07bad3.tar.gz
libplist-c14849987d893999c03f165b49257e108d07bad3.tar.bz2
Unfold automake variables into multiple lines for maintainability
-rw-r--r--Makefile.am2
-rw-r--r--cython/Makefile.am36
-rw-r--r--fuzz/Makefile.am11
-rw-r--r--include/Makefile.am29
-rw-r--r--libcnary/Makefile.am17
-rw-r--r--src/Makefile.am83
-rw-r--r--test/Makefile.am18
-rw-r--r--tools/Makefile.am5
8 files changed, 129 insertions, 72 deletions
diff --git a/Makefile.am b/Makefile.am
index a46e047..b9a1a52 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,9 +1,11 @@
AUTOMAKE_OPTIONS = foreign
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = libcnary src include tools test docs
+
if HAVE_CYTHON
SUBDIRS += cython
endif
+
if BUILD_FUZZERS
SUBDIRS += fuzz
endif
diff --git a/cython/Makefile.am b/cython/Makefile.am
index bce8121..3c70dc9 100644
--- a/cython/Makefile.am
+++ b/cython/Makefile.am
@@ -3,22 +3,42 @@ AM_CPPFLAGS = -I$(top_srcdir)/include
AM_CFLAGS = $(GLOBAL_CFLAGS)
AM_LDFLAGS = $(GLOBAL_LDFLAGS)
-EXTRA_DIST = plist.pyx plist.pxd
+EXTRA_DIST = \
+ plist.pyx \
+ plist.pxd
if HAVE_CYTHON
BUILT_SOURCES = plist.c
-PXDINCLUDES = plist.pxd $(CYTHON_PLIST_INCLUDE_DIR)/plist.pxd
-CLEANFILES = \
- *.pyc \
- *.pyo \
- plist.c
+PXDINCLUDES = \
+ plist.pxd \
+ $(CYTHON_PLIST_INCLUDE_DIR)/plist.pxd
+
+CLEANFILES = \
+ *.pyc \
+ *.pyo \
+ plist.c
plistdir = $(pyexecdir)
plist_LTLIBRARIES = plist.la
-plist_la_SOURCES = plist_util.c plist_util.h plist.pyx
-plist_la_CFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/src $(PYTHON_CPPFLAGS) $(AM_CFLAGS) -Wno-shadow -Wno-redundant-decls -Wno-switch-default -Wno-strict-aliasing -Wno-implicit-function-declaration -fvisibility=default
+plist_la_SOURCES = \
+ plist_util.c \
+ plist_util.h \
+ plist.pyx
+
+plist_la_CFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_srcdir)/src \
+ $(PYTHON_CPPFLAGS) \
+ $(AM_CFLAGS) \
+ -Wno-shadow \
+ -Wno-redundant-decls \
+ -Wno-switch-default \
+ -Wno-strict-aliasing \
+ -Wno-implicit-function-declaration \
+ -fvisibility=default
+
plist_la_LDFLAGS = -module -avoid-version $(PYTHON_LIBS) $(AM_LDFLAGS)
plist_la_LIBADD = $(top_builddir)/src/libplist.la
diff --git a/fuzz/Makefile.am b/fuzz/Makefile.am
index b9798f9..a8ef294 100644
--- a/fuzz/Makefile.am
+++ b/fuzz/Makefile.am
@@ -19,7 +19,9 @@ LIBFUZZER_SRC:
CLEANFILES = libFuzzer.a
-noinst_PROGRAMS = xplist_fuzzer bplist_fuzzer
+noinst_PROGRAMS = \
+ xplist_fuzzer \
+ bplist_fuzzer
xplist_fuzzer_SOURCES = xplist_fuzzer.cc
xplist_fuzzer_LDFLAGS = -static
@@ -31,6 +33,11 @@ bplist_fuzzer_LDADD = $(top_builddir)/src/libplist.la libFuzzer.a
TESTS = fuzzers.test
-EXTRA_DIST = bplist.dict xplist.dict init-fuzzers.sh test-fuzzers.sh fuzzers.test
+EXTRA_DIST = \
+ bplist.dict \
+ xplist.dict \
+ init-fuzzers.sh \
+ test-fuzzers.sh \
+ fuzzers.test
endif
diff --git a/include/Makefile.am b/include/Makefile.am
index 4e4db2e..2fa500e 100644
--- a/include/Makefile.am
+++ b/include/Makefile.am
@@ -1,14 +1,15 @@
-nobase_include_HEADERS = plist/plist.h \
- plist/plist++.h \
- plist/Array.h \
- plist/Boolean.h \
- plist/Data.h \
- plist/Date.h \
- plist/Dictionary.h \
- plist/Integer.h \
- plist/Key.h \
- plist/Node.h \
- plist/Real.h \
- plist/String.h \
- plist/Structure.h \
- plist/Uid.h
+nobase_include_HEADERS = \
+ plist/plist.h \
+ plist/plist++.h \
+ plist/Array.h \
+ plist/Boolean.h \
+ plist/Data.h \
+ plist/Date.h \
+ plist/Dictionary.h \
+ plist/Integer.h \
+ plist/Key.h \
+ plist/Node.h \
+ plist/Real.h \
+ plist/String.h \
+ plist/Structure.h \
+ plist/Uid.h
diff --git a/libcnary/Makefile.am b/libcnary/Makefile.am
index e2187ec..f5c7bc9 100644
--- a/libcnary/Makefile.am
+++ b/libcnary/Makefile.am
@@ -1,12 +1,15 @@
-AM_CFLAGS = $(GLOBAL_CFLAGS) -I$(top_srcdir)/libcnary/include
+AM_CFLAGS = \
+ $(GLOBAL_CFLAGS) \
+ -I$(top_srcdir)/libcnary/include
+
AM_LDFLAGS =
noinst_LTLIBRARIES = libcnary.la
-libcnary_la_LIBADD =
+libcnary_la_LIBADD =
libcnary_la_LDFLAGS = $(AM_LDFLAGS) -no-undefined
libcnary_la_SOURCES = \
- node.c \
- node_list.c \
- include/node.h \
- include/node_list.h \
- include/object.h
+ node.c \
+ node_list.c \
+ include/node.h \
+ include/node_list.h \
+ include/object.h
diff --git a/src/Makefile.am b/src/Makefile.am
index 7fe500a..02b0478 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,47 +1,56 @@
-AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir) -I$(top_srcdir)/libcnary/include
+AM_CPPFLAGS = \
+ -I$(top_srcdir)/include \
+ -I$(top_srcdir) \
+ -I$(top_srcdir)/libcnary/include
AM_CFLAGS = $(GLOBAL_CFLAGS)
AM_LDFLAGS = $(GLOBAL_LDFLAGS)
-lib_LTLIBRARIES = libplist.la libplist++.la
+lib_LTLIBRARIES = \
+ libplist.la \
+ libplist++.la
+
libplist_la_LIBADD = $(top_builddir)/libcnary/libcnary.la
libplist_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LIBPLIST_SO_VERSION) -no-undefined
-libplist_la_SOURCES = base64.c base64.h \
- bytearray.c bytearray.h \
- strbuf.h \
- hashtable.c hashtable.h \
- ptrarray.c ptrarray.h \
- time64.c time64.h time64_limits.h \
- xplist.c \
- bplist.c \
- plist.c plist.h
+libplist_la_SOURCES = \
+ base64.c base64.h \
+ bytearray.c bytearray.h \
+ strbuf.h \
+ hashtable.c hashtable.h \
+ ptrarray.c ptrarray.h \
+ time64.c time64.h \
+ time64_limits.h \
+ xplist.c \
+ bplist.c \
+ plist.c plist.h
libplist___la_LIBADD = libplist.la
libplist___la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LIBPLIST_SO_VERSION) -no-undefined
-libplist___la_SOURCES = Node.cpp \
- Structure.cpp \
- Array.cpp \
- Boolean.cpp \
- Data.cpp \
- Date.cpp \
- Dictionary.cpp \
- Integer.cpp \
- Key.cpp \
- Real.cpp \
- String.cpp \
- Uid.cpp \
- $(top_srcdir)/include/plist/Node.h \
- $(top_srcdir)/include/plist/Structure.h \
- $(top_srcdir)/include/plist/Array.h \
- $(top_srcdir)/include/plist/Boolean.h \
- $(top_srcdir)/include/plist/Data.h \
- $(top_srcdir)/include/plist/Date.h \
- $(top_srcdir)/include/plist/Dictionary.h \
- $(top_srcdir)/include/plist/Integer.h \
- $(top_srcdir)/include/plist/Key.h \
- $(top_srcdir)/include/plist/Real.h \
- $(top_srcdir)/include/plist/String.h \
- $(top_srcdir)/include/plist/Uid.h
+libplist___la_SOURCES = \
+ Node.cpp \
+ Structure.cpp \
+ Array.cpp \
+ Boolean.cpp \
+ Data.cpp \
+ Date.cpp \
+ Dictionary.cpp \
+ Integer.cpp \
+ Key.cpp \
+ Real.cpp \
+ String.cpp \
+ Uid.cpp \
+ $(top_srcdir)/include/plist/Node.h \
+ $(top_srcdir)/include/plist/Structure.h \
+ $(top_srcdir)/include/plist/Array.h \
+ $(top_srcdir)/include/plist/Boolean.h \
+ $(top_srcdir)/include/plist/Data.h \
+ $(top_srcdir)/include/plist/Date.h \
+ $(top_srcdir)/include/plist/Dictionary.h \
+ $(top_srcdir)/include/plist/Integer.h \
+ $(top_srcdir)/include/plist/Key.h \
+ $(top_srcdir)/include/plist/Real.h \
+ $(top_srcdir)/include/plist/String.h \
+ $(top_srcdir)/include/plist/Uid.h
if WIN32
libplist_la_LDFLAGS += -avoid-version -static-libgcc
@@ -49,4 +58,6 @@ libplist___la_LDFLAGS += -avoid-version -static-libgcc
endif
pkgconfigdir = $(libdir)/pkgconfig
-pkgconfig_DATA = libplist-2.0.pc libplist++-2.0.pc
+pkgconfig_DATA = \
+ libplist-2.0.pc \
+ libplist++-2.0.pc
diff --git a/test/Makefile.am b/test/Makefile.am
index 4519de0..2f5e1b9 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -1,10 +1,18 @@
-AM_CFLAGS = $(GLOBAL_CFLAGS) -I$(top_srcdir)/include -I$(top_srcdir)/libcnary/include
+AM_CFLAGS = \
+ $(GLOBAL_CFLAGS) \
+ -I$(top_srcdir)/include \
+ -I$(top_srcdir)/libcnary/include
+
AM_LDFLAGS =
-noinst_PROGRAMS = plist_cmp plist_test
+noinst_PROGRAMS = \
+ plist_cmp \
+ plist_test
plist_cmp_SOURCES = plist_cmp.c
-plist_cmp_LDADD = $(top_builddir)/src/libplist.la $(top_builddir)/libcnary/libcnary.la
+plist_cmp_LDADD = \
+ $(top_builddir)/src/libplist.la \
+ $(top_builddir)/libcnary/libcnary.la
plist_test_SOURCES = plist_test.c
plist_test_LDADD = $(top_builddir)/src/libplist.la
@@ -77,7 +85,9 @@ EXTRA_DIST = \
data/unsigned.bplist \
data/unsigned.plist
-TESTS_ENVIRONMENT = top_srcdir=$(top_srcdir) top_builddir=$(top_builddir)
+TESTS_ENVIRONMENT = \
+ top_srcdir=$(top_srcdir) \
+ top_builddir=$(top_builddir)
clean-local:
if test -d $(top_builddir)/test/data; then cd $(top_builddir)/test/data && rm -f *.out *.bin *.xml; fi
diff --git a/tools/Makefile.am b/tools/Makefile.am
index 67b7dd7..3b4e06c 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -1,4 +1,7 @@
-AM_CFLAGS = $(GLOBAL_CFLAGS) -I$(top_srcdir)/include
+AM_CFLAGS = \
+ $(GLOBAL_CFLAGS) \
+ -I$(top_srcdir)/include
+
AM_LDFLAGS =
bin_PROGRAMS = plistutil