Hi,

attached you can find a patch which installs a freedesktop desktop file for 
cmake-gui together with an icon, so that cmake should appear in the start 
menus of KDE, Gnome, etc. (tested with KDE 3.5)

I'm not sure if the desktop file should just call "cmake-gui" in Exec, or if 
it should be a configured file with the full path to cmake-gui, e.g. 
Exec=/opt/cmake-HEAD/bin/cmake-gui .
Comments ?

Please apply.

Alex
? cmake.desktopfile.patch
Index: CMake.desktop
===================================================================
RCS file: CMake.desktop
diff -N CMake.desktop
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ CMake.desktop	5 Mar 2008 00:18:57 -0000
@@ -0,0 +1,13 @@
+[Desktop Entry]
+Version=1.0
+Encoding=UTF-8
+Name=CMake
+Comment=Cross Platform Buildsystem
+Exec=cmake-gui %F
+Icon=CMakeSetup.png
+Terminal=false
+X-MultipleArgs=false
+Type=Application
+Categories=Application;Development;
+StartupNotify=true
+MimeType=application/x-cmakecache;
Index: CMakeLists.txt
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/QtDialog/CMakeLists.txt,v
retrieving revision 1.15
diff -b -u -p -r1.15 CMakeLists.txt
--- CMakeLists.txt	19 Feb 2008 19:26:20 -0000	1.15
+++ CMakeLists.txt	5 Mar 2008 00:18:57 -0000
@@ -66,6 +66,14 @@ ELSE(NOT QT4_FOUND)
     INSTALL(TARGETS cmake-gui RUNTIME DESTINATION bin
     ${CMAKE_INSTALL_DESTINATION_ARGS})
   ENDIF(CMAKE_PACKAGE_QTGUI)
+
+  IF(UNIX)
+    # install a desktop file so CMake appears in the application start menu
+    # with an icon
+    INSTALL(FILES CMake.desktop DESTINATION share/applications )
+    INSTALL(FILES CMakeSetup.png DESTINATION share/pixmaps )
+  ENDIF(UNIX)
+
   IF(APPLE)
     SET(CMAKE_POSTFLIGHT_SCRIPT
       "${CMake_BINARY_DIR}/Source/QtDialog/postflight.sh")
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to