Hi! On Wed, 2025-11-26 at 12:50:28 +0100, Guillem Jover wrote: > On Wed, 2025-11-26 at 12:13:24 +0100, Matthias Klose wrote: > > Do you also agree that the syntax that I used is wrong, and should > > be rejected? > > Yes, that syntax has never been correct, has never worked, and you will > not find any example in Debian packages using it. If it gets accepted > by tools, then I guess those need to be improved to reject it. > > There's also the deb-src-control(5) man page, which describes the > correct syntax, although I've had pending to split the build depends > syntax into its own man page, and try to make the build profiles one > a bit easier to understand. > > (The dsc(5) man page describes something that might resemble what you > used, but I see it does not mention explicitly that the angles get > stripped, I'll improve that.)
Something like the attached patch, probably. Thanks, Guillem
diff --git i/man/deb-src-control.pod w/man/deb-src-control.pod index 8f459c607..775ba7e14 100644 --- i/man/deb-src-control.pod +++ w/man/deb-src-control.pod @@ -336,16 +336,20 @@ for equal to. An architecture specification consists of one or more architecture names, separated by whitespace. -Exclamation marks may be prepended to each of the -names, meaning “NOT”. +Exclamation marks (B<!>) may be prepended to each of the names, +meaning “NOT”. -A restriction formula consists of one or more restriction lists, separated -by whitespace. -Each restriction list is enclosed in angle brackets. -Items -in the restriction list are build profile names, separated by whitespace -and can be prefixed with an exclamation mark, meaning “NOT”. -A restriction formula represents a disjunctive normal form expression. +A restriction formula consists of one or more restriction lists, +separated by whitespace. +Each restriction list is enclosed in angle brackets (B<E<lt>> and B<E<gt>>). +Items in the restriction list are build profile names, +separated by whitespace +and can be prefixed with an exclamation mark (B<!>), +meaning “NOT”. +A restriction formula represents a disjunctive normal form expression, +that is whitespace inside enclosed angle brackets is read as “AND”, +and whitespace between enclosing angle brackets is read as “OR“, +such as “B<E<lt>>foo AND barB<E<gt>> OR B<E<lt>>quux AND bazB<E<gt>>”. Note that dependencies on packages in the B<build-essential> diff --git i/man/dsc.pod w/man/dsc.pod index 0afe5f0ab..2989a038e 100644 --- i/man/dsc.pod +++ w/man/dsc.pod @@ -238,8 +238,10 @@ field, with spaces converted to ‘,’. =item B<profile> The normalized build-profile restriction formula from the binary package -B<Build-Profile> field, with ORs converted to ‘+’ and ANDs to -‘,’. +B<Build-Profile> field, +with ANDs (whitespace inside enclosed angle brackets) converted to ‘,’, +and ORs (whitespace between enclosing angle brackets) to ‘+’. +All angle brackets get removed during normalization. =item B<protected>

