Files
RetroArch/samples/audio/graph_clock/Makefile
LibretroAdmin 21635dd171 samples: build with -g1 instead of -g
The sample and test builds used full debug info. -g1 keeps what
sanitizer reports and backtraces need - function names, files and line
numbers - and drops the variable and type information nobody reads in
CI. Objects get about 30% smaller (rh265.o under ASan+UBSan: 5.1MB to
3.7MB), so the ccache caches hold more of each job's build and are
quicker to restore and save.
2026-10-13 11:50:11 +02:00

32 lines
742 B
Makefile

# JACK and PipeWire clock conversions: the wrap and the fraction.
CORE_DIR := ../../..
LIBRETRO_COMM_DIR := $(CORE_DIR)/libretro-common
TARGET := graph_clock_test
SOURCES_C := graph_clock_test.c
OBJS := $(SOURCES_C:.c=.o)
INCDIRS := -I$(LIBRETRO_COMM_DIR)/include -I$(CORE_DIR)
CFLAGS += -Wall -Wno-variadic-macros $(INCDIRS) -D_GNU_SOURCE
ifneq ($(SANITIZER),)
CFLAGS += -fsanitize=$(SANITIZER) -fno-omit-frame-pointer -g1
LDFLAGS += -fsanitize=$(SANITIZER)
else
CFLAGS += -g1 -O1
endif
all: $(TARGET)
$(TARGET): $(OBJS)
$(CC) -o $@ $(OBJS) $(LDFLAGS) -lm
%.o: %.c
$(CC) $(CFLAGS) -std=c99 -pedantic -Wdeclaration-after-statement -Wno-long-long -c -o $@ $<
clean:
rm -f $(OBJS) $(TARGET)
.PHONY: all clean