[wpkg-users] issue with 1.2.1-RC25?

Rainer Meier r.meier at wpkg.org
Fri Oct 21 20:53:53 CEST 2011


Hi Stefan,

On 21.10.2011 20:22, Stefan Pendl wrote:
>>> The order of variable evaluation is as follows:
>>>
>>> 1) package variables
>>> 2) profile variables
>>> 3) host variables
>>
>> Now this is clearly defined:
>> - WPKG reads all host variables applying to the current host
>> - WPKG reads all profile variables applying to the current host
>> - WPKG reads all package variables
>>
>
> Rainer,
>
> Does it still support overwriting package variables at a higher level?

Yes, at least it's supposed to. WPKG will now collect all variable definitions 
in order into a dictionary object. If for example a package defines the same 
variable name as the profile, then it will be replaced.

E.g. before reading the package
HOST:    SOFTWARE
          SETTINGS
          VAR1
          VAR2
PROFILE: VAR3
          VAR4


Then a package which replaces SOFTWARE:
HOST:    SETTINGS
          VAR1
          VAR2
PROFILE: VAR3
          VAR4
PACKAGE: SOFTWARE


Then WPKG starts to evaluate the variables. So as you see you have to be careful 
since the SOFTWARE variable in this case cannot be used any more by SETTINGS, 
VAR1, VAR2... as it will be defined as the last variable in the list.


Hmm, actually when I think about this is not ideal... Let me think about this.

br,
Rainer



More information about the wpkg-users mailing list