PackageDependency (Windows 10)

Declares a dependency on another package that is marked as a framework package.

Element hierarchy

<Package>
<Dependencies>
<PackageDependency>

Syntax

<PackageDependency Name                   = A string between 3 and 50 characters in length that consists of alpha-numeric, period, and dash characters.
                   Publisher              = A string between 1 and 8192 characters in length that fits the regular expression  of a distinguished name : "(CN | L | O | OU | E | C | S | STREET | T | G | I | SN | DC | SERIALNUMBER | Description | PostalCode | POBox | Phone | X21Address | dnQualifier | (OID\.(0 | [1-9][0-9]*)(\.(0 | [1-9][0-9]*))+))=(([^,+="<>#;])+ | ".*")(, ((CN | L | O | OU | E | C | S | STREET | T | G | I | SN | DC | SERIALNUMBER | Description | PostalCode | POBox | Phone | X21Address | dnQualifier | (OID\.(0 | [1-9][0-9]*)(\.(0 | [1-9][0-9]*))+))=(([^,+="<>#;])+ | ".*")))*". Further, semantic validation ensures that the string is compliant with CertNameToStr Windows API implementation of X.500 rules.
                   MinVersion             = A version string in quad notation, "Major.Minor.Build.Revision".
                   MaxMajorVersionTested? = unsignedShort
                   uap6:Optional? = Boolean />

Key

?   optional (zero or one)

Attributes and Elements

Attributes

Attribute Description Data type Required Default value
MaxMajorVersionTested

The maximum version of the dependency package tested against. Used to determine whether frameworks will be staged side-by-side, and what framework gets loaded into the package graph for the package.

unsignedShort No
MinVersion

The minimum version of the dependency package.

A version string in quad notation, "Major.Minor.Build.Revision". Yes
Name

The name as it appears in the Name attribute of the Identity element of the dependency package.

A string between 3 and 50 characters in length that consists of alpha-numeric, period, and dash characters. Yes
uap6:Optional

Indicates that a framework package dependency is optional for the app, meaning the app can be installed even if the optional framework dependencies are not installed.

Boolean No False
Publisher

The publisher as it appears in the Publisher attribute of the Identity element of the dependency package.

A string between 1 and 8192 characters in length that fits the regular expression of a distinguished name : "(CN | L | O | OU | E | C | S | STREET | T | G | I | SN | DC | SERIALNUMBER | Description | PostalCode | POBox | Phone | X21Address | dnQualifier | (OID\.(0 | [1-9][0-9]*)(\.(0 | [1-9][0-9]*))+))=(([^,+="<>#;])+ | ".*")(, ((CN | L | O | OU | E | C | S | STREET | T | G | I | SN | DC | SERIALNUMBER | Description | PostalCode | POBox | Phone | X21Address | dnQualifier | (OID\.(0 | [1-9][0-9]*)(\.(0 | [1-9][0-9]*))+))=(([^,+="<>#;])+ | ".*")))*". Further, semantic validation ensures that the string is compliant with CertNameToStr Windows API implementation of X.500 rules. Yes

 

Child Elements

None.

Parent Elements

Parent Element Description
Dependencies

Declares other packages that a package depends on to complete its software.

 

Remarks

When working with package dependencies note the following:

  • A package cannot have multiple dependency declarations that have the same Name attribute.
  • If the Publisher attribute is not specified, then the dependency package must be unsigned. When a dependency package is unsigned it must also be marked as a framework package. See the Framework element.
  • The version of the dependency package must be greater than or equal to the minimum version specified by this attribute.

Examples

<Dependencies>
    <PackageDependency Name="Microsoft.WinJS.1.0"
      Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
      MinVersion="1.0.0.0"/>    
</Dependencies>

Requirements

Namespace

http://schemas.microsoft.com/appx/manifest/foundation/windows10