Skip to content

Commit d1c9f36

Browse files
paul-soporanmerceyz
authored andcommitted
docs: document libc in manifest.json schema (#4705)
* docs: document libc in `manifest.json` schema * docs: add more references to libc
1 parent 475cec4 commit d1c9f36

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

packages/gatsby/static/configuration/manifest.json

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,14 @@
6262
},
6363
"_exampleItems": ["x64", "ia32", "arm64"]
6464
},
65+
"libc": {
66+
"description": "A value compared during install with the host standard C library. If the values don't match, the package won't see its postinstall scripts run (if listed in `dependencies`) or won't be installed at all (if listed in `optionalDependencies`).",
67+
"type": "array",
68+
"items": {
69+
"type": "string"
70+
},
71+
"_exampleItems": ["glibc", "musl"]
72+
},
6573
"main": {
6674
"description": "The path that will be used to resolve the qualified path to use when accessing the package by its name. This field can be modified at publish-time through the use of the `publishConfig.main` field.",
6775
"type": "string",
@@ -130,7 +138,7 @@
130138
"_exampleKeys": ["webpack"]
131139
},
132140
"optionalDependencies": {
133-
"description": "Similar to the `dependencies` field, except that these entries will not be required to build properly should they have any build script. Note that such dependencies must always be resolvable (otherwise we couldn't store it in the lockfile, which could lead to non-reproducible installs), but those which list `cpu`/`os` fields will not be fetched unless they match the current system architecture.\n\n**This field is usually not what you're looking for**, unless you depend on the `fsevents` package. If you need a package to be required only when a specific feature is used then use an optional peer dependency. Your users will have to satisfy it should they use the feature, but it won't cause the build errors to be silently swallowed when the feature is needed.",
141+
"description": "Similar to the `dependencies` field, except that these entries will not be required to build properly should they have any build script. Note that such dependencies must always be resolvable (otherwise we couldn't store it in the lockfile, which could lead to non-reproducible installs), but those which list `os` / `cpu` / `libc` fields will not be fetched unless they match the current system architecture.\n\n**This field is usually not what you're looking for**, unless you depend on the `fsevents` package. If you need a package to be required only when a specific feature is used then use an optional peer dependency. Your users will have to satisfy it should they use the feature, but it won't cause the build errors to be silently swallowed when the feature is needed.",
134142
"type": "object",
135143
"patternProperties": {
136144
"^(?:@([^/]+?)/)?([^/]+?)$": {
@@ -189,7 +197,7 @@
189197
"examples": [false]
190198
},
191199
"optional": {
192-
"description": "If true, the build isn't required to succeed for the install to be considered a success, and the dependency may be skipped if its `os` and `cpu` fields don't match the current system architecture. It's what the `optionalDependencies` field compiles down to.\n\n**This settings will be applied even when found within a nested manifest**, but the highest requirement in the dependency tree will prevail.",
200+
"description": "If true, the build isn't required to succeed for the install to be considered a success, and the dependency may be skipped if its `os` / `cpu` / `libc` fields don't match the current system architecture. It's what the `optionalDependencies` field compiles down to.\n\n**This settings will be applied even when found within a nested manifest**, but the highest requirement in the dependency tree will prevail.",
193201
"type": "boolean",
194202
"examples": [false]
195203
},

packages/gatsby/static/configuration/yarnrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -739,7 +739,7 @@
739739
"_exampleItems": ["current", "x64", "ia32"]
740740
},
741741
"libc": {
742-
"description": "The list of standard libraries to cover.",
742+
"description": "The list of standard C libraries to cover.",
743743
"type": "array",
744744
"items": {
745745
"type": "string"

0 commit comments

Comments
 (0)