Add deduplicated and memory-efficient string pool
[people/ms/libloc.git] / Makefile.am
CommitLineData
46aded9a
MT
1EXTRA_DIST =
2CLEANFILES =
3ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
4AM_MAKEFLAGS = --no-print-directory
5
6AM_CPPFLAGS = \
7 -include $(top_builddir)/config.h \
8 -DSYSCONFDIR=\""$(sysconfdir)"\" \
9 -I${top_srcdir}/src
10
11AM_CFLAGS = ${my_CFLAGS} \
12 -fvisibility=hidden \
13 -ffunction-sections \
14 -fdata-sections
15
16AM_LDFLAGS = \
17 -Wl,--gc-sections \
18 -Wl,--as-needed
19
20LIBLOC_CURRENT=0
21LIBLOC_REVISION=0
22LIBLOC_AGE=0
23
24SED_PROCESS = \
25 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && $(SED) \
26 -e 's,@VERSION\@,$(VERSION),g' \
27 -e 's,@prefix\@,$(prefix),g' \
28 -e 's,@exec_prefix\@,$(exec_prefix),g' \
29 -e 's,@libdir\@,$(libdir),g' \
30 -e 's,@includedir\@,$(includedir),g' \
31 < $< > $@ || rm $@
32
33pkgconfigdir = $(libdir)/pkgconfig
34
35%.pc: %.pc.in Makefile
36 $(SED_PROCESS)
37
38pkginclude_HEADERS = \
39 src/loc/libloc.h
40
41lib_LTLIBRARIES = \
42 src/libloc.la
43
44src_libloc_la_SOURCES =\
45 src/libloc-private.h \
62b83e6d
MT
46 src/libloc.c \
47 src/stringpool.c \
48 src/stringpool.h
46aded9a
MT
49
50EXTRA_DIST += src/libloc.sym
51
52src_libloc_la_LDFLAGS = \
53 $(AM_LDFLAGS) \
54 -version-info $(LIBLOC_CURRENT):$(LIBLOC_REVISION):$(LIBLOC_AGE) \
55 -Wl,--version-script=$(top_srcdir)/src/libloc.sym
56
57src_libloc_la_DEPENDENCIES = \
58 ${top_srcdir}/src/libloc.sym
59
60pkgconfig_DATA = \
61 src/libloc.pc
62
63EXTRA_DIST += \
64 src/libloc.pc.in
65
66CLEANFILES += \
67 src/libloc.pc
68
69TESTS = \
62b83e6d
MT
70 src/test-libloc \
71 src/test-stringpool
46aded9a
MT
72
73check_PROGRAMS = \
62b83e6d
MT
74 src/test-libloc \
75 src/test-stringpool
46aded9a
MT
76
77src_test_libloc_SOURCES = \
78 src/test-libloc.c
79
80src_test_libloc_LDADD = \
81 src/libloc.la
62b83e6d
MT
82
83src_test_stringpool_SOURCES = \
84 src/test-stringpool.c
85
86src_test_stringpool_LDADD = \
87 src/libloc.la