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

Do not pass --parallel option to old cmake #146

Merged
merged 1 commit into from
May 12, 2022

Conversation

taiki-e
Copy link
Member

@taiki-e taiki-e commented Mar 1, 2022

This parses the cmake version and avoids passing --parallel option to old cmake.

Fixes #131
Fixes #143

(I confirmed this fix works in a project where I actually ran into issue 131: openrr/openrr#584)

@alexcrichton
Copy link
Member

Ok, sorry but I've decided that I will no longer maintain this crate and it needs a new maintainer.

1 similar comment
@alexcrichton
Copy link
Member

Ok, sorry but I've decided that I will no longer maintain this crate and it needs a new maintainer.

src/lib.rs Outdated Show resolved Hide resolved
@m-ou-se m-ou-se merged commit 00e6b22 into rust-lang:master May 12, 2022
@taiki-e taiki-e deleted the version branch May 12, 2022 10:54
@acshi
Copy link

acshi commented Jul 10, 2022

Could we please get a new release with this fix included? Unfortunately, I just spent several hours on a goose chase with wondering why the cmake version check wasn't working because I thought this code was present in the most recent release when it actually wasn't!

hishamhm added a commit to Kong/ngx_wasm_module that referenced this pull request Aug 10, 2022
I haven't spotted this one before, but it just failed on me
when testing the Ubuntu 18.04 build:

The latest `cargo` uses `cmake --parallel` when building
`wabt-sys` (which is required by `cwabt`, used by the V8 backend).
The `--parallel` flag is only available from CMake 3.12 onwards,
which is not included in the Ubuntu 18.04 distro.

More info on the cmake version requirement for cmake-rs:
rust-lang/cmake-rs#131
A fix was merged but a new version of the crate was not
yet released:
rust-lang/cmake-rs#146

Turns out the easiest way to get a binary for CMake >= 3.12
that's compatible with Ubuntu 18.04 is to install it via pip:

```
RUN apt-get install -y --no-install-recommends \
        python3-pip \
        python3-setuptools
RUN pip3 install --upgrade pip
RUN pip3 install scikit-build
RUN pip3 install cmake
```

...which worked, but pinning the dependency involved fewer moving
parts and felt like a more stable solution.
hishamhm added a commit to Kong/ngx_wasm_module that referenced this pull request Aug 10, 2022
The latest cargo uses cmake --parallel when building
wabt-sys (which is required by cwabt, used by the V8 backend).
The --parallel flag is only available from CMake 3.12 onwards,
which is not included in the Ubuntu 18.04 distro.

More info on the cmake version requirement for cmake-rs:
rust-lang/cmake-rs#131
A fix was merged but a new version of the crate was not
yet released:
rust-lang/cmake-rs#146

Additionally, wabt-sys actually includes code which assumes
CMake >= 3.12! See:
https://ma.ttias.be/wabt-sys-compile-error-cmake-project-version-not-declared-in-scope-ubuntu-18-04/
hishamhm added a commit to Kong/ngx_wasm_module that referenced this pull request Aug 11, 2022
The latest cargo uses cmake --parallel when building
wabt-sys (which is required by cwabt, used by the V8 backend).
The --parallel flag is only available from CMake 3.12 onwards,
which is not included in the Ubuntu 18.04 distro.

More info on the cmake version requirement for cmake-rs:
rust-lang/cmake-rs#131
A fix was merged but a new version of the crate was not
yet released:
rust-lang/cmake-rs#146

Additionally, wabt-sys actually includes code which assumes
CMake >= 3.12! See:
https://ma.ttias.be/wabt-sys-compile-error-cmake-project-version-not-declared-in-scope-ubuntu-18-04/
hishamhm added a commit to Kong/ngx_wasm_module that referenced this pull request Aug 12, 2022
The latest cargo uses cmake --parallel when building
wabt-sys (which is required by cwabt, used by the V8 backend).
The --parallel flag is only available from CMake 3.12 onwards,
which is not included in the Ubuntu 18.04 distro.

More info on the cmake version requirement for cmake-rs:
rust-lang/cmake-rs#131
A fix was merged but a new version of the crate was not
yet released:
rust-lang/cmake-rs#146

Additionally, wabt-sys actually includes code which assumes
CMake >= 3.12! See:
https://ma.ttias.be/wabt-sys-compile-error-cmake-project-version-not-declared-in-scope-ubuntu-18-04/
@emk emk mentioned this pull request Oct 26, 2022
emk added a commit to faradayio/geocode-csv that referenced this pull request Oct 26, 2022
We also update to the latest `bigtable-rs` to fix the build.

See also the following info on `cmake` and Ubuntu 18:

rust-lang/cmake-rs#146
rust-lang/cmake-rs#162
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

Successfully merging this pull request may close these issues.

Unsupported --parallel flag issued 0.1.46 does not work
4 participants