At Sunday 02 November 2014 17:40:59 Detlev Offenbach wrote: > Can give a detailed feedback on which files are in conflict. Maybe you can > suggest/provide a solution as well (patched install.py script).
Well, I've created a patch (see attachments) which should provide freedesktop compatibility for linux systems. Unfortunately I didn't find usage of API files in eric, so I could not create patch for it. -- Sincerely yours, E.Alekseev email: [email protected] ICQ: 407-398-235 Jabber: [email protected]
diff -ruN eric5-5.5.0.orig/eric/eric5.desktop eric5-5.5.0/eric/eric5.desktop
--- eric5-5.5.0.orig/eric/eric5.desktop 2014-11-03 02:48:01.814339679 +0300
+++ eric5-5.5.0/eric/eric5.desktop 2014-11-03 02:48:20.297673134 +0300
@@ -1,9 +1,9 @@
[Desktop Entry]
Version=1.0
Type=Application
-Exec=eric5
+Exec=eric5$SUFFIX
MimeType=text/x-python;
-Icon=eric
+Icon=eric$SUFFIX
Terminal�lse
Name=eric5
Name[de]=eric5
diff -ruN eric5-5.5.0.orig/eric/eric5_webbrowser.desktop eric5-5.5.0/eric/eric5_webbrowser.desktop
--- eric5-5.5.0.orig/eric/eric5_webbrowser.desktop 2014-11-03 02:48:01.991006347 +0300
+++ eric5-5.5.0/eric/eric5_webbrowser.desktop 2014-11-03 02:48:20.297673134 +0300
@@ -1,9 +1,9 @@
[Desktop Entry]
Version=1.0
Type=Application
-Exec=eric5_webbrowser
+Exec=eric5_webbrowser$SUFFIX
MimeType=text/html;text/xml;application/xhtml+xml;x-scheme-handler/http;x-scheme-handler/https;
-Icon=ericWeb
+Icon=ericWeb$SUFFIX
Terminal�lse
Name=eric5 Web Browser
Name[de]=eric5 Web Browser
diff -ruN eric5-5.5.0.orig/install.py eric5-5.5.0/install.py
--- eric5-5.5.0.orig/install.py 2014-11-03 02:48:02.047673015 +0300
+++ eric5-5.5.0/install.py 2014-11-03 02:48:46.714339974 +0300
@@ -30,6 +30,7 @@
import fnmatch
import distutils.sysconfig
import codecs
+import fileinput
# Define the globals.
progName = None
@@ -702,30 +703,40 @@
except EnvironmentError:
print("Could not install '{0}'.".format(apiName))
+ global includePythonVariant
+
+ if includePythonVariant:
+ marker = PythonMarkers[sys.version_info.major]
+ else:
+ marker = ""
+
# create menu entry for Linux systems
if sys.platform.startswith("linux"):
+ prepareDestkops()
if distDir:
dst = os.path.normpath(os.path.join(distDir, "usr/share/pixmaps"))
if not os.path.exists(dst):
os.makedirs(dst)
shutilCopy(
os.path.join(sourceDir, "icons", "default", "eric.png"),
- os.path.join(dst, "eric.png"))
+ os.path.join(dst, "eric{}.png".format(marker)))
shutilCopy(
os.path.join(sourceDir, "icons", "default", "ericWeb48.png"),
- os.path.join(dst, "ericWeb.png"))
+ os.path.join(dst, "ericWeb{}.png".format(marker)))
dst = os.path.normpath(
os.path.join(distDir, "usr/share/applications"))
if not os.path.exists(dst):
os.makedirs(dst)
- shutilCopy(os.path.join(sourceDir, "eric5.desktop"), dst)
+ shutilCopy(os.path.join(sourceDir, "eric5.desktop"),
+ os.path.join(dst, "eric5{}.desktop".format(marker)))
shutilCopy(os.path.join(sourceDir, "eric5_webbrowser.desktop"),
- dst)
+ os.path.join(dst, "eric5_webbrowser{}.desktop".format(marker)))
dst = os.path.normpath(
os.path.join(distDir, "usr/share/appdata"))
if not os.path.exists(dst):
os.makedirs(dst)
- shutilCopy(os.path.join(sourceDir, "eric5.appdata.xml"), dst)
+ shutilCopy(os.path.join(sourceDir, "eric5.appdata.xml"),
+ os.path.join(dst, "eric5{}.appdata.xml".format(marker)))
elif os.getuid() == 0:
shutilCopy(os.path.join(
sourceDir, "icons", "default", "eric.png"),
@@ -1348,6 +1359,22 @@
exit(res)
+def prepareDestkops():
+ """insert suffix to desktop files"""
+ global includePythonVariant
+ if includePythonVariant:
+ marker = PythonMarkers[sys.version_info.major]
+ else:
+ marker = ""
+
+ for line in fileinput.input(os.path.join(sourceDir, "eric5.desktop"), inplace=True):
+ print("%s" % line.replace("$SUFFIX", marker).rstrip())
+ for line in fileinput.input(os.path.join(sourceDir, "eric5_webbrowser.desktop"), inplace=True):
+ print("%s" % line.replace("$SUFFIX", marker).rstrip())
+ for line in fileinput.input(os.path.join(sourceDir, "eric5.appdata.xml"), inplace=True):
+ print("%s" % line.replace("$SUFFIX", marker).rstrip())
+
+
if __name__ == "__main__":
try:
main(sys.argv)
diff -ruN eric5-5.5.0.orig/eric/eric5.appdata.xml eric5-5.5.0/eric/eric5.appdata.xml
--- eric5-5.5.0.orig/eric/eric5.appdata.xml 2014-05-23 21:12:39.000000000 +0400
+++ eric5-5.5.0/eric/eric5.appdata.xml 2014-11-03 02:51:42.527674460 +0300
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2013 First Lastname <[email protected]> -->
<application>
- <id type="desktop">eric5.desktop</id>
+ <id type="desktop">eric5$SUFFIX.desktop</id>
<metadata_license>CC-BY-3.0</metadata_license>
<project_license>GPL-3.0+</project_license>
<name>eric5</name>
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Eric mailing list [email protected] http://www.riverbankcomputing.com/mailman/listinfo/eric
