summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorRobin Jarry <robin@jarry.cc>2022-04-14 21:47:06 +0200
committerRobin Jarry <robin@jarry.cc>2022-04-14 21:51:09 +0200
commit02b7f7401682ffcfb2ebf1c4a2900b8f40908db4 (patch)
treed48ba67964a92bdf548e8768046363cfce53e738 /Makefile
parentba892d776947e9494b10eb820cf6d35d3bb263c6 (diff)
downloadaerc-02b7f7401682ffcfb2ebf1c4a2900b8f40908db4.zip
mk: do not depend on cmp being available
cmp is part of gnu diffutils which may not be available. Use grep which is more widespread. Signed-off-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 1 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 14adf89..3e7d89b 100644
--- a/Makefile
+++ b/Makefile
@@ -38,9 +38,7 @@ build_cmd:=$(GO) build $(GOFLAGS) -ldflags "$(GO_LDFLAGS)" -o aerc
# the following command outputs nothing, we only want to execute it once
# and force .aerc.d to be regenerated when build_cmd has changed
-_!=echo '$(build_cmd)' > .aerc.tmp; \
- cmp -s .aerc.d .aerc.tmp || rm -f .aerc.d; \
- rm -f .aerc.tmp
+_!=grep -sqFx '$(build_cmd)' .aerc.d || rm -f .aerc.d
.aerc.d:
@echo '$(build_cmd)' > $@