From: Zac Medico Date: Tue, 31 Jul 2012 22:01:43 +0000 (-0700) Subject: Check for desktop-file-validate binary. X-Git-Tag: v2.2.0_alpha121~22 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=19e828fc178f0e55174ae923f6ba9a357fc86885;p=portage.git Check for desktop-file-validate binary. --- diff --git a/pym/portage/package/ebuild/doebuild.py b/pym/portage/package/ebuild/doebuild.py index dfdfedcbd..395e0eeec 100644 --- a/pym/portage/package/ebuild/doebuild.py +++ b/pym/portage/package/ebuild/doebuild.py @@ -1749,6 +1749,8 @@ def _post_src_install_uid_fix(mysettings, out): ed_len = len(mysettings["ED"]) desktopfile_errors = [] unicode_errors = [] + desktop_file_validate = \ + portage.process.find_binary("desktop-file-validate") is not None while True: @@ -1796,7 +1798,8 @@ def _post_src_install_uid_fix(mysettings, out): else: fpath = os.path.join(parent, fname) - if fname.endswith(".desktop") and os.path.isfile(fpath): + if desktop_file_validate and fname.endswith(".desktop") and \ + os.path.isfile(fpath): desktop_validate = validate_desktop_entry(fpath) if desktop_validate: desktopfile_errors.extend(desktop_validate)