Pass the CC variable to the example Makefiles
[lttng-ust.git] / doc / examples / Makefile.am
CommitLineData
a106a9f8 1doc_examplesdir = ${docdir}/examples
7ccf75d3
MD
2doc_examples_easy_ustdir = ${docdir}/examples/easy-ust
3doc_examples_gen_tpdir = ${docdir}/examples/gen-tp
60302adc 4doc_examples_demodir = ${docdir}/examples/demo
a106a9f8
JG
5doc_examples_hello_static_libdir = ${docdir}/examples/hello-static-lib
6
7dist_doc_examples_DATA = README
7ccf75d3
MD
8
9dist_doc_examples_easy_ust_DATA = easy-ust/Makefile \
10 easy-ust/sample.c \
11 easy-ust/sample_component_provider.h easy-ust/tp.c
12
13dist_doc_examples_gen_tp_DATA = gen-tp/Makefile \
14 gen-tp/sample.c gen-tp/sample_tracepoint.tp
60302adc
JG
15
16dist_doc_examples_demo_DATA = demo/demo.c \
17 demo/demo-trace \
18 demo/Makefile \
19 demo/README \
20 demo/tp2.c \
21 demo/tp3.c \
22 demo/tp.c \
23 demo/ust_tests_demo2.h \
24 demo/ust_tests_demo3.h \
25 demo/ust_tests_demo.h
a106a9f8
JG
26
27dist_doc_examples_hello_static_lib_DATA = hello-static-lib/Makefile \
28 hello-static-lib/hello.c \
29 hello-static-lib/README \
30 hello-static-lib/ust_tests_hello.h \
31 hello-static-lib/tp.c
32
f66773d6
MD
33if NO_SHARED
34# Don't build examples if shared libraries support was explicitly
35# disabled.
36else
37# Copies are for VPATH build support
38SUBDIRS_PROXY = easy-ust demo gen-tp hello-static-lib
39
40all-local:
41 @if [ x"$(srcdir)" != x"$(builddir)" ]; then \
42 cp -f $(srcdir)/Makefile.examples.template $(builddir); \
43 for subdir in $(SUBDIRS_PROXY); do \
44 cp -fR $(srcdir)/$$subdir $(builddir); \
45 done; \
46 fi
47 for subdir in $(SUBDIRS_PROXY); do \
0728d307 48 (cd $$subdir && $(MAKE) AM_CC="$(CC)" AM_CPPFLAGS="$(CPPFLAGS) -I../../../include/" AM_CFLAGS='$(CFLAGS)' AM_LDFLAGS='$(LDFLAGS) -L../../../liblttng-ust/.libs/ -Wl,-rpath="$(PWD)/../../liblttng-ust/.libs/"' LTTNG_GEN_TP_PATH="../../../tools/" $(AM_MAKEFLAGS) all && cd ..) || exit 1; \
f66773d6
MD
49 done
50
51clean-local:
52 for subdir in $(SUBDIRS_PROXY); do \
c84d9878 53 (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) clean && cd ..) || exit 1; \
f66773d6
MD
54 done
55 @if [ x"$(srcdir)" != x"$(builddir)" ]; then \
56 for subdir in $(SUBDIRS_PROXY); do \
57 rm -rf $(builddir)/$$subdir; \
58 done; \
59 rm -f $(builddir)/Makefile.examples.template; \
60 fi
61endif
This page took 0.025572 seconds and 4 git commands to generate.