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

Re: building arch:all packages on the buildd network



On 27/02/14 11:57, Jakub Wilk wrote:
>>> "any" may be interpreted as the prefered arch, which is advised (but
>>> not required) to be amd64. If multiple values are provided, the first
>>> value (only) will be used to build the arch:all package.
>>
>> Any arguments on this rough concept?
> 
> What about architecture wildcards? Could I say
> 
> Build-Architecture-Indep: linux-any
> 
> ?

I don't see why not. If in practice "any" means whatever preferred
architecture is hard-coded in wanna-build or equivalent (currently i386
in Ubuntu, probably amd64 in Debian), then "linux-any" should mean w-b's
favourite Linux architecture (probably amd64 again), "kfreebsd-any"
should mean kfreebsd-amd64, "hurd-any" should mean hurd-i386 and so on.

Pseudocode:

    PREFERRED_ARCHS = [
        "amd64",
        "i386",
        "armhf",          # presumably faster than armel?
        "kfreebsd-amd64",
    ]

    KNOWN_ARCHS = PREFERRED_ARCHS[:]

    for arch in some list of all archs, maybe /usr/share/dpkg/*table:
         if arch not in PREFERRED_ARCHS:
             KNOWN_ARCHS.append(arch)

    def get_build_arch(build_architecture_indep):
        for arch_wildcard in build_architecture_indep:
            for arch in KNOWN_ARCHS:
                if arch_wildcard matches arch:
                    return arch
        raise Unbuildable


Reply to: