1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
|
# Copyright (C) CNRS, INRIA, Université Bordeaux 1, Télécom SudParis
# See COPYING in top-level directory.
CC = gcc
CFLAGS = -O0 -marm -march=armv7-a -g
BIN = libtest_pptrace.static.a libtest_pptrace.shared.so main.shared main.static
all: $(BIN)
main.shared: main.c test_pptrace.h
$(CC) $(CFLAGS) -o main.shared main.c -L. -ltest_pptrace.shared
main.static: main.c test_pptrace.h
$(CC) $(CFLAGS) -o main.static main.c -static -L. -ltest_pptrace.static
libtest_pptrace.shared.so: test_pptrace.shared.o
$(CC) $(CFLAGS) --shared -o libtest_pptrace.shared.so test_pptrace.shared.o -ldl
libtest_pptrace.static.a: test_pptrace.static.o
ar rcv libtest_pptrace.static.a test_pptrace.static.o
test_pptrace.shared.o: test_pptrace.c test_pptrace.h
$(CC) $(CFLAGS) -o test_pptrace.shared.o -c test_pptrace.c -fPIC
test_pptrace.static.o: test_pptrace.c test_pptrace.h
$(CC) $(CFLAGS) -o test_pptrace.static.o -c test_pptrace.c
clean:
rm -f $(BIN) *.o *.so
|