[CMake] CPack tar ownership

Tim St. Clair timothysc at gmail.com
Mon Jan 10 10:17:22 EST 2011


Thanks! I think I botched my 1st verification...

fakeroot gives me a root owned package, which expands correctly using
tar --no-same-owner -xzf.

w00t,
Tim

On Sat, Jan 8, 2011 at 8:22 AM, Eric Noulard <eric.noulard at gmail.com> wrote:
> 2011/1/8 Tim St. Clair <timothysc at gmail.com>:
>> This will be across several *nix platforms,
>>
>> I tried fakeroot but when I expand it has the euid of the user.
>
> This is odd, by the way which version of CMake are you using?
>
> On my ubuntu 10.04 box with CMake 2.8.3, I get:
>
> A) cpack -G TGZ
> leads to a tar+gz archive whose content its owned by the user.
> (as printed out using 'tar ztvf file.tgz')
>
> B) fakeroot cpack -G TGZ
> leads to a tar+gz archive whose content its owned by root.
> (as printed out using 'tar ztvf file.tgz')
>
>
> An alternative solution would be to force ownership on extraction,
> GNU tar has the option:
> --no-same-owner
>           extract files as yourself
>
> which should do the job (I suppose you can be root when extracting).
>
>
> Do you have any self contained example which exhibits the problem?
>
> --
> Erk
> Membre de l'April - « promouvoir et défendre le logiciel libre » -
> http://www.april.org
>



-- 
Cheers,
Timothy St. Clair


More information about the CMake mailing list