Skip to content

Commit 73fc1af

Browse files
committed
pkgbuild: document the new references keys
* pypi are not case-insensitive (as long as the normalized form matches it's fine) * mappings can now have duplicate keys, to handle things like multiple cpe/purls better * there are now new keys for cpe and purl
1 parent 5182ad4 commit 73fc1af

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

web/dev/pkgbuild.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,16 +27,19 @@ For `msys2_references` the following keys are recognized:
2727
* `cygwin-mingw64` -
2828
the cygwin package name for all packages starting with "mingw64-x86_64-",
2929
minus that prefix: https://cygwin.com/packages/src_package_list.html
30-
* `pypi` - the PyPI project name: https://pypi.org/search/
30+
* `pypi` - the PyPI project name (case-insensitive): https://pypi.org/search/
3131
* `gentoo` - the full Gentoo package name e.g. `dev-python/pyasn1`
3232
* `internal` - special key, which if it exists marks the package as internal and doesn't link it to any external sources
33+
* `purl` - a [package URL](https://github.com/package-url/purl-spec) e.g. `pkg:cargo/ripgrep` (only cargo supported atm)
34+
Multiple PURLs supported.
35+
* `cpe` - a [CPE](https://en.wikipedia.org/wiki/Common_Platform_Enumeration) prefix, either in the 2.2 format (`cpe: cpe:/a:gnu:gcc`) or the 2.3 format (`cpe:2.3:a:gnu:gcc`). `target_sw` etc are currently not supported. Multiple CPEs supported.
3336

3437
Defining a key without a value means there is no mapping and the package shouldn't be linked.
3538

3639
The following datatypes are supported:
3740

3841
* **string:** `msys2_myvar="example"` 🠆 `{"myvar": "example"}`
3942
* **array:** Arrays of strings: `msys2_myvar=("example1" "example2")` 🠆 `{"myvar": ["example1", "example2"]}`
40-
* **mapping:** Mappings of strings to an optional string, separated by `":"`, values are
41-
stripped: `msys2_myvar=("example1: value1" "example2")` 🠆 `{"myvar": {"example1": "value1", "example2": null}}`
43+
* **mapping:** Mappings of strings to optional other strings, separated by `":"`, values are
44+
stripped: `msys2_myvar=("example1: value1" "example2")` 🠆 `{"myvar": {"example1": ["value1"], "example2": [null]}}`
4245
* **boolean:** either `true` or `false`: `msys2_myvar=true` 🠆 `{"myvar": true}`

0 commit comments

Comments
 (0)