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

Multiarch interpreter problem

The proposal for

  Multi-Arch: same
  Architecture: all

Implementation approach:

  Such a package is like a collection of identical .debs for all
  available architectures, all marked
     Multi-Arch: same
     Architecture: <something>

  Normally, such a .deb is treated by dpkg as if it were for the
  native architecture.  There should be an option to change this.

  Also, such a package can be "installed" for an additional
  architecture with
     dpkg --package-add-arch PACKAGE:ARCH
  which actually uses the same path as dpkg --install, except that
  provided that the package is in `unpacked' for some ARCH2,
  the package goes straight to `unpacked' for ARCH without actually
  processing any .deb.

  When the package is upgraded, all architectures for which it is
  better than `config-files' are updated; ie, it is as if all the
  .debs are processed at once.


  At the moment, the reference count passed to prerm scripts is wrong
  and useless.  A new reference count (number of arches strictly
  better than `unpacked') should be provided in a new env var and the
  old one deprecated. 

  In mk1 of the proposal, packages marked M-A:same,Arch:all will not
  be allowed to have conffiles.

I propose the following rewritten description for the M-A field (NB,
may not be true in all places - someone must check!)

The Multi-Arch field gives the packaging system information about the
kind of interfaces exposed to other packages by this package.  The
packaging system uses this to control how dependencies onto this
package are interpreted.

Some packages can be installed multiple-times for different
architectures.  The Multi-Arch field also declares whether this is the

Multi-Arch: no

  This package provides interfaces useable only by code of the same
  architecture; and, it is not multi-arch coinstallable.  (Or, it is
  architecture-specific and has not yet been annotated -- Multi-Arch:
  no is the default for non-Architecture:all packages.)

  (The package satisfies dependencies only from packages of the same
  architecture, or arch:all.)

Multi-Arch: same

  This package provides interfaces useable only by code of the same
  architecture, but to make this easier it has been made

  Each installed arch for this package satisfies dependencies from
  other packages of the same architecture.

  This is the usual marking for packages containing machine code

  When this package is Architecture: all, this means that although the
  physical code in this package is architecture-independent, the
  facilities it provides are useable only on certain architectures.
  This can happen when this package's users and this package's
  architecture-specific dependencies need to be available for the
  /same/ architecture.

  Most obviously, this can happen when this package is a script
  language module which depends on, and is depended on by,
  architecture-specific language extension modules (eg, Perl XS).  An
  XS module which uses this pure Perl package needs this package's
  lower XS dependencies to be set up for the same architecture as the
  top XS module, or it is not useable.

Multi-Arch: foreign

  This package provides interfaces which are useable by code of any
  architecture.  (Or, it is Architecture:all and has not yet been
  annotated -- Multi-Arch: foreign is the default for
  Architecture:all packages.)

  The packaging system will prefer to resolve dependencies on
  Multi-Arch: foreign packages by installing them for a preferred
  architecture, the `native' architecture.

  This package is not coinstallable.

Multi-Arch: allowed

  This package provides a mixture of architecture-specific and
  architecture-independent interfaces.

  Dependencies on this package may be marked with `:any' to indicate
  that they are satisifed by any architecture version of this package
  (ie, that the depending package uses an architecture-neutral
  interface).  If not so marked, they are only satisfied by the
  package of the same architecture (ie, the depending package uses an
  architecture-specific interface).

  This package is not coinstallable.


Reply to: