[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: build profile syntax ideas



+++ Guillem Jover [2013-08-16 14:15 +0200]:
> Hi!
> 
> On Fri, 2013-08-16 at 02:59:45 +0100, Wookey wrote:
> > In the interests of making some progress, I suggest that we simply say
> > that arches and profiles can't be mixed in a [], as otherwise we'd
> > have to change the dpkg API, and no-one seems very keen on that. 
> > 
> > Yes it would be nicer, but no-one has thought of a case where it's
> > important. We didn't need any such thing with the <> syntax, so if the
> > dpkg maintainers want to avoid changing the API, and we can do that by
> > only accepting a slightly stricter syntax, then lets do that.
> > 
> > The current iteration of the Spec, after some refinement at debconf, is here:
> > https://wiki.debian.org/BuildProfileSpec
> 
> I've not checked that yet, will try to do that during this weekend.
> ISTM I had an issue with the new field being Profile instead of
> Build-Profile, for example. Will need to check my notes.

The concept was that it was used the same way that 'Architecture' is
currently. In source packages it indicates what you can build for, and
in binary packages what it was built for. And we don't bother calling
that 'build-architecture', so that same logic was follow for
'profile'. But either name is file with us. 

> > So I think I am suggesting that the entry "We propose that literals of
> > different namespaces can be mixed within a disjunction. Therefore, the
> > following would be legal:
> > 
> > Build-Depends foo [arch.i386 !profile.cross]"
> > 
> > Is changed to say that you can't do that, and have to do [i386]
> > [!profile.cross] instead.

Josch is just making this change now. And will post that to d-devel as
that what we said we'd do when the original proposal was posted. 

> I've been pondering about the (old) updated proposal, and while I can
> see Ian's argument and can agree with the problems he presents, I
> can't really see using a syntax like «pkg [foo] [bar]» as something
> desirable given the current context. I'd expect the failure modes for
> those to be silent, and it might imply wrongly parsed or computed
> depdendencies. I want old tools to break spectacularly so that they
> can be spotted and fixed. Using the same bracket characters for
> different blocks on the same dependency also seems confusing, and
> mixing different namespaces for something that has only expected
> architecture up to now more so.
> 
> While the bracket characters are limited, and using <> can be
> considered to waste them when we could reuse others, it's the cleaner
> and safer option. And I'm fine with allowing any namespace there, not
> just build profiles, so that we can have a slightly more future proof
> syntax. We could even consider switching from [] to <arch.foo> if
> desired for example.

OK. So - how do we proceed from here? Various thing are blocked on
agreeing and implementing this in dpkg in the archive so I'd really
like to try and get some code and mechanism we can all live with,
without spending another 6 months on it.

Either syntax could work fine so far as I can see. As you say, [] will
not break existing tools (maybe), <> will and either of those could be
an advantage depending on your POV. ([] can be upoaded sooner, but may
do unexpected things, <> can not be uploaded at all until explitictly
understood, but breakage will be obvious). 

Should we write updated patches for the above '[profile:]' proposal, or change it
to be essentially the same (i.e with a namespace, to allow for future
expansion) but using <> ? i.e. '<profile:>' as opposed to the original
'<>' ?

Would it be OK to miss out the namespace identifier for profiles, as
we do for arches in []? (which makes for a simple default syntax).
Perhaps that's a bad idea.

Wookey
-- 
Principal hats:  Linaro, Emdebian, Wookware, Balloonboard, ARM
http://wookware.org/


Reply to: