-
Notifications
You must be signed in to change notification settings - Fork 122
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
Build extra components specified in manifest metadata #114
Commits on Jul 25, 2022
-
Rewrite build driver selection
Because #[path = "..."] approach sets different file paths for the same module, this causes issues with the normal module structure.
Configuration menu - View commit details
-
Copy full SHA for cbd3ee8 - Browse repository at this point
Copy the full SHA cbd3ee8View commit details
Commits on Jul 27, 2022
-
Configuration menu - View commit details
-
Copy full SHA for 107c13c - Browse repository at this point
Copy the full SHA 107c13cView commit details -
Refactor and use serde for build configuration
Add dependency `envy` to deserialize struct from env variables. Refactor `common::InstallDir` using the strum crate. Add `build_driver::TOOLS_DIR`. Cargo fmt `build/pio.rs`. Split build configuration into separate modules and structs `BuildConfig`, `NativeConfig`.
Configuration menu - View commit details
-
Copy full SHA for 1441dc1 - Browse repository at this point
Copy the full SHA 1441dc1View commit details -
Allow build configuration to be specified in manifest metadata
This change allows the build configuration to be specified in the `package.metadata.esp-idf-sys` table of the root crate's manifest (Cargo.toml). If no root crate exists in the workspace the crate with the name equal to the `ESP_IDF_SYS_ROOT_CRATE` environment variable is used. All configuration specified via environment variables will override the corresponding options of the cargo metadata. If `cargo metadata` fails for some reason, this will only generate a warning in the build output and not cause the build to fail. Add build dependency `cargo_metadata`.
Configuration menu - View commit details
-
Copy full SHA for 4f6e9ce - Browse repository at this point
Copy the full SHA 4f6e9ceView commit details
Commits on Jul 28, 2022
-
Allow to specify extra esp-idf components in manifest metadata
Makes it possible to specify extra components in the `package.metadata.esp-idf-sys.extra_components` array in the root crate's manifest as well as all direct dependencies. This change also instructs cmake to build all extra components, but without generating any bindings.
Configuration menu - View commit details
-
Copy full SHA for f9edbe5 - Browse repository at this point
Copy the full SHA f9edbe5View commit details
Commits on Jul 29, 2022
-
Get the list of enabled components from cmake
Because cmake already knows all the compiled components, it is just a matter of forwarding that information to the build script. This removes the need to recurse into every subfolder of the esp-idf's components folder.
Configuration menu - View commit details
-
Copy full SHA for 5f73553 - Browse repository at this point
Copy the full SHA 5f73553View commit details -
Generate bindings for extra components
There are two ways the bindings are generated. The first is when `bindings_module` is not set. In that case the header of the extra component will just be added to the normal esp-idf bindings generation. All additional bindings will also be in the root of `esp-idf-sys`. The second: when `bindings_module` is set. For every unique `bindings_module` bindgen will be invoked to generate the bindings, which will then be appended as a new module to the `bindings.rs` file. Note though that since this is a new bindgen invocation duplicate symbols of the normal esp-idf bindings may be generated.
Configuration menu - View commit details
-
Copy full SHA for db3254a - Browse repository at this point
Copy the full SHA db3254aView commit details
Commits on Jul 31, 2022
-
Remove cargo metadata
--frozen
and--offline
flagscargo metadata resolves all dependencies even ones that are disabled (known as weak dependencies) which cargo build doesn't do (see issue rust-lang/cargo#10801). These unresolved dependencies require network access to load their package metadata. As the `--frozen` flag itself blocks network access (in addition to blocking changes to the Cargo.lock) too, we need to remove both the `--frozen` and `--offline` flags. Doing this allows cargo the change the `Cargo.lock` though, which is undesirable (as we're in the process of building the same dependencies that rely on the `Cargo.lock` in the first place).
Configuration menu - View commit details
-
Copy full SHA for fc81349 - Browse repository at this point
Copy the full SHA fc81349View commit details -
Configuration menu - View commit details
-
Copy full SHA for 351beb6 - Browse repository at this point
Copy the full SHA 351beb6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 62c0f1b - Browse repository at this point
Copy the full SHA 62c0f1bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 3a13722 - Browse repository at this point
Copy the full SHA 3a13722View commit details
Commits on Aug 1, 2022
-
Configuration menu - View commit details
-
Copy full SHA for 8336bcd - Browse repository at this point
Copy the full SHA 8336bcdView commit details -
Configuration menu - View commit details
-
Copy full SHA for 27eb477 - Browse repository at this point
Copy the full SHA 27eb477View commit details