# HG changeset patch # User Christophe Lincoln # Date 1390094400 -3600 # Node ID 53a2678332668d9930c81322bc1b3658ddd9361c # Parent 30e39dd19525b64f4c63b64d67ed796c14837cd0 Improve Makefile diff -r 30e39dd19525 -r 53a267833266 Makefile --- a/Makefile Sat Jan 18 17:52:45 2014 +0100 +++ b/Makefile Sun Jan 19 02:20:00 2014 +0100 @@ -5,10 +5,10 @@ PREFIX?=/usr DESTDIR?= WEB?=/var/www/cgi-bin/tinycm -LOGIN?=/var/lib/slitaz +AUTH?=/var/lib/slitaz LINGUAS?=pt_BR -all: +all: msgfmt # i18n @@ -31,24 +31,31 @@ # Install -install: - install -m 0700 -d $(DESTDIR)$(LOGIN)/people - install -m 0700 -d $(DESTDIR)$(LOGIN)/auth - install -m 0755 -d $(DESTDIR)$(WEB)/cache - install -m 0777 -d $(DESTDIR)$(PREFIX)/share/applications - #install -m 0777 -d $(DESTDIR)$(PREFIX)/share/locale - - cp -a config.cgi favicon.ico index.cgi style.css images lib \ - plugins content/ $(DESTDIR)$(WEB) - #cp -a po/mo/* $(DESTDIR)$(PREFIX)/share/locale - install -m 0644 data/*.desktop $(DESTDIR)$(PREFIX)/share/applications - +install: install-web + install -m 0700 -d $(DESTDIR)$(AUTH)/people + install -m 0700 -d $(DESTDIR)$(AUTH)/auth + install -m 0777 -d $(DESTDIR)$(PREFIX)/share/locale + cp -a po/mo/* $(DESTDIR)$(PREFIX)/share/locale # Set permissions - chown -R www.www $(DESTDIR)$(LOGIN)/auth - chown -R www.www $(DESTDIR)$(LOGIN)/people + chown -R www.www $(DESTDIR)$(AUTH)/auth + chown -R www.www $(DESTDIR)$(AUTH)/people chown -R www.www $(DESTDIR)$(WEB)/content chown -R www.www $(DESTDIR)$(WEB)/cache +install-web: + install -m 0755 -d $(DESTDIR)$(WEB)/cache + cp -a config.cgi favicon.ico index.cgi style.css images lib \ + plugins content $(DESTDIR)$(WEB) + +install-slitaz: install + install -m 0777 -d $(DESTDIR)$(PREFIX)/share/applications + install -m 0644 data/*.desktop $(DESTDIR)$(PREFIX)/share/applications + uninstall: rm -rf $(DESTDIR)$(WEB) rm $(DESTDIR)$(PREFIX)/share/applications/tinycm.desktop + +# Clean source + +clean: + rm -rf po/mo diff -r 30e39dd19525 -r 53a267833266 README --- a/README Sat Jan 18 17:52:45 2014 +0100 +++ b/README Sun Jan 19 02:20:00 2014 +0100 @@ -40,6 +40,15 @@ $ editor config.cgi $ make install +If you want to install the web interface and auth DB in an other directory +than /var/www and /var/lib/slitaz you can use the following command: + + $ make install WEB=/path/to/domain/vhost AUTH=/path/to/domain + +If you already have a users DB and want to share auth sytem you can install +TinyCM with: + + $ make install-web WEB=/path/to/domain/vhost Plugins -------