1 |
On Monday 14 December 2009 15:02:22 Shinkan wrote: |
2 |
> Hi everyone, |
3 |
> |
4 |
> I wanted to submit this as a bug on bugzilla, but I must be sure there is |
5 |
> nothing that I miss. |
6 |
> |
7 |
> Let's say I have a /target dir. |
8 |
> If I do 'emerge --root=/target <someport>' (cross-emerge), and that |
9 |
> <someport> is supposed to create users (like vixie-cron, clamav or many |
10 |
> others), users are not created on /target. I can verify that by chrooting |
11 |
> on /target and making something that requires this user (such as launching |
12 |
> clamd for clamav), or simply by looking at /target/etc/passwd to see that |
13 |
> there's no expected users. |
14 |
> |
15 |
> Am I missing somethings or is this really a bug ? |
16 |
|
17 |
What you are trying to do makes no sense. You are either cross-compiling for |
18 |
chroot-type purposes or cross-compiling for a different machine and arch. |
19 |
|
20 |
If it's the former, you do not need or want an /etc/passwd in the chroot - you |
21 |
start such things with the EUID of the intended user from the starts. |
22 |
|
23 |
If it's for another machine, what good will a passwd file be? What are you |
24 |
going to do with it? You certainly can't copy it to the target intact, you |
25 |
can't cat and append it to the passwd file on the target host, in fact you |
26 |
cannot make any assumptions about the target at all, not even that a passwd |
27 |
file is present there. |
28 |
|
29 |
The only thing you can do in that case is write an installer script that takes |
30 |
you tar.bz2, unpacks it on the target and then checks the status there and |
31 |
runs useradd as necessary depending on what it finds. |
32 |
|
33 |
|
34 |
-- |
35 |
alan dot mckinnon at gmail dot com |