Skip to content

Commit 67e571a

Browse files
authored
Merge pull request #2155 from h-vetinari/stdlib
First iteration of stdlib docs
2 parents 5003dd8 + bdcad84 commit 67e571a

File tree

3 files changed

+29
-18
lines changed

3 files changed

+29
-18
lines changed

docs/maintainer/knowledge_base.md

Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1727,15 +1727,15 @@ but with `10.9` as the deployment target.
17271727
WARNING: some packages might use features from `10.12` if you do the above due to
17281728
buggy symbol availability checks. For example packages looking for `clock_gettime`
17291729
will see it as it will be a weak symbol, but the package might not have a codepath
1730-
to handle the weak symbol, in that case, you need to update the `MACOSX_DEPLOYMENT_TARGET`
1731-
as described below.
1730+
to handle the weak symbol, in that case, you need to update the `c_stdlib_version`
1731+
(previously `MACOSX_DEPLOYMENT_TARGET`) as described below.
17321732
17331733
After increasing the SDK version, if you are getting an error that says that a function
17341734
is available only for macOS x.x, then do the following in `recipe/conda_build_config.yaml`,
17351735
17361736
```yaml
17371737
# Please consult conda-forge/core before doing this
1738-
MACOSX_DEPLOYMENT_TARGET: # [osx and x86_64]
1738+
c_stdlib_version: # [osx and x86_64]
17391739
- "10.12" # [osx and x86_64]
17401740
MACOSX_SDK_VERSION: # [osx and x86_64]
17411741
- "10.12" # [osx and x86_64]
@@ -1745,13 +1745,12 @@ In `recipe/meta.yaml`, add the following to ensure that the user's system is com
17451745

17461746
```yaml
17471747
requirements:
1748-
run:
1749-
- __osx >={{ MACOSX_DEPLOYMENT_TARGET|default("10.9") }} # [osx and x86_64]
1748+
build:
1749+
- {{ stdlib("c") }}
17501750
```
17511751

1752-
Note that this requires `conda>=4.8`. If you want to support older conda versions
1753-
the requirement should be changed from `run` to `run_constrained`. Note that
1754-
`conda<4.8` will ignore the condition if it's a `run_constrained` on `__osx`.
1752+
Note that the run-export on `__osx` that's produced by the stdlib metapackages
1753+
requires `conda>=4.8`.
17551754

17561755
<a id="newer-c-features-with-old-sdk"></a>
17571756

@@ -1874,10 +1873,20 @@ put the following in your build section.
18741873
requirements:
18751874
build:
18761875
- {{ compiler('c') }}
1877-
- sysroot_linux-64 2.17 # [linux64]
1876+
- {{ stdlib('c') }}
18781877
```
18791878

1880-
You also need to use a newer docker image by setting the following in the `conda-forge.yml`
1879+
and add the following to `recipe/conda_build_config.yaml`:
1880+
1881+
```yaml
1882+
c_stdlib_version: # [linux]
1883+
- "2.17" # [linux]
1884+
```
1885+
1886+
This covers the headers/library present at build-time, and will also create
1887+
a corresponding run-export on the `__glibc` virtual package.
1888+
1889+
You may also need to use a newer docker image by setting the following in the `conda-forge.yml`
18811890
of your recipe and rerendering.
18821891

18831892
```yaml

news/2024-01-29-rust-175-osx-sdk.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,18 @@ With the release of `rust 1.75`, we now require setting the minimal
55
`recipe/conda_build_config.yaml` with the following content:
66

77
```yaml
8-
MACOSX_DEPLOYMENT_TARGET: # [osx and x86]
9-
- '10.12' # [osx and x86]
8+
c_stdlib_version: # [osx and x86]
9+
- '10.12' # [osx and x86]
1010
```
1111
12-
You should also add a run dependency on the respective OSX version:
12+
and adding `{{ stdlib("c") }}` as build dependency next to your compiler jinja:
1313

1414
```yaml
15-
run:
16-
- __osx >={{ MACOSX_DEPLOYMENT_TARGET|default("10.9") }} # [osx and x86_64]
15+
build:
16+
- {{ compiler("rust") }}
17+
- {{ stdlib("c") }}
1718
```
1819

19-
The latter is also set automatically via a `run_exports` of
20-
the `compiler('rust')` package, but we add this line if you would increase
21-
the deployment target later in the feedstock for unrelated reasons.
20+
Note: This entry was update in April 2024 to reflect the new infrastructure for
21+
setting `MACOSX_DEPLOYMENT_TARGET`, see
22+
[here](https://conda-forge.org/news/2024/03/24/stdlib-migration/).

news/2024-04-09-clang-everywhere.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Clang now available as compiler for all platforms

0 commit comments

Comments
 (0)