1
0
mirror of https://git.sr.ht/~adnano/kiln synced 2024-11-08 14:19:20 +01:00

Add Makefile

This commit is contained in:
adnano 2020-11-01 20:51:43 -05:00
parent 26e6a0b05b
commit 7b6efd6fb8
3 changed files with 39 additions and 6 deletions

1
.gitignore vendored Normal file

@ -0,0 +1 @@
kiln

32
Makefile Normal file

@ -0,0 +1,32 @@
.POSIX:
.SUFFIXES:
VERSION=0.0.0
PREFIX?=/usr/local
GO?=go
GOFLAGS?=
GOSRC!=find . -name '*.go'
GOSRC+=go.mod go.sum
all: kiln
kiln: $(GOSRC)
$(GO) build $(GOFLAGS) \
-ldflags "-X main.Prefix=$(PREFIX) \
-X main.ShareDir=$(SHAREDIR) \
-X main.Version=$(VERSION)" \
-o $@
clean:
rm -f kiln
install: all
mkdir -p $(DESTDIR)$(PREFIX)/bin
install -m755 kiln $(DESTDIR)$(PREFIX)/bin
uninstall:
$(RM) $(DESTDIR)$(PREFIX)/bin/kiln
.PHONY: all clean install uninstall

@ -12,14 +12,14 @@ A simple static site generator for Gemini.
## Installation
```
go install
```
First install Go version 1.15 or later.
Then compile:
$ make
# make install
## Usage
```
kiln
```
kiln
For more information, consult the [wiki](https://man.sr.ht/~adnano/kiln/).