Add demo test back as an example
[lttng-ust.git] / doc / examples / demo / Makefile
CommitLineData
60302adc
JG
1# Copyright (C) 2013 Jérémie Galarneau <jeremie.galarneau@efficios.com>
2#
3# THIS MATERIAL IS PROVIDED AS IS, WITH ABSOLUTELY NO WARRANTY EXPRESSED
4# OR IMPLIED. ANY USE IS AT YOUR OWN RISK.
5#
6# Permission is hereby granted to use or copy this program for any
7# purpose, provided the above notices are retained on all copies.
8# Permission to modify the code and to distribute modified code is
9# granted, provided the above notices are retained, and a notice that
10# the code was modified is included with the above copyright notice.
11
12# This Makefile is not using automake so that people may see how to build
13# a program and tracepoint provider probes as stand-alone shared objects.
14
15CC = gcc
16LIBS = -ldl # On Linux
17#LIBS = -lc # On BSD
18CFLAGS = -I.
19
20all: demo lttng-ust-provider-ust-tests-demo.so lttng-ust-provider-ust-tests-demo3.so
21
22lttng-ust-provider-ust-tests-demo.o: tp.c tp2.c ust_tests_demo.h ust_tests_demo2.h
23 $(CC) $(CFLAGS) -fpic -c -o $@ $<
24
25lttng-ust-provider-ust-tests-demo.so: lttng-ust-provider-ust-tests-demo.o
26 $(CC) -shared -o $@ -llttng-ust $<
27
28lttng-ust-provider-ust-tests-demo3.o: tp3.c ust_tests_demo3.h
29 $(CC) $(CFLAGS) -fpic -c -o $@ $<
30
31lttng-ust-provider-ust-tests-demo3.so: lttng-ust-provider-ust-tests-demo3.o
32 $(CC) -shared -o $@ -llttng-ust $<
33
34demo.o: demo.c
35 $(CC) $(CFLAGS) -c -o $@ $<
36
37demo: demo.o
38 $(CC) demo.o -o $@ $(LIBS)
39
40.PHONY: clean
41clean:
42 rm -f *.o *.so demo
This page took 0.024723 seconds and 4 git commands to generate.