]> granicus.if.org Git - vim/commitdiff
patch 8.1.1468: the generated desktop files may be invalid v8.1.1468
authorBram Moolenaar <Bram@vim.org>
Wed, 5 Jun 2019 19:25:34 +0000 (21:25 +0200)
committerBram Moolenaar <Bram@vim.org>
Wed, 5 Jun 2019 19:25:34 +0000 (21:25 +0200)
Problem:    The generated desktop files may be invalid.
Solution:   Check validity with desktop-file-validate. (Christian Brabandt,
            Will Thompson, closes #4480)

src/po/Makefile
src/version.c

index 6049b497eae7f6a5c3576fd377eac1f99bc5dc21..8c7066b64ce9e7147e7b7984430e4e523716e500 100644 (file)
@@ -151,7 +151,7 @@ prefixcheck:
 
 clean: checkclean
        rm -f core core.* *.old.po *.mo *.pot sjiscorr
-       rm -f LINGUAS vim.desktop gvim.desktop
+       rm -f LINGUAS vim.desktop gvim.desktop tmp_*desktop
 
 distclean: clean
 
@@ -167,13 +167,17 @@ $(PACKAGE).pot: ../*.c ../if_perl.xs ../GvimExt/gvimext.cpp ../globals.h ../if_p
 
 vim.desktop: vim.desktop.in $(POFILES)
        @echo $(LANGUAGES) | tr " " "\n" |sed -e '/\./d' | sort > LINGUAS
-       $(MSGFMT) --desktop -d . --template vim.desktop.in -o vim.desktop
+       $(MSGFMT) --desktop -d . --template vim.desktop.in -o tmp_vim.desktop
        rm -f LINGUAS
+       if command -v desktop-file-validate; then desktop-file-validate tmp_vim.desktop; fi
+       mv tmp_vim.desktop vim.desktop
 
 gvim.desktop: gvim.desktop.in $(POFILES)
        @echo $(LANGUAGES) | tr " " "\n" |sed -e '/\./d' | sort > LINGUAS
-       $(MSGFMT) --desktop -d . --template gvim.desktop.in -o gvim.desktop
+       $(MSGFMT) --desktop -d . --template gvim.desktop.in -o tmp_gvim.desktop
        rm -f LINGUAS
+       if command -v desktop-file-validate; then desktop-file-validate tmp_gvim.desktop; fi
+       mv tmp_gvim.desktop gvim.desktop
 
 update-po: $(LANGUAGES)
 
index de5e0abbb43de3b2c11849d5cfc12ccc5567ee99..443a114a8f3eb2c211e14627773ed7fc3ba6115c 100644 (file)
@@ -767,6 +767,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1468,
 /**/
     1467,
 /**/