summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorDaniel Patterson <me@danielpatterson.dev>2022-03-02 03:38:59 +0000
committerRobin Jarry <robin@jarry.cc>2022-03-03 21:31:32 +0100
commit0cfffaef5409f99bbc4140b97b769a400b7467f8 (patch)
treec37b8a4257eb1a9dd58873871dc355043c17b4c8 /Makefile
parent7e6c0d2e6e8c37844289a9b215df29708c580bf2 (diff)
downloadaerc-0cfffaef5409f99bbc4140b97b769a400b7467f8.zip
config: specify sharedir during build
We should use the Makefile value of SHAREDIR when searching for config files and templates etc. This is important for systems which do not use the standard file hierarchy or which do not have a consistent location for installing program files, for example NixOS, which will have a different install location with every update. Signed-off-by: Daniel Patterson <me@danielpatterson.dev> Acked-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile1
1 files changed, 1 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 9b9d24f..cf8d743 100644
--- a/Makefile
+++ b/Makefile
@@ -11,6 +11,7 @@ MANDIR?=$(PREFIX)/share/man
GO?=go
GOFLAGS?=
LDFLAGS+=-X main.Version=$(VERSION)
+LDFLAGS+=-X git.sr.ht/~rjarry/aerc/config.shareDir=$(SHAREDIR)
GOSRC!=find * -name '*.go'
GOSRC+=go.mod go.sum