work in prog
[lttv.git] / usertrace-fast / Makefile
CommitLineData
b09f3215 1
8b30e7bc 2RANLIB=ranlib
b09f3215 3
4CC=gcc
5
8b30e7bc 6all: test sample-instrument-fct libltt-instrument-functions.a libltt-instrument-functions.so.0
7
1c48e587 8test: test.c ltt-usertrace-fast.c
b09f3215 9 $(CC) $(CFLAGS) -lpthread -o $@ $^
10
8b30e7bc 11
12sample-instrument-fct: sample-instrument-fct.c
13 $(CC) $(CFLAGS) -L. -g -finstrument-functions -lltt-instrument-functions -o $@ $^
14
15libltt-instrument-functions.a: ltt-instrument-functions.o ltt-facility-loader-user_generic.o
16 @rm -f libltt-instrument-functions.a
17 $(AR) rc $@ $^
18 $(RANLIB) $@
19
20libltt-instrument-functions.so.0: ltt-instrument-functions.o ltt-facility-loader-user_generic.o
21 @rm -f libltt-instrument-functions.so libltt-instrument-functions.so.0
22 $(CC) $(CFLAGS) -shared -Wl,-soname,libltt-instrument-functions.so -o $@ $^
23 ln -s libltt-instrument-functions.so.0 libltt-instrument-functions.so
24
25install:
26 if [ ! -e "$(INCLUDE_DIR)/ltt" ] ; then mkdir $(INCLUDE_DIR)/ltt ; fi
27 cp -f ltt/*.h $(INCLUDE_DIR)/ltt
28 cp -df libltt-instrument-functions.so* libltt-instrument-functions.a $(LIB_DIR)
29
30.PHONY : clean install
b09f3215 31
32clean:
8b30e7bc 33 rm -fr *.o *~ test sample-instrument-fct libltt-instrument-functions.a libltt-instrument-functions.so*
This page took 0.023397 seconds and 4 git commands to generate.