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

using cross affects ci workflow #614

Closed
uncomfyhalomacro opened this issue Apr 10, 2023 · 4 comments
Closed

using cross affects ci workflow #614

uncomfyhalomacro opened this issue Apr 10, 2023 · 4 comments

Comments

@uncomfyhalomacro
Copy link
Contributor

I just found out that juliaup uses action-rs/cargo with cross set to true which limits installing additional dependencies. These dependencies might be needed for some crates e.g. reqwest with native-tls enabled looks for openssl-dev. The cross tool can actually allow us to make a pre-build hook e.g. install libssl-dev or pkg-config inside the container before running cargo. See cross-rs/cross#678. However action-rs/cargo seems to not have updated to include the pre-build hook. This makes sense since the functionality was added since 2022 while action-rs/cargo has not been updated since 2021

Assuming we have the prebuild hook option, we can do the following to install openssl devel inside the cross container:

    - name: Test
      uses: actions-rs/cargo@v1
      with:
        use-cross: true
        pre-build: 'apt-get install -y libssl-dev pkg-config'
        command: check
        args: --target ${{matrix.target}} --features ${{matrix.features}}

There is an open issue at actions-rs/cargo#115 but it's been two years since action-rs/cargo was updated.

This issue affects my PR #613 where I cannot test if my changes build correctly

@uncomfyhalomacro
Copy link
Contributor Author

Solution:

We can just use vanilla cross without using the github action (or fork it) to add the prebuild hook functionality as described in their README but I haven't tested it.

@uncomfyhalomacro
Copy link
Contributor Author

Just to add. This also means that apt-get install musl-tools didn't do anything because of cross

@uncomfyhalomacro
Copy link
Contributor Author

Seems another project noticed - kanidm/webauthn-rs#301

I will open a pull request I guess.

@davidanthoff
Copy link
Collaborator

I think this is not really a problem right now? For the certificate situation things work on the PR now. I'm closing for now.

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

No branches or pull requests

2 participants