On Sun, Jul 11, 2010 at 02:42:44PM -0500, Jon Nelson wrote:
On Sun, Jul 11, 2010 at 2:29 PM, Jon Nelson
wrote: On Sun, Jul 11, 2010 at 10:23 AM, Robert Xu
wrote: On Jul 11, 2010, at 11:10, Jon Nelson
wrote: On Sun, Jul 11, 2010 at 3:10 AM, Jan Engelhardt
wrote: On Sunday 2010-07-11 01:09, Jon Nelson wrote:
Macros:
%define fooversion 25 fooversion 25
Because it's supposed to be
%fooversion 25
and that only.
OK. I was patterning things after what I found here:
osc meta prjconf CentOS:CentOS-5
although I got it partly wrong (I had the %define line after Macros:).
The output from that command has the following (pasted exactly, minus the '=' lines):
======
Substitute: popt-devel popt
%define centos_version 501
Macros: %opensuse_bs 1 %centos_version 501 %_vendor redhat
======
According to the docs, the "%define centos_version 501" line is usable *only* in the project config, and the macros defined after the "Macros:" line are usable in spec files as though they appeared in .rpmmacros.
Is that correct?
OK, but what about my other questions. Are they stacked or appended somehow?
Let's say I have FooDistro-1.0 and FooDistro-2.0 (these are for sources only, no packages get built). Let's say I have stuff:apple and stuff:banana. stuff:apple has build repos for both FooDistro versions. stuff:banana only makes use of stuff:apple.
In both FooDistro project configs, following "Macros:", I have:
%foodistro_version 10 %define foodistro_version 10
I've given it a try and it does not appear to be stacking the way I expect, or I'm doing it wrong.
I have the following projects:
A B C and D.
A and B are different versions of the same base distro. C has A and B as build repositories. D has C has a build repository.
A and B have project configs that look like this:
A has this:
%define foo_version 10
and that line does not follow the Macros: line.
B has this:
%define foo_version 20
and that line does not follow the Macros: line.
C has this as it's *only* project config:
%if 0%{?foo_version} == 10 Substitute: packageA packageB %endif
%if 0%{?foo_version} == 20 Substitute: packageB packageA %endif
However, packages built in project C for repo A (which should have foo_version 10) are using packageB. If the Substitute directive was being followed, that should not be.
How do I debug this? It feels like a black box and I've tried lots of permutations without luck.
Run osc api build/C/A/_buildconfig and check if the concatenated configs look like you want them to look. Cheers, Michael. -- Michael Schroeder mls@suse.de SUSE LINUX Products GmbH, GF Markus Rex, HRB 16746 AG Nuernberg main(_){while(_=~getchar())putchar(~_-1/(~(_|32)/13*2-11)*13);} -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org