Skip to content

Commit

Permalink
Feature/support for cython blis compilers (#492)
Browse files Browse the repository at this point in the history
* Support for cython-blis

* Add compiler in case that is a cython tool
  • Loading branch information
marcelotrevisani authored Sep 20, 2023
1 parent fdb4340 commit fce7663
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
4 changes: 3 additions & 1 deletion grayskull/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ class Configuration:
]
)
is_strict_cf: bool = False
pkg_need_c_compiler: Tuple = field(default_factory=lambda: ("cython",))
pkg_need_c_compiler: Tuple = field(
default_factory=lambda: ("cython", "cython-blis", "blis")
)
pkg_need_cxx_compiler: Tuple = field(default_factory=lambda: ("pybind11",))
url_pypi_metadata: str = "https://pypi.org/pypi/{pkg_name}/json"
download: bool = False
Expand Down
4 changes: 2 additions & 2 deletions grayskull/strategy/py_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -473,9 +473,9 @@ def get_compilers(
for pkg in requires_dist:
pkg = RE_DEPS_NAME.match(pkg).group(0)
pkg = pkg.lower().strip()
if pkg.strip() in config.pkg_need_c_compiler:
if pkg.startswith("cython-") or pkg in config.pkg_need_c_compiler:
compilers.add("c")
if pkg.strip() in config.pkg_need_cxx_compiler:
if pkg in config.pkg_need_cxx_compiler:
compilers.add("cxx")
return list(compilers)

Expand Down
1 change: 0 additions & 1 deletion grayskull/strategy/pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ def get_val(key):
source_section["url"] = adjust_source_url_to_include_placeholders(
source_section["url"], get_val("version")
)

return {
"author": get_val("author"),
"name": get_val("name"),
Expand Down

0 comments on commit fce7663

Please sign in to comment.