-
Notifications
You must be signed in to change notification settings - Fork 428
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New jinja-function for handling sysroot #4981
Comments
How about |
I'd like that! It's clearer and more understandable than |
It occurred to me today that we should be able to extend this to all platforms, and that if we go with
|
Checklist
What is the idea?
In the context of conda-forge/conda-forge.github.io#1844, we discovered that we have very few ways to encode the sysroot expectations for a given package, and that both on linux and on osx, a lot of conda-forge's infrastructure implicitly assumes cos6 and macos 10.9, because they haven't been changed for such a long time.
In the discussion of how to encode such constraints correctly (e.g. moving to >=10.13), the option of adding an osx-equivalent to https://github.com/conda-forge/linux-sysroot-feedstock came up, and that essentially, the only way to do this cleanly would be for recipes to explicitly note their dependence on the sysroot, and control the version via (the global)
conda_build_config.yaml
.This would also solve priorisation issues with the current centos 7 sysroot, that needs to be weighed down (despite the higher version), since we still want to build for centos 6 by default (for now at least; the same problem appears for introducing the 2.28 sysroot).
One idea that would work already today would be to abuse the
compiler()
jinja-function, which would already allow to populate something like:However, while
{{ compiler('sysroot') }}
might be acceptable inmeta.yaml
, this would look a bit awkward in the CBCoriginal suggestion (obsolete)
Thus the idea came up to introduce a new jinja-function
sysroot(...)
, which could work as follows:The idea to make it take
'default'
as an argument is threefold:{{ sysroot() }}
) that this is calling a function- {{ sysroot(...) }}
per platformThus the idea came up to introduce a new jinja-function
stdlibc("c")
, that works likecompiler("c")
i.e. on linux-64,
stdlibc("c")
would expand to{{ c_stdlib }}_{{ cross_target_platform }} {{ c_stdlib_version }}
This would have several advantages:
compiler()
function (matching the fact that most compiled artefacts need a runtime lib)<lang>_compiler{,_version}
cxx
c_stdlib
implementation to CBC)Why is this needed?
Solve various issues in conda-forge infrastructure, see above.
What should happen?
stdlib
function is a good ideacompiler
function; other idea?stdlib
functioncompiler(<lang>)
or diverge intentionallyAdditional Context
No response
The text was updated successfully, but these errors were encountered: