[CMake] CMake & RPM problems

Eric Noulard eric.noulard at gmail.com
Wed May 6 12:43:20 EDT 2009


2009/5/6 Florent Lagaye <florent.lagaye at inrialpes.fr>:
> Hi,
>
> Thanks so much, it works now ! I can build an rpm package ! so nice.

Nice to ear, I'll will take time to provide a patch in order to make
the working change go upstream.

> I've got new questions now the I can build the rpm.
>
>     - How can I embed a freedesktop file that links to an icon (svg) ?

I would say that you'll have to put the icon file in your source tree
and to install it with

INSTALL(FILE myicon.svg DESTINATION share/icons)

Then regarding the creation of the link and the "freedesktop file" I don't
know. How does it works? Should you create some sort of special link
to the SVG file?
Do you need to create the "freedesktop file" at installation time,
the concerned will then refer to the installed icon file?

Could you explain us (or point the appropriate documentation)
on how the "freedesktop file" should work?

>     - Where should I put the icon file ?

Like I said I would put the file in the source tree and then

INSTALL(FILE ....) it with appropriate path.

>     - How can I tell CPack to put instruction to update the icon cache after
> installation ?

I bet CPack won't do it but the package used should, in this case RPM
I think it would be a post-install script to be embedded in the RPM.

I have to look into this but if you need such "pre/post install scripts" I bet
the current CPackRPM won't be enough you'll have to patch it to suit
those needs.

We may discuss this and propose appropriate patches to CMake developper.

Whatever the solution how would you "update the icon cache" "by hand",
is there some command to launch?

>     - How can I tell CPack to put instruction to create and associate new
> mime-types ?

Same question as before.

>
> Thanks very much Eric for your answers.

You are welcome.

-- 
Erk


More information about the CMake mailing list