Permalink
Browse files

Replace install.sh by a makefile

  • Loading branch information...
1 parent 1ee1c31 commit 99dfb8984fa478f026e7e878d1cbae3be9596c48 @Nano77 committed Jan 16, 2013
Showing with 93 additions and 57 deletions.
  1. +31 −0 INSTALL.md
  2. +1 −1 README.md
  3. +0 −38 install.sh
  4. +61 −0 makefile
  5. +0 −18 po/make-mo
View
31 INSTALL.md
@@ -0,0 +1,31 @@
+Build
+-----
+
+Standard : `make`
+
+
+
+Ubuntu : `make ubuntu`
+
+
+
+Debian : `make debian`
+
+
+
+
+Install
+-------
+
+`make DESTDIR=`*'Your desired destination'* `install`
+
+
+
+
+Ubuntu post-install
+-------------------
+
+Ensure than `/var/lib/gdm/dconf` are writable by gdm :
+`chown -R gdm:gdm /var/lib/gdm/`
+
+
View
2 README.md
@@ -3,7 +3,7 @@ GDM3setup
A GUI to setting GDM3
-Nano77 <nanoarch77@gmail.com>
+NanoArch <nanoarch77@gmail.com>
View
38 install.sh
@@ -1,38 +0,0 @@
-#! /bin/sh
-#
-#
-
-#Ubuntu
-#chown -R gdm:gdm /var/lib/gdm/
-
-#Ubuntu/Debian
-#sed -i s/python2/python/ gdm3setup.py
-#sed -i s/python2/python/ gdm3setup-daemon.py
-#sed -i s/python2/python/ gdmlogin.py
-
-#Debian
-#sed -i -e 's/sbin\/gdm/sbin\/gdm3/' gdm3setup-daemon.py
-#sed -i -e 's/sbin\/gdm/sbin\/gdm3/' gdm3setup.py
-#sed -i -e 's/etc\/gdm/etc\/gdm3/' gdm3setup-daemon.py
-#sed -i -e 's/etc\/gdm/etc\/gdm3/' gdmlogin.py
-#sed -i -e 's/"gdm"/"Debian-gdm"/' gdm3setup-daemon.py
-#sed -i -e 's/sbin\/gdm/sbin\/gdm3/' get_gdm.sh
-
-cd po
-./make-mo
-cd ..
-
-install --mode=755 -D gdm3setup.py /usr/bin/
-install --mode=755 -D gdm3setup-daemon.py /usr/bin/
-install --mode=755 -D start-gdm3setup-daemon /usr/bin/
-install --mode=755 -D gdmlogin.py /usr/bin/
-install --mode=755 -D get_gdm.sh /usr/bin/
-install --mode=755 -D set_gdm.sh /usr/bin/
-install -D gdm3setup.desktop /usr/share/applications/
-install -D apps.nano77.gdm3setup.service /usr/share/dbus-1/system-services/
-install -D apps.nano77.gdm3setup.service /usr/share/dbus-1/services/
-install -D apps.nano77.gdm3setup.conf /etc/dbus-1/system.d/
-install -D apps.nano77.gdm3setup.policy /usr/share/polkit-1/actions/
-install -D gdm3setup.ui /usr/share/gdm3setup/ui/gdm3setup.ui
-cp -r locale /usr/share/
-
View
61 makefile
@@ -0,0 +1,61 @@
+
+all: mo
+
+ubuntu: python mo
+
+debian: python mo
+ sed -i -e 's/sbin\/gdm/sbin\/gdm3/' gdm3setup-daemon.py
+ sed -i -e 's/sbin\/gdm/sbin\/gdm3/' gdm3setup.py
+ sed -i -e 's/etc\/gdm/etc\/gdm3/' gdm3setup-daemon.py
+ sed -i -e 's/etc\/gdm/etc\/gdm3/' gdmlogin.py
+ sed -i -e 's/"gdm"/"Debian-gdm"/' gdm3setup-daemon.py
+ sed -i -e 's/sbin\/gdm/sbin\/gdm3/' get_gdm.sh
+
+python:
+ sed -i s/python2/python/ gdm3setup.py
+ sed -i s/python2/python/ gdm3setup-daemon.py
+ sed -i s/python2/python/ gdmlogin.py
+
+mo:
+ mkdir -p locale/{fr,en_US,es_ES,de_DE,it,pt_BR,zh_CN}/LC_MESSAGES/
+
+ msgfmt po/gdm3setup-fr.po -o locale/fr/LC_MESSAGES/gdm3setup.mo
+ msgfmt po/gdm3setup-en_US.po -o locale/en_US/LC_MESSAGES/gdm3setup.mo
+ msgfmt po/gdm3setup-es_ES.po -o locale/es_ES/LC_MESSAGES/gdm3setup.mo
+ msgfmt po/gdm3setup-de_DE.po -o locale/de_DE/LC_MESSAGES/gdm3setup.mo
+ msgfmt po/gdm3setup-it.po -o locale/it/LC_MESSAGES/gdm3setup.mo
+ msgfmt po/gdm3setup-pt_BR.po -o locale/pt_BR/LC_MESSAGES/gdm3setup.mo
+ msgfmt po/gdm3setup-zh_CN.po -o locale/zh_CN/LC_MESSAGES/gdm3setup.mo
+
+install:
+ install --mode=755 -D gdm3setup.py $(DESTDIR)/usr/bin/gdm3setup.py
+ install --mode=755 -D gdm3setup-daemon.py $(DESTDIR)/usr/bin/gdm3setup-daemon.py
+ install --mode=755 -D start-gdm3setup-daemon $(DESTDIR)/usr/bin/
+ install --mode=755 -D gdmlogin.py $(DESTDIR)/usr/bin/
+ install --mode=755 -D get_gdm.sh $(DESTDIR)/usr/bin/
+ install --mode=755 -D set_gdm.sh $(DESTDIR)/usr/bin/
+ install -D gdm3setup.desktop $(DESTDIR)/usr/share/applications/gdm3setup.desktop
+ install -D apps.nano77.gdm3setup.service $(DESTDIR)/usr/share/dbus-1/system-services/apps.nano77.gdm3setup.service
+ install -D apps.nano77.gdm3setup.service $(DESTDIR)/usr/share/dbus-1/services/apps.nano77.gdm3setup.service
+ install -D apps.nano77.gdm3setup.conf $(DESTDIR)/etc/dbus-1/system.d/apps.nano77.gdm3setup.conf
+ install -D apps.nano77.gdm3setup.policy $(DESTDIR)/usr/share/polkit-1/actions/apps.nano77.gdm3setup.policy
+ install -D gdm3setup.ui $(DESTDIR)/usr/share/gdm3setup/ui/gdm3setup.ui
+ cp -r locale $(DESTDIR)/usr/share/
+
+uninstall:
+ rm /usr/bin/gdm3setup.py
+ rm /usr/bin/gdm3setup-daemon.py
+ rm /usr/bin/start-gdm3setup-daemon
+ rm /usr/bin/gdmlogin.py
+ rm /usr/bin/get_gdm.sh
+ rm /usr/bin/set_gdm.sh
+ rm /usr/share/applications/gdm3setup.desktop
+ rm /usr/share/dbus-1/system-services/apps.nano77.gdm3setup.service
+ rm /usr/share/dbus-1/services/apps.nano77.gdm3setup.service
+ rm /etc/dbus-1/system.d/apps.nano77.gdm3setup.conf
+ rm /usr/share/polkit-1/actions/apps.nano77.gdm3setup.policy
+ rm /usr/share/gdm3setup/ui/gdm3setup.ui
+ rm /usr/share/locale/{de_DE,en_US,es_ES,fr,it,pt_BR,zh_CN}/LC_MESSAGES/gdm3setup.mo
+
+
+
View
18 po/make-mo
@@ -1,18 +0,0 @@
-#! /bin/sh
-#
-
-mkdir -p ../locale/fr/LC_MESSAGES/
-mkdir -p ../locale/en_US/LC_MESSAGES/
-mkdir -p ../locale/es_ES/LC_MESSAGES/
-mkdir -p ../locale/de_DE/LC_MESSAGES/
-mkdir -p ../locale/it/LC_MESSAGES/
-mkdir -p ../locale/pt_BR/LC_MESSAGES/
-mkdir -p ../locale/zh_CN/LC_MESSAGES/
-
-msgfmt gdm3setup-fr.po -o ../locale/fr/LC_MESSAGES/gdm3setup.mo
-msgfmt gdm3setup-en_US.po -o ../locale/en_US/LC_MESSAGES/gdm3setup.mo
-msgfmt gdm3setup-es_ES.po -o ../locale/es_ES/LC_MESSAGES/gdm3setup.mo
-msgfmt gdm3setup-de_DE.po -o ../locale/de_DE/LC_MESSAGES/gdm3setup.mo
-msgfmt gdm3setup-it.po -o ../locale/it/LC_MESSAGES/gdm3setup.mo
-msgfmt gdm3setup-pt_BR.po -o ../locale/pt_BR/LC_MESSAGES/gdm3setup.mo
-msgfmt gdm3setup-zh_CN.po -o ../locale/zh_CN/LC_MESSAGES/gdm3setup.mo

0 comments on commit 99dfb89

Please sign in to comment.