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

Compile failure with non-cargo build systems #22

Closed
taiki-e opened this issue Aug 25, 2020 · 0 comments · Fixed by #23
Closed

Compile failure with non-cargo build systems #22

taiki-e opened this issue Aug 25, 2020 · 0 comments · Fixed by #23
Assignees
Labels
C-bug Category: related to a bug.

Comments

@taiki-e
Copy link
Owner

taiki-e commented Aug 25, 2020

The following line fails to compile with non-cargo build systems, like Bazel.

const VERSION: Version = include!(concat!(env!("OUT_DIR"), "/version.rs"));

Non-version-based code generation (const_fn(cfg), const_fn(feature)) does not actually need build-scripts, so compile should not fail even if you are using those build systems.
Version-based code generation needs build-scripts, but if used with these build-systems, we should probably always generate normal functions. (This is basically the same behavior as when outputting cfg by build-scripts.)

@taiki-e taiki-e added the C-bug Category: related to a bug. label Aug 25, 2020
@taiki-e taiki-e self-assigned this Aug 25, 2020
@bors bors bot closed this as completed in d0d679f Aug 25, 2020
@bors bors bot closed this as completed in #23 Aug 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: related to a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant