2023-02-08 19:03:00 +01:00
|
|
|
CC ?= cc
|
2023-02-09 11:34:32 +01:00
|
|
|
USR_LDFLAGS ?=
|
2024-05-31 19:35:04 +02:00
|
|
|
LDFLAGS ?= $$(pkg-config --libs ipc)
|
2023-02-09 11:34:32 +01:00
|
|
|
LDFLAGS += $(USR_LDFLAGS)
|
|
|
|
LDFLAGS += $(STATIC_BUILD)
|
|
|
|
CFLAGS ?= -Wall -Wextra
|
2023-02-08 19:03:00 +01:00
|
|
|
|
|
|
|
all: build
|
|
|
|
|
2023-02-09 11:34:32 +01:00
|
|
|
include ../mk/makefile.utils
|
|
|
|
|
2023-02-08 19:03:00 +01:00
|
|
|
BINS = pong pongd
|
|
|
|
build: $(BINS)
|
|
|
|
|
|
|
|
$(BINS):
|
2023-02-09 11:34:32 +01:00
|
|
|
$(CC) -o $@ $@.c $(CFLAGS) $(LDFLAGS)
|
2023-02-08 19:03:00 +01:00
|
|
|
|
2024-06-14 16:20:37 +02:00
|
|
|
run-pong:
|
|
|
|
$(VALGRIND) ./pong
|
|
|
|
|
|
|
|
run-pongd:
|
|
|
|
$(VALGRIND) ./pongd
|
|
|
|
|
2023-02-08 19:03:00 +01:00
|
|
|
clean:
|
|
|
|
rm $(BINS) 2>/dev/null
|
|
|
|
|
|
|
|
# You can add your specific instructions there.
|
|
|
|
-include makefile.user
|