From fda36c7d5a7b975811565f0dccd9bf723efe2e33 Mon Sep 17 00:00:00 2001 From: Glenn Date: Tue, 16 Aug 2022 21:35:19 +0200 Subject: [PATCH] Fix build rules --- .gitignore | 1 + Makefile | 12 ++++++------ README.md | 1 + 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 0bb75ea..64addb4 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ /docs/ +_build /lib/ /bin/ /.shards/ diff --git a/Makefile b/Makefile index 209f7ac..358d70b 100644 --- a/Makefile +++ b/Makefile @@ -4,24 +4,24 @@ SOURCES=$(shell find -name '*.cr') LDFLAGS= DESTDIR=/usr -BUILDDIR=_build +BUILD_DIR=_build all: build $(BUILD_DIR): mkdir -p $(BUILD_DIR) -$(BUILDDIR)/kathmandu_time: $(BUILDDIR) $(SOURCES) - crystal build $(LDFLAGS) src/kathmandu_time.cr -o $(BUILDDIR)/kathmandu_time +$(BUILD_DIR)/kathmandu_time: $(BUILD_DIR) $(SOURCES) + crystal build $(LDFLAGS) src/kathmandu_time.cr -o $(BUILD_DIR)/kathmandu_time -build: $(BUILDDIR)/kathmandu_time +build: $(BUILD_DIR)/kathmandu_time build-release: LDFLAGS=--release --no-debug build-release: build install: build install -m 0755 -o root -g root \ - $(BUILDDIR)/kathmandu_time \ + $(BUILD_DIR)/kathmandu_time \ $(DESTDIR)/bin/kathmandu_time spec: @@ -33,5 +33,5 @@ run: crystal run src/kathmandu_time.cr clean: - rm -f $(BUILDDIR)/kathmandu_time + rm -f $(BUILD_DIR)/kathmandu_time diff --git a/README.md b/README.md index 334f364..30fe1b9 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,7 @@ TODO: Write installation instructions here ## Usage + TODO: Write usage instructions here ## Development