LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 11-06-2011, 04:35 AM   #1
rhklinux
Member
 
Registered: Jan 2010
Location: india/pune
Distribution: Arch Fedora20
Posts: 126

Rep: Reputation: 18
Icon addition in debian package system


Ubuntu 10.10
I created a small application and successfully created a debian package using (dpkg -b ). Its going nice,but I want icon of my application in ubuntu main menu->Accessories,I googled about it but cant find any working solution.
Thanks in advance !!
 
Old 11-07-2011, 01:46 AM   #2
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761
Put your icons within the appropriate subdirectories of /usr/share/icons/hicolor/ and your desktop file in /usr/share/applications/. Then have your post install script make the following calls:

update-desktop-database -q /usr/share/applications
gtk-update-icon-cache -tq /usr/share/icons/hicolor

P.S. You should probably have the post install check for the presence of these two helper apps before it attempts to call them.

Last edited by ruario; 11-07-2011 at 01:52 AM.
 
Old 11-07-2011, 01:51 AM   #3
ruario
Senior Member
 
Registered: Jan 2011
Location: Oslo, Norway
Distribution: Slackware
Posts: 2,557

Rep: Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761Reputation: 1761
You will also need a /usr/share/menu/nameofyourapp file if you want this to work with window managers that don't make use of freedesktop.org's Desktop Menu Specification, which would be the majority of smaller window managers.
 
Old 11-13-2011, 01:46 AM   #4
rhklinux
Member
 
Registered: Jan 2010
Location: india/pune
Distribution: Arch Fedora20
Posts: 126

Original Poster
Rep: Reputation: 18
First of all thanks for the advice !
I tried what you told,but unfortunately i got no icon in menu.
here is my postinst
Quote:
#!/bin/sh
update-desktop-database -q /usr/share/applications
gtk-update-icon-cache -tq /usr/share/icons/hicolor
and test.desktop
Quote:
[Desktop Entry]
Name=test
Comment=test
Exec=/usr/bin/test
Name[en_US]=test.desktop
Icon=/usr/share/icons/hicolor/test.png
Categories=Application
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] trying to figure out the Debian.org package system to install gdm Martian Gnome Linux - Software 8 06-11-2010 12:15 AM
compile gentoo package on debian system kpachopoulos Gentoo 3 07-24-2009 04:52 AM
Cannot install virtualbox addition inside a linux guest system hkl8324 Linux - Software 4 12-31-2008 11:01 PM
debian samba package adds system users checkmate3001 Linux - Server 1 07-12-2008 11:53 AM
FC1 Package addition from LAN server chrisjbzero Fedora 1 05-06-2004 02:45 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:54 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration