Corrected an issue in the install.py script. 5_0_x

Fri, 06 Aug 2010 18:55:32 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Fri, 06 Aug 2010 18:55:32 +0200
branch
5_0_x
changeset 462
ac91c502254e
parent 451
bde55078d91e
child 469
a3dd08c7f489

Corrected an issue in the install.py script.

install.py file | annotate | diff | comparison | revisions
--- a/install.py	Sun Aug 01 17:44:13 2010 +0200
+++ b/install.py	Fri Aug 06 18:55:32 2010 +0200
@@ -421,10 +421,14 @@
     # create menu entry for Linux systems
     if sys.platform.startswith("linux"):
         if distDir:
-            shutil.copy(os.path.join("eric", "icons", "default", "eric.png"), 
-                os.path.normpath(os.path.join(distDir, "/usr/share/pixmaps")))
-            shutil.copy(os.path.join("eric", "eric5.desktop"), 
-                os.path.normpath(os.path.join(distDir, "/usr/share/applications")))
+            dst = os.path.normpath(os.path.join(distDir, "usr/share/pixmaps"))
+            if not os.path.exists(dst):
+                os.makedirs(dst)
+            shutil.copy(os.path.join("eric", "icons", "default", "eric.png"), dst)
+            dst = os.path.normpath(os.path.join(distDir, "usr/share/applications"))
+            if not os.path.exists(dst):
+                os.makedirs(dst)
+            shutil.copy(os.path.join("eric", "eric5.desktop"), dst)
         else:
             shutil.copy(os.path.join("eric", "icons", "default", "eric.png"), 
                 "/usr/share/pixmaps")

eric ide

mercurial