Permalink
Browse files

add autostart destktop file

  • Loading branch information...
1 parent 6c092d5 commit c2562c6a5bca7646c82651fad3c95bb3858aeae9 @poliva committed Jun 8, 2012
Showing with 45 additions and 1 deletion.
  1. +30 −1 Makefile
  2. +15 −0 indicator-sysbat.desktop
View
31 Makefile
@@ -1,10 +1,39 @@
-CC=gcc
+DESTDIR?=/
+SHELL = /bin/sh
+CC?=gcc
CFLAGS=-Wall -Wextra -Wwrite-strings -O -g $(shell pkg-config --cflags --libs gtk+-3.0 appindicator3-0.1 libgtop-2.0) -lsensors
+INSTALL = /usr/bin/install -c
+INSTALLDATA = /usr/bin/install -c -m 644
+PROGNAME = indicator-sysbat
+
+srcdir = .
+prefix = $(DESTDIR)
+bindir = $(prefix)/usr/bin
+docdir = $(prefix)/usr/share/doc
+mandir = $(prefix)/usr/share/man
all: indicator-sysbat
indicator-sysbat: indicator-sysbat.c
$(CC) $< $(CFLAGS) -o $@
+install: all
+ mkdir -p $(bindir)
+ $(INSTALL) $(PROGNAME) $(bindir)/$(PROGNAME)
+ mkdir -p $(prefix)/etc/xdg/autostart/
+ $(INSTALLDATA) $(PROGNAME).desktop $(prefix)/etc/xdg/autostart/
+ mkdir -p $(docdir)/$(PROGNAME)/
+ $(INSTALLDATA) $(srcdir)/README.md $(docdir)/$(PROGNAME)/
+ $(INSTALLDATA) $(srcdir)/LICENSE $(docdir)/$(PROGNAME)/
+# mkdir -p $(mandir)/man1/
+# $(INSTALLDATA) $(srcdir)/$(PROGNAME).1 $(mandir)/man1/
+
+uninstall:
+ rm -rf $(bindir)/$(PROGNAME)
+ rm -rf $(prefix)/etc/xdg/autostart/$(PROGNAME).desktop
+ rm -rf $(docdir)/$(PROGNAME)/
+# rm -rf $(mandir)/man1/$(PROGNAME).1
+
+
clean:
rm -f *.o indicator-sysbat
View
15 indicator-sysbat.desktop
@@ -0,0 +1,15 @@
+[Desktop Entry]
+Type=Application
+Exec=/usr/bin/indicator-sysbat
+Icon=
+Categories=
+Hidden=false
+NoDisplay=false
+Terminal=false
+X-GNOME-Autostart-enabled=true
+X-KDE-autostart-after=panel
+X-KDE-StartupNotify=false
+Name[en_US]=indicator-sysbat
+Name=indicator-sysbat
+Comment[en_US]=a simple indicator showing CPU, Memory, Battery and fan speed.
+Comment=a simple indicator showing CPU, Memory, Battery and fan speed.

0 comments on commit c2562c6

Please sign in to comment.