1 |
On 03/14/2015 12:30 PM, Joakim Tjernlund wrote: |
2 |
> On Sat, 2015-03-14 at 11:57 -0700, Zac Medico wrote: |
3 |
>> On 03/14/2015 11:41 AM, Joakim Tjernlund wrote: |
4 |
>>> On Sat, 2015-03-14 at 11:08 -0700, Zac Medico wrote: |
5 |
>>>> On 03/14/2015 09:12 AM, Joakim Tjernlund wrote: |
6 |
>>>>> On Wed, 2015-03-11 at 13:43 -0700, Zac Medico wrote: |
7 |
>>>>>> On 03/11/2015 01:16 PM, Joakim Tjernlund wrote: |
8 |
>>>>>>> On Wed, 2015-03-11 at 10:56 -0700, Zac Medico wrote: |
9 |
>>>>>>>> On 03/11/2015 08:48 AM, Joakim Tjernlund wrote: |
10 |
>>>>>>>>> On Sun, 2015-03-08 at 11:58 -0700, Zac Medico wrote: |
11 |
>>>>>>>>>> On 03/08/2015 10:01 AM, Joakim Tjernlund wrote: |
12 |
>>>>>>>>>>> On Sun, 2015-03-08 at 15:47 +0000, Joakim Tjernlund wrote: |
13 |
>>>>>>>>>>>> |
14 |
>>>>>>>>>>>> package.use/package.use.force is a bit different though: |
15 |
>>>>>>>>>>>> cat /etc/portage/package.use/qemu |
16 |
>>>>>>>>>>>> app-emulation/qemu vde -alsa -pulseaudio -bluetooth -opengl qemu_user_targets_x86_64 |
17 |
>>>>>>>>>>>> xattr |
18 |
>>>>>>>>>>>> virtfs |
19 |
>>>>>>>>>>>> static- |
20 |
>>>>>>>>>>>> user |
21 |
>>>>>>>>>>>> |
22 |
>>>>>>>>>>>> #Needed by static-user |
23 |
>>>>>>>>>>>> sys-libs/zlib static-libs |
24 |
>>>>>>>>>>>> dev-libs/glib static-libs |
25 |
>>>>>>>>>>>> sys-apps/attr static-libs |
26 |
>>>>>>>>>>>> |
27 |
>>>>>>>>>>>> Moving this to package.use/package.use.force does not respect -alsa, -pulseaudio, - |
28 |
>>>>>>>>>>>> opengl |
29 |
>>>>>>>>>>>> all |
30 |
>>>>>>>>>>>> flags which has a - on them, emerge wants to turn them on again. |
31 |
>>>>>>>>>>>> |
32 |
>>>>>>>>>>>> Am I missing something? |
33 |
>>>>>>>>>>>> Using portage 2.2.18 |
34 |
>>>>>>>>>>> |
35 |
>>>>>>>>>>> Appears one have to use package.use.mask for that. |
36 |
>>>>>>>>>>> cat package.use.mask |
37 |
>>>>>>>>>>> app-emulation/qemu alsa pulseaudio bluetooth opengl |
38 |
>>>>>>>>>>> It would be handy if one could use the same syntax as in /etc/portage/package.use/qemu(- |
39 |
>>>>>>>>>>> alsa - |
40 |
>>>>>>>>>>> opengl |
41 |
>>>>>>>>>>> etc.) |
42 |
>>>>>>>>>>> |
43 |
>>>>>>>>>>> Jocke |
44 |
>>>>>>>>>>> |
45 |
>>>>>>>>>> |
46 |
>>>>>>>>>> Yes, the inverted use.mask logic can be confusing if you are not familiar with it. The |
47 |
>>>>>>>>>> negative |
48 |
>>>>>>>>>> flags |
49 |
>>>>>>>>>> have a |
50 |
>>>>>>>>>> special meaning within the context of of portage's "incremental stacking" behavior, so they |
51 |
>>>>>>>>>> can |
52 |
>>>>>>>>>> still |
53 |
>>>>>>>>>> be |
54 |
>>>>>>>>>> useful, though not in the same way that you you attempted to use them. |
55 |
>>>>> |
56 |
>>>>> Just noticed that USE flags in profiles/package.use.mask override everything so this |
57 |
>>>>> USE=thin emerge -av sys-fs/lvm2 |
58 |
>>>>> will not turn on thin if thin is in profiles/package.use.mask |
59 |
>>>>> How can just change the default so a user can easily turn it on ? |
60 |
>>>> |
61 |
>>>> Generally, setting the USE environment variable like that is poor practice, because the setting will |
62 |
>>>> not |
63 |
>>>> persist the next time that you rebuild the package. So, you should set the flag in |
64 |
>>> |
65 |
>>> |
66 |
>>> I know, this was just an example to illustrate that it did not work. |
67 |
>>> |
68 |
>>>> /etc/portage/package.use. You can unmask the flag for lvm2 like this: |
69 |
>>>> |
70 |
>>>> echo "sys-fs/lvm2 -thin" >> /etc/portage/profile/package.use.mask |
71 |
>>> |
72 |
>>> You misunderstand, I have "sys-fs/lvm2 thin" in /etc/portage/profile/package.use.mask |
73 |
>>> and I want a user to able to override this setting, using USE=".." or adding it |
74 |
>>> to their local /etc/portage/package.use file/dir |
75 |
>> |
76 |
>> There's no other way to negate a use mask than to use /etc/portage/profile/{use.mask,package.use.mask} as I |
77 |
>> have described. I don't think that it makes much sense to negate a use mask for a single emerge invocation. |
78 |
>> If you want to do that, then why is the use flag masked anyway? |
79 |
> |
80 |
> I am putting tougher a profile for my company where I want to specify default |
81 |
> USE flags for different apps/libs. Then a user who knows what he/she is doing |
82 |
> should be able to override these defaults. It is not possible as far |
83 |
> as I can tell to override negative USE flags or is there? |
84 |
|
85 |
You can set default USE flags in the profile, and then the users can |
86 |
override those settings locally (both positively and negatively). You |
87 |
should not be using use.mask at all here. The profile can set |
88 |
USE="-flag" in make.defaults, or in packages.use, and the user can |
89 |
override that without having to mess with use.mask. |
90 |
-- |
91 |
Thanks, |
92 |
Zac |