Link libcharon to checksum_builder in order to get rid of the fake symbols.
[strongswan.git] / src / checksum / Makefile.am
1 ipsec_LTLIBRARIES = libchecksum.la
2 noinst_PROGRAMS = checksum_builder
3
4 nodist_libchecksum_la_SOURCES = checksum.c
5 libchecksum_la_LDFLAGS = -module -avoid-version
6
7 checksum_builder_SOURCES = checksum_builder.c
8 checksum_builder_LDADD = \
9         $(top_builddir)/src/libstrongswan/libstrongswan.la \
10         $(top_builddir)/src/libcharon/libcharon.la \
11         $(DLLIB)
12
13 BUILT_SOURCES = checksum.c
14 CLEANFILES = checksum.c
15 INCLUDES = -I$(top_srcdir)/src/libstrongswan
16 AM_CFLAGS = -rdynamic
17
18 libs =  $(shell find $(top_builddir)/src/libstrongswan $(top_builddir)/src/libcharon \
19                         -name 'libstrongswan*.so')
20
21 if USE_CHARON
22   libs += $(top_builddir)/src/libcharon/.libs/libcharon.so
23   libs += $(top_builddir)/src/charon/.libs/charon
24 endif
25
26 if USE_PLUTO
27   libs += $(top_builddir)/src/pluto/.libs/pluto
28 endif
29
30 if USE_TOOLS
31   libs += $(top_builddir)/src/openac/.libs/openac
32   libs += $(top_builddir)/src/pki/.libs/pki
33   libs += $(top_builddir)/src/scepclient/.libs/scepclient
34 endif
35
36 if USE_ATTR_SQL
37   libs += $(top_builddir)/src/libstrongswan/plugins/attr_sql/.libs/pool
38 endif
39
40 checksum.c : checksum_builder $(libs)
41                 ./checksum_builder $(libs) > checksum.c