Skip to content
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

Added qh3 as a package #25193

Open
wants to merge 16 commits into
base: main
Choose a base branch
from
Open

Added qh3 as a package #25193

wants to merge 16 commits into from

Conversation

thewchan
Copy link
Contributor

Checklist

  • Title of this PR is meaningful: e.g. "Adding my_nifty_package", not "updated meta.yaml".
  • License file is packaged (see here for an example).
  • Source is from official source.
  • Package does not vendor other packages. (If a package uses the source of another package, they should be separate packages or the licenses of all packages need to be packaged).
  • If static libraries are linked in, the license of the static library is packaged.
  • Package does not ship static libraries. If static libraries are needed, follow CFEP-18.
  • Build number is 0.
  • A tarball (url) rather than a repo (e.g. git_url) is used in your recipe (see here for more details).
  • GitHub users listed in the maintainer section have posted a comment confirming they are willing to be listed there.
  • When in trouble, please check our knowledge base documentation before pinging a team.

@conda-forge-webservices
Copy link

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipes/qh3) and found it was in an excellent condition.

@thewchan
Copy link
Contributor Author

@conda-forge/help-c-cpp @help-python-c It seems the ls-qpack is included in vendor directory in the source but somehow it's still complaining it can't find the header file? Tried adding the conda pylsqpack to no avail...

- {{ compiler('c') }}

# Adding this here as otherwise it relies on vendor lsqpack
- pylsqpack
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be in host

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let me try that

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The compiler needs to stay in build.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

got it I'll move it back

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xhochy does this mean the C library would need to be brought onto conda first?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we will need that first.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xhochy, I've never worked on a pure C library for Conda before, is here a good example recipe you think I can reference?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Depends on what the build tool is. Is it using autotools?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I checked upstream, seems like CMake?

@thewchan
Copy link
Contributor Author

thewchan commented Feb 5, 2024

@xhochy no dice still

  src/qh3/_vendor/pylsqpack/binding.c:4:10: fatal error: lsqpack.h: No such file or directory
      4 | #include "lsqpack.h"

@thewchan thewchan closed this Feb 5, 2024
@thewchan thewchan reopened this Feb 7, 2024
@thewchan
Copy link
Contributor Author

Hi @xhochy I'm pivoting back to this now, it's asking for libclang and I've added it to the build env, but somehow it's saying it still can't find it?

@@ -0,0 +1,2 @@
c_stdlib_version: # [osx and x86]
- '10.12' # [osx and x86]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- '10.12' # [osx and x86]
- '10.13' # [osx and x86]

10.13 is now the new default/minimum

- {{ compiler('c') }}
- {{ compiler('rust') }}
- cmake
- libclang # [linux]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- libclang # [linux]

This is something on PyPI only to reduce the size of binary artifacts (mostly?). In all recipes I have seen it, I just patched it out as a requirement.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll try Clang instead then

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or maybe I need to use Clang as the C compiler and not gcc?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xhochy It seems that it's during the rust/cargo build phase it needs libclang, but not sure why it's not detecting it

@thewchan
Copy link
Contributor Author

thewchan commented May 11, 2024

@xhochy New OSX errors

/Applications/Xcode_14.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/CommonCrypto/CommonRandom.h:35:9: error: unknown type name 'CCCryptorStatus'

/Users/runner/Miniforge3/conda-bld/qh3_1715437872253/_build_env/.cargo/registry/src/index.crates.io-6f17d22bba15001f/aws-lc-sys-0.15.0/aws-lc/crypto/fipsmodule/rand/urandom.c:382:42: error: use of undeclared identifier 'kCCSuccess'

Also linux build still not working, same issue, can't find libclang. I might try switching from gcc to clang

host:
- python
- maturin >=1.2,<2.0
- pip
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- pip
- pip
- clangdev

This is probably what you need

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

got it, let me try

@xhochy
Copy link
Member

xhochy commented May 11, 2024

@xhochy New OSX errors


/Applications/Xcode_14.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/CommonCrypto/CommonRandom.h:35:9: error: unknown type name 'CCCryptorStatus'



/Users/runner/Miniforge3/conda-bld/qh3_1715437872253/_build_env/.cargo/registry/src/index.crates.io-6f17d22bba15001f/aws-lc-sys-0.15.0/aws-lc/crypto/fipsmodule/rand/urandom.c:382:42: error: use of undeclared identifier 'kCCSuccess'

Also linux build still not working, same issue, can't find libclang. I might try switching from gcc to clang

I think you need openssl in host and set OPENSSL_DIR=$PREFIX

@thewchan
Copy link
Contributor Author

@xhochy maybe it's confused now because there is both gcc and clang? Or is it asking for a c++ compiler

warning: aws-lc-sys@0.15.0: Compiler version doesn't include clang or GCC: "/home/conda/staged-recipes/build_artifacts/qh3_1715440102416/_build_env/bin/x86_64-conda-linux-gnu-cc" "--version"
  warning: aws-lc-sys@0.15.0: Failed to run: "c++" "--version"

@xhochy
Copy link
Member

xhochy commented May 11, 2024

Yes, it needs a C++ compiler

@thewchan
Copy link
Contributor Author

@xhochy it still has trouble finding a compiler, I wonder if I need to specify or change some env variables for Clang?

 warning: aws-lc-sys@0.15.0: Compiler version doesn't include clang or GCC: "/home/conda/staged-recipes/build_artifacts/qh3_1715440942569/_build_env/bin/x86_64-conda-linux-gnu-cc" "--version"
  warning: aws-lc-sys@0.15.0: Compiler version doesn't include clang or GCC: "/home/conda/staged-recipes/build_artifacts/qh3_1715440942569/_build_env/bin/x86_64-conda-linux-gnu-c++" "--version"

  error: failed to run custom build command for `aws-lc-sys v0.15.0`


@xhochy
Copy link
Member

xhochy commented May 11, 2024

No. This should be buildable with gcc. Switching to clang might even bring more hassle in this case.

@thewchan
Copy link
Contributor Author

It really is this aws-lc-sys-0.15.0 rust package causing all the problems in both linux and osx, but seems to be for different reasons

@xhochy
Copy link
Member

xhochy commented May 11, 2024

I read a bit through its code. It seems like adding cmake to build and setting AWS_LC_SYS_CMAKE_BUILDER=1 may lead to better errors.

@thewchan
Copy link
Contributor Author

@xhochy I already have cmake in build but let me try that env var

@xhochy
Copy link
Member

xhochy commented May 11, 2024

You need make in build

- {{ compiler('c') }}
- {{ compiler('cxx') }}
- {{ compiler('rust') }}\
- clangdev
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should only be in host

- {{ stdlib('c') }}
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- {{ compiler('rust') }}\
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- {{ compiler('rust') }}\
- {{ compiler('rust') }}

@thewchan
Copy link
Contributor Author

@xhochy Thanks so much! Linux build is fixed. Now trying to figure out the OSX build, I found this possible related situation but not sure if it is addressable here: openssl/openssl#16458

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

None yet

3 participants