From 67b055905859213c235a750ef3800c9c76af13db Mon Sep 17 00:00:00 2001 From: Gergely Koloszar Date: Sat, 18 Oct 2025 21:13:15 +0200 Subject: [PATCH] Add makefile, and move latlon to a 'tools' directory --- helpers/tools/Makefile | 24 ++++++++++++++++++++++++ helpers/{ => tools}/latlon.c | 0 2 files changed, 24 insertions(+) create mode 100644 helpers/tools/Makefile rename helpers/{ => tools}/latlon.c (100%) diff --git a/helpers/tools/Makefile b/helpers/tools/Makefile new file mode 100644 index 0000000..38914fd --- /dev/null +++ b/helpers/tools/Makefile @@ -0,0 +1,24 @@ +bin := latlon + +CC = gcc + +CFLAGS += -Wall +CFLAGS += -Wextra +CFLAGS += -Wpedantic +CFLAGS += -std=c23 +CFLAGS += -O3 + +LDFLAGS += -lm + +PREFIX ?= $(HOME)/.local/share/dzgui + +all: $(bin) + +install: $(bin) + install -Dm 755 $(bin) $(PREFIX) + +$(bin): latlon.c + $(CC) $(CFLAGS) $^ -o $@ $(LDFLAGS) + +clean: + rm -f $(bin) diff --git a/helpers/latlon.c b/helpers/tools/latlon.c similarity index 100% rename from helpers/latlon.c rename to helpers/tools/latlon.c