[libmetaterm] rootshell: Install the .desktop file



commit f9a04787e578b228bb8efb2531ae96d16bfbfc24
Author: Colin Walters <walters verbum org>
Date:   Thu Jun 2 22:58:27 2011 -0400

    rootshell: Install the .desktop file

 .gitignore                         |    1 +
 Makefile-apps.am                   |    6 ++++++
 apps/metaterm-rootshell.desktop.in |    2 +-
 3 files changed, 8 insertions(+), 1 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index b734a40..c478bae 100644
--- a/.gitignore
+++ b/.gitignore
@@ -29,3 +29,4 @@ xmldocs.make
 libmetaterm-1.pc
 metaterm-basic-app
 metaterm-rootshell
+metaterm-rootshell.desktop
diff --git a/Makefile-apps.am b/Makefile-apps.am
index e1ebc9d..2dd2140 100644
--- a/Makefile-apps.am
+++ b/Makefile-apps.am
@@ -13,6 +13,12 @@ metaterm_rootshell_LDADD = $(common_app_libs)
 metaterm_rootshell_SOURCES = \
 	apps/metaterm-rootshell.c
 
+appsdir=$(datadir)/applications
+apps_DATA = metaterm-rootshell.desktop
+
+metaterm-rootshell.desktop: apps/metaterm-rootshell.desktop.in
+	sed -e s,%bindir%,$(bindir), < $< > $  tmp && mv $  tmp $@
+
 noinst_PROGRAMS += metaterm-basic-app
 metaterm_basic_app_CFLAGS = $(common_app_cflags)
 metaterm_basic_app_LDADD = $(common_app_libs)
diff --git a/apps/metaterm-rootshell.desktop.in b/apps/metaterm-rootshell.desktop.in
index 61975f8..f4b97fc 100644
--- a/apps/metaterm-rootshell.desktop.in
+++ b/apps/metaterm-rootshell.desktop.in
@@ -2,5 +2,5 @@
 Type=Application
 Name=Root Shell
 _Comment=Log in as root in a terminal
-Exec= bindir@/metaterm-rootshell
+Exec=%bindir%/metaterm-rootshell
 Categories=GNOME;GTK;Utility;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]