[gnome-terminal/gnome-3-8] build: Validate desktop file on 'make check'



commit 239d7643a2b0324ff4220cefcfc93dfc94483b42
Author: Christian Persch <chpe gnome org>
Date:   Fri Mar 22 12:52:58 2013 +0100

    build: Validate desktop file on 'make check'

 Makefile.am                  |    7 +++++++
 configure.ac                 |    6 ++++++
 gnome-terminal.desktop.in.in |    2 +-
 3 files changed, 14 insertions(+), 1 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index f317baa..8cd1009 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -15,6 +15,13 @@ desktop_in_files = @PACKAGE  desktop in in
 desktop_DATA = $(desktop_in_files:.desktop.in.in=.desktop)
 @INTLTOOL_DESKTOP_RULE@
 
+desktop-file-validate: $(desktop_DATA)
+       for f in $^; do \
+               $(DESKTOP_FILE_VALIDATE) $$f; \
+       done
+
+check-local: desktop-file-validate
+
 EXTRA_DIST =                   \
        ChangeLog.pre-2-23      \
        ChangeLog.README        \
diff --git a/configure.ac b/configure.ac
index baa2d38..c56c531 100644
--- a/configure.ac
+++ b/configure.ac
@@ -168,6 +168,12 @@ if test -z "$XMLLINT"; then
   AC_MSG_ERROR([xmllint not found])
 fi
 
+AC_ARG_VAR([DESKTOP_FILE_VALIDATE],[the desktop-file-validate programme])
+AC_PATH_PROG([DESKTOP_FILE_VALIDATE],[desktop-file-validate],[])
+if test -z "$DESKTOP_FILE_VALIDATE"; then
+  AC_MSG_ERROR([desktop-file-validate not found])
+fi
+
 # ******************
 # Nautilus extension
 # ******************
diff --git a/gnome-terminal.desktop.in.in b/gnome-terminal.desktop.in.in
index 9ba1076..f80d0d0 100644
--- a/gnome-terminal.desktop.in.in
+++ b/gnome-terminal.desktop.in.in
@@ -11,5 +11,5 @@ X-GNOME-Bugzilla-Bugzilla=GNOME
 X-GNOME-Bugzilla-Product=gnome-terminal
 X-GNOME-Bugzilla-Component=BugBuddyBugs
 X-GNOME-Bugzilla-Version= VERSION@
-Categories=GNOME;GTK;Utility;TerminalEmulator;
+Categories=GNOME;GTK;Utility;System;TerminalEmulator;
 StartupNotify=true


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