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

Re: Debian vs. Ubuntu source control file

Lucas Nussbaum <lucas@lucas-nussbaum.net> writes:

> Modifying the source stanza is debian/control is clearly a bad idea. But
> for binary stanzas, debian/control is only a template from which
> DEBIAN/control is generated. If tools get information about binary
> packages using debian/control, then it's probably a bug (lintian is a
> different case, because it analyzes the build process itself, and makes
> assumptions about what the maintainer is doing. However, misleading
> lintian into thinking something about your package is not a serious
> issue).

Lintian tries to keep its analysis of debian/control to only those things
that it can't figure out for one reason or another from the generated
*.dsc or debian/CONTROL files precisely because doing that parsing and
drawing inferences from it are tricky.

> Anyway, to avoid modifying debian/control directly, it's easy to add an
> additional substvar (ubuntu:Browser?):
> debian/control:
> Depends: [...], iceweasel | ${ubuntu:Browser}

> debian/rules:
>  if dpkg-vendor --is ubuntu; then \
>    echo "ubuntu:Browser=abrowser" >> debian/feed2imap.substvars ;\
>  fi

Yeah, that's what I was thinking of suggesting.

I am personally not horribly fond of a package building differently on
Debian or Ubuntu via only this mechanism, though.  I think it violates a
very important invariant:  the same package with the same version number
will have the same contents.  It's normally possible to freely mix Debian
and Ubuntu packages provided that the dependencies are met, but if the
Debian and Ubuntu packages have different contents despite being
indistinguishable from the perspective of the package manager, that makes
it extremely difficult to do that.  Now, every system must be exclusively
Debian or Ubuntu or risk getting inconsistent packages that can't be
distinguished from each other.

Maybe there's some way that could also be addressed, such as by having the
source package build binary packages with a different version number
depending on what platform on which they're built?  Add "ubuntu" to the
end of the source version number to form the binary version number if
built on Ubuntu, for instance?

Russ Allbery (rra@debian.org)               <http://www.eyrie.org/~eagle/>

Reply to: