You are not logged in.

#1 2006-03-28 05:10:50

elasticdog
Member
From: Washington, USA
Registered: 2005-05-02
Posts: 995
Website

How to include a .desktop file for a Java-based PKGBUILD?

I've tried searching a for a while and can't seem to get anywhere with such generic search terms, but I was wondering what would be the proper way to include a .desktop file and possibly an icon for a PKGBUILD that is just a Java-based program?  I think it would be a lot more user-friendly for people if I could add  the program to their menu when they install it.

As things are right now, the PKGBUILD just creates an executable script in <code>/usr/bin/</code> that runs the jar file with the proper classpath (as per the Java Packaging Guidelines), and there is nothing to actually make/compile (thus no .desktop file directly from the author).  The package I plan on adding these features to is jGnash in the AUR if you want to take a look.  Thanks!

Offline

#2 2006-03-28 06:17:40

Cerebral
Forum Fellow
From: Waterloo, ON, CA
Registered: 2005-04-08
Posts: 3,108
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

If you're wondering about paths, for the mostpart I've seen the .desktop files go into /usr/share/applications and the icons into /usr/share/icons.

Offline

#3 2006-03-28 06:20:31

WillySilly
Member
Registered: 2005-01-14
Posts: 268

Re: How to include a .desktop file for a Java-based PKGBUILD?

Cerebral, icons for apps go in /usr/share/pixmaps. /usr/share/icons is for icon themes like Tango, etc

Offline

#4 2006-03-28 08:50:35

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: How to include a .desktop file for a Java-based PKGBUILD?

I think the cleanest way to do this is to provide the icon and .desktop files in your tarball, list them in your source array, and add install commands to the PKGBUILD. I have seen other submissions where the .desktop file is created in the PKGBUILD, but personally I'd use the first method.

Offline

#5 2006-03-28 08:53:40

_Gandalf_
Member
Registered: 2006-01-12
Posts: 735

Re: How to include a .desktop file for a Java-based PKGBUILD?

I'm with tomk idea, I always provide .desktop/icon files within packages if they don't generate one, and a simple install command to /usr/share/{applications,pixmaps} in the PKGBUILD

Offline

#6 2006-03-28 13:19:31

arooaroo
Member
From: London, UK
Registered: 2005-01-13
Posts: 1,268
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

Good tip. We ought to find a good place in the wiki for this info.

Offline

#7 2006-03-28 13:31:09

Cerebral
Forum Fellow
From: Waterloo, ON, CA
Registered: 2005-04-08
Posts: 3,108
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

WillySilly wrote:

Cerebral, icons for apps go in /usr/share/pixmaps. /usr/share/icons is for icon themes like Tango, etc

Er... yes.  Wow.  That's what I get for trying to post something at 1 in the morning after going nuts working on an assignment.  tongue

/usr/share/pixmaps is indeed where I've noticed most icons going, not /usr/share/icons.  :oops:

Offline

#8 2006-03-28 16:00:19

elasticdog
Member
From: Washington, USA
Registered: 2005-05-02
Posts: 995
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

Awesome...thanks for the advice everyone.

Offline

#9 2006-03-28 23:32:45

mpie
Member
From: 404 Not found
Registered: 2005-03-06
Posts: 649

Re: How to include a .desktop file for a Java-based PKGBUILD?

BTW elasticdog, where did you find the info on java packaging??
I've crawled over the forums and wiki but haven't been able to find it

Offline

#10 2006-03-29 00:02:42

elasticdog
Member
From: Washington, USA
Registered: 2005-05-02
Posts: 995
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

It took me a little while to track it down again too big_smile  You can find the guidelines here: http://www.buchuki.com/misc/archjava.html

If I get bored later tonight, I'll try to convert that document over to the wiki...

Offline

#11 2006-03-29 00:14:55

mpie
Member
From: 404 Not found
Registered: 2005-03-06
Posts: 649

Re: How to include a .desktop file for a Java-based PKGBUILD?

Cheers  big_smile

Offline

#12 2006-03-29 00:16:39

Dusty
Schwag Merchant
From: Medicine Hat, Alberta, Canada
Registered: 2004-01-18
Posts: 5,986
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

elasticdog wrote:

If I get bored later tonight, I'll try to convert that document over to the wiki...

That would be wonderful! I hope boredom sets in! wink

Dusty

Offline

#13 2006-03-29 02:37:45

elasticdog
Member
From: Washington, USA
Registered: 2005-05-02
Posts: 995
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

Done...the newly packaged jGnash personal finance manager has been properly updated in the AUR to include an icon and a .desktop file.  Thanks for all the help with that one mateys!

Offline

#14 2006-04-03 03:27:12

elasticdog
Member
From: Washington, USA
Registered: 2005-05-02
Posts: 995
Website

Re: How to include a .desktop file for a Java-based PKGBUILD?

elasticdog wrote:

It took me a little while to track it down again too big_smile  You can find the guidelines here: http://www.buchuki.com/misc/archjava.html

If I get bored later tonight, I'll try to convert that document over to the wiki...

Took me a couple days to get bored, but tonight I added and slightly edited the Java Package Guidelines to the Wiki...

Offline

Board footer

Powered by FluxBB