[gnome-boxes] Validate desktop file during build



commit b06dc836dbb9b4ba40446619b8f7bf54fc139be3
Author: Christophe Fergeau <cfergeau redhat com>
Date:   Wed Feb 20 11:35:23 2013 +0100

    Validate desktop file during build
    
    This is the second time that Boxes ship a tarball with an invalid
    desktop file because of tranlation issues.
    Better to run desktop-file-validate during build to detect such problems
    early.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=694254

 configure.ac     |    1 +
 data/Makefile.am |    3 +++
 2 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index d750f22..884483f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -20,6 +20,7 @@ AC_PROG_CC
 AM_PROG_CC_C_O
 AC_PROG_CXX
 AM_PROG_AR
+AC_CHECK_TOOL([DESKTOP_FILE_VALIDATE], [desktop-file-validate], [/bin/true])
 
 # Initialize libtool
 LT_PREREQ([2.2])
diff --git a/data/Makefile.am b/data/Makefile.am
index 95b0fb0..cb2ea26 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -6,6 +6,9 @@ desktop_in_files = gnome-boxes.desktop.in
 desktop_DATA     = $(desktop_in_files:.desktop.in=.desktop)
 @INTLTOOL_DESKTOP_RULE@
 
+all-local: $(desktop_DATA)
+       @$(DESKTOP_FILE_VALIDATE) $(desktop_DATA)
+
 gsettings_SCHEMAS = org.gnome.boxes.gschema.xml
 @INTLTOOL_XML_NOMERGE_RULE@
 @GSETTINGS_RULES@


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