diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -8,11 +8,14 @@ install: mkdir -p $(DESTDIR)$(PREFIX)/bin cp -f bin/stagit-new-repo bin/stagit-gen-index $(DESTDIR)$(PREFIX)/bin/ chmod 755 $(DESTDIR)$(PREFIX)/bin/stagit-gen-index $(DESTDIR)$(PREFIX)/bin/stagit-new-repo - mkdir -p /home/git/hooks - cp hooks/post-receive /home/git/hooks/ + cp hooks/post-receive $(DESTDIR)$(PREFIX)/share/ + if [ "$(PREFIX)" ]; then \ + sed -iba 's:/usr/local:$(PREFIX)' $(DESTDIR)$(PREFIX)/bin/stagit-new-repo; \ + rm -f $(DESTDIR)$(PREFIX)/bin/stagit-new-repoba; \ + fi uninstall: rm $(DESTDIR)$(PREFIX)/bin/stagit-gen-index $(DESTDIR)$(PREFIX)/bin/stagit-new-repo - rm /home/git/hooks/post-receive + rm $(DESTDIR)$(PREFIX)/share/post-receive .PHONY: install uninstall |