diff options
Diffstat (limited to 'lib/Makefile.am')
-rw-r--r-- | lib/Makefile.am | 79 |
1 files changed, 4 insertions, 75 deletions
diff --git a/lib/Makefile.am b/lib/Makefile.am index 7edac1f..3909bb9 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am | |||
@@ -2,85 +2,14 @@ | |||
2 | 2 | ||
3 | SUBDIRS = tests | 3 | SUBDIRS = tests |
4 | 4 | ||
5 | noinst_LIBRARIES = libcoreutils.a libnagiosplug.a | 5 | noinst_LIBRARIES = libnagiosplug.a |
6 | 6 | ||
7 | # Will auto pick up fsusage.c mountlist.c | ||
8 | libcoreutils_a_SOURCES = \ | ||
9 | cloexec.c cloexec.h \ | ||
10 | exit.h \ | ||
11 | full-read.c full-read.h \ | ||
12 | full-write.c full-write.h \ | ||
13 | gettext.h \ | ||
14 | safe-read.c safe-read.h \ | ||
15 | safe-write.c safe-write.h strcase.h xalloc-die.c | ||
16 | 7 | ||
17 | # intprops.h required for getloadavg.c | 8 | libnagiosplug_a_SOURCES = utils_base.c utils_disk.c |
18 | # This needs to be an EXTRA_DIST because the m4s | 9 | EXTRA_DIST = utils_base.h utils_disk.h |
19 | # that have AC_LIBSOURCES for intprops.h are not necessary and | ||
20 | # the getloadavg m4 is an autoconf one, so doesn't | ||
21 | # know about intprops.h. Confused? You will be! | ||
22 | EXTRA_DIST = intprops.h | ||
23 | 10 | ||
24 | other_coreutils_files = \ | 11 | INCLUDES = -I$(srcdir) -I$(top_srcdir)/gl -I$(top_srcdir)/intl -I$(top_srcdir)/plugins |
25 | error.c error.h \ | ||
26 | fsusage.c \ | ||
27 | getloadavg.c \ | ||
28 | malloc.c \ | ||
29 | mountlist.c \ | ||
30 | realloc.c \ | ||
31 | strtod.c \ | ||
32 | exitfail.c exitfail.h \ | ||
33 | fsusage.h \ | ||
34 | getopt.c getopt1.c \ | ||
35 | mountlist.h \ | ||
36 | unlocked-io.h \ | ||
37 | xalloc.h \ | ||
38 | xmalloc.c | ||
39 | |||
40 | |||
41 | libcoreutils_a_LIBADD = $(LIBOBJS) $(ALLOCA) | ||
42 | libcoreutils_a_DEPENDENCIES = $(libcoreutils_a_LIBADD) | ||
43 | lib_OBJECTS = $(libcoreutils_a_OBJECTS) | ||
44 | |||
45 | libnagiosplug_a_SOURCES = snprintf.c utils_base.c utils_disk.c | ||
46 | EXTRA_DIST += utils_base.h utils_disk.h | ||
47 | |||
48 | INCLUDES = -I$(srcdir) -I$(top_srcdir)/intl -I$(top_srcdir)/plugins | ||
49 | |||
50 | print_coreutil_files: | ||
51 | @echo $(libcoreutils_a_SOURCES) $(other_coreutils_files) $(EXTRA_DIST) | ||
52 | 12 | ||
53 | test: | 13 | test: |
54 | cd tests && make test | 14 | cd tests && make test |
55 | 15 | ||
56 | # Below are from coreutil's lib/Makefile.am | ||
57 | BUILT_SOURCES = $(STDBOOL_H) | ||
58 | EXTRA_DIST += stdbool_.h | ||
59 | MOSTLYCLEANFILES = stdbool.h stdbool.ht | ||
60 | # Create stdbool.h on systems that lack a working one. | ||
61 | stdbool.h: stdbool_.h | ||
62 | sed -e 's/@''HAVE__BOOL''@/$(HAVE__BOOL)/g' $(srcdir)/stdbool_.h > $@t | ||
63 | mv $@t $@ | ||
64 | |||
65 | BUILT_SOURCES += $(ALLOCA_H) | ||
66 | EXTRA_DIST += alloca_.h | ||
67 | |||
68 | # We need the following in order to create an <alloca.h> when the system | ||
69 | # doesn't have one that works with the given compiler | ||
70 | all-local $(lib_OBJECTS): $(ALLOCA_H) | ||
71 | alloca.h: alloca_.h | ||
72 | cp $(srcdir)/alloca_.h $@-t | ||
73 | mv $@-t $@ | ||
74 | MOSTLYCLEANFILES += alloca.h alloca.h-t | ||
75 | |||
76 | BUILT_SOURCES += $(GETOPT_H) | ||
77 | EXTRA_DIST += getopt_.h getopt_int.h | ||
78 | |||
79 | # We need the following in order to create an <getopt.h> when the system | ||
80 | # doesn't have one that works with the given compiler. | ||
81 | all-local $(lib_OBJECTS): $(GETOPT_H) | ||
82 | getopt.h: getopt_.h | ||
83 | cp $(srcdir)/getopt_.h $@-t | ||
84 | mv $@-t $@ | ||
85 | MOSTLYCLEANFILES += getopt.h getopt.h-t | ||
86 | |||