[CMake] how to make OpenGTL rpm?

Matthew Woehlke mw_triad at users.sourceforge.net
Wed Jul 16 18:19:57 EDT 2008


Eric Noulard wrote:
> 2008/7/15 Matthew Woehlke <mw_triad at users.sourceforge.net>:
>>>> but when I try to build the RPM, it wants to write to /usr (ah, shouldn't
>>>> rpm building NOT need to install first?!), and if I run it as root, it
>>>> installs but yields an empty rpm.
> 
> CPack RPM shouldn't try to write to /usr unless there is
> some abolsute installed path _and_ you are not setting
> 
> SET(CPACK_SET_DESTDIR "ON")
> 
>  **** Before include(CPack) ****

D'oh :-). For some reason I was thinking it shouldn't matter. Don't know 
why, I should know better :-). Sorry.

Ok, that's better... except for the gratuitous violations of Fedora 
packaging convention. I suspect it won't be possible to use cpack to 
make Fedora RPM's, at least not without a lot of surgery (for one, 
Fedora needs an SRPM, RPM and -devel RPM, also no RPATH allowed, and no 
RPM's containing common directories, e.g. /usr, /usr/bin, /usr/lib, etc.)

Anyway, thanks for the help! I now have a highly non-canon, but 
installable, rpm that satisfies koffice's check, at least on i*86 (llvm 
is broken on x86_64). Next step is making a proper rpm for Fedora, but I 
suspect that won't involve cpack (should be interesting getting cmake to 
play with Fedora's RPM building :-) ).

-- 
Matthew
I don't see what C++ has to do with keeping people from shooting 
themselves in the foot.  C++ will happily load the gun, offer you a 
drink to steady your nerves, and help you aim. -- Peter da Silva (from 
cluefire.net)



More information about the CMake mailing list