[SKIP CI] fix(make): Real actual macOS support (#148)
Tested again on the lone Apple device I have. This time it does not break make on Linux 🌝 Reviewed-on: #148 Reviewed-by: grumbulon <grumbulon@grumbulon.xyz>
This commit is contained in:
parent
a386960076
commit
59212798f7
2 changed files with 12 additions and 7 deletions
17
GNUmakefile
17
GNUmakefile
|
@ -7,6 +7,11 @@ ifeq ($(OS),Windows_NT)
|
|||
EXE := $(PROG).exe
|
||||
else
|
||||
EXE := $(PROG)
|
||||
ifeq ($(shell uname), Darwin)
|
||||
INSTALLFLAGS :=
|
||||
else
|
||||
INSTALLFLAGS := D
|
||||
endif
|
||||
endif
|
||||
|
||||
## install: installs awl
|
||||
|
@ -16,11 +21,11 @@ install:
|
|||
$(GO) install $(GOFLAGS) .
|
||||
else
|
||||
install: all
|
||||
install -Dm755 $(PROG) $(DESTDIR)$(PREFIX)/$(BIN)/$(PROG)
|
||||
install -Dm644 doc/$(PROG).1 $(DESTDIR)$(MAN)/man1/$(PROG).1
|
||||
gzip -9 $(DESTDIR)$(MAN)/man1/$(PROG).1
|
||||
install -$(INSTALLFLAGS)m755 $(PROG) $(DESTDIR)$(PREFIX)/$(BIN)/$(PROG)
|
||||
install -$(INSTALLFLAGS)m644 doc/$(PROG).1 $(DESTDIR)$(MAN)/man1/$(PROG).1
|
||||
gzip -9f $(DESTDIR)$(MAN)/man1/$(PROG).1
|
||||
# completions need to go in one specific place :)
|
||||
install -Dm644 completions/bash.bash $(DESTDIR)$(PREFIX)/$(SHARE)/bash-completion/completions/$(PROG)
|
||||
install -Dm644 completions/fish.fish $(DESTDIR)$(PREFIX)/$(SHARE)/fish/vendor_completions.d/$(PROG).fish
|
||||
install -Dm644 completions/zsh.zsh $(DESTDIR)$(PREFIX)/$(SHARE)/zsh/site-functions/_$(PROG)
|
||||
install -$(INSTALLFLAGS)m644 completions/bash.bash $(DESTDIR)$(PREFIX)/$(SHARE)/bash-completion/completions/$(PROG)
|
||||
install -$(INSTALLFLAGS)m644 completions/fish.fish $(DESTDIR)$(PREFIX)/$(SHARE)/fish/vendor_completions.d/$(PROG).fish
|
||||
install -$(INSTALLFLAGS)m644 completions/zsh.zsh $(DESTDIR)$(PREFIX)/$(SHARE)/zsh/site-functions/_$(PROG)
|
||||
endif
|
||||
|
|
2
Makefile
2
Makefile
|
@ -10,7 +10,7 @@ EXE := $(PROG)
|
|||
install: all
|
||||
install -Dm755 $(PROG) $(DESTDIR)$(PREFIX)/$(BIN)/$(PROG)
|
||||
install -Dm644 doc/$(PROG).1 $(DESTDIR)$(MAN)/man1/$(PROG).1
|
||||
gzip -9 $(DESTDIR)$(MAN)/man1/$(PROG).1
|
||||
gzip -9f $(DESTDIR)$(MAN)/man1/$(PROG).1
|
||||
# completions need to go in one specific place :)
|
||||
install -Dm644 completions/bash.bash $(DESTDIR)$(PREFIX)$(SHARE)/bash-completion/completions/$(PROG)
|
||||
install -Dm644 completions/fish.fish $(DESTDIR)$(PREFIX)$(SHARE)/fish/vendor_completions.d/$(PROG).fish
|
||||
|
|
Loading…
Reference in a new issue