add install target to Makefile

Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/d46b4405
Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/d46b4405
Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/d46b4405

Branch: refs/heads/1843-feature-bigcouch
Commit: d46b4405427a0dd2fc16ff838b5d0b11b23146bb
Parents: 7e3c6e2
Author: Robert Newson <[email protected]>
Authored: Mon Dec 23 18:18:03 2013 +0000
Committer: Robert Newson <[email protected]>
Committed: Tue Jan 28 15:52:26 2014 +0000

----------------------------------------------------------------------
 Makefile | 11 +++++++++++
 1 file changed, 11 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb/blob/d46b4405/Makefile
----------------------------------------------------------------------
diff --git a/Makefile b/Makefile
index faa570c..8b0602b 100644
--- a/Makefile
+++ b/Makefile
@@ -33,6 +33,17 @@ dist: compile
 distclean: clean
        @rm -rf rel/couchdb
 
+include install.mk
+install: dist
+       @mkdir -p $(prefix)
+       @cp -R rel/couchdb/* $(prefix)
+       @mkdir -p $(data_dir)
+       @chown $(user) $(data_dir)
+       @mkdir -p $(view_dir)
+       @chown $(user) $(view_dir)
+       @touch $(prefix)/var/log/couchdb.log
+       @chown $(user) $(prefix)/var/log/couchdb.log
+
 dev: compile
        @rm -rf rel/dev1 rel/dev2 rel/dev3
        @echo "==> Building development node #1 (ports 15984/15986)"

Reply via email to