25 lines
755 B
Makefile
25 lines
755 B
Makefile
CC ?= cc
|
|
CFLAGS ?= -std=c11 -O2 -Wall -Wextra -Wpedantic
|
|
CFLAGS += -I../../gps_system/header
|
|
LDLIBS ?= -lm
|
|
|
|
GPS_TIME_SOURCE := ../../gps_system/src/gps_time_anchor.c
|
|
|
|
.PHONY: all test benchmark clean
|
|
|
|
all: standalone_gps_integrity_test
|
|
|
|
standalone_gps_integrity_test: standalone_gps_integrity_test.c $(GPS_TIME_SOURCE)
|
|
$(CC) $(CFLAGS) $^ -o $@ $(LDLIBS)
|
|
|
|
test: standalone_gps_integrity_test
|
|
./standalone_gps_integrity_test
|
|
|
|
benchmark: standalone_gps_integrity_test
|
|
./standalone_gps_integrity_test --bench-clean 100000
|
|
./standalone_gps_integrity_test --bench-single 100000
|
|
./standalone_gps_integrity_test --bench-double 100000
|
|
|
|
clean:
|
|
rm -f standalone_gps_integrity_test standalone_gps_integrity_test_san standalone_gps_integrity_test_gprof gmon.out
|