Custom commands#198
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 79361129f1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
5c81015 to
570ec4c
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 570ec4c93f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9feac49f95
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
9feac49 to
31f77ab
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 31f77ab328
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: da4ec26df0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
91463f5 to
39b4522
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a59bf9ace9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (resolved_target_type == target_interface) { | ||
| throw_key_error("build-event cannot be used with type = \"interface\"", "build-event", custom.find("build-event")); | ||
| } |
There was a problem hiding this comment.
Reject TARGET-form custom commands on object libraries
Checked cmake --help-command add_custom_command: the TARGET form is for a library or executable, and CMake rejects object libraries with may not have PRE_BUILD, PRE_LINK, or POST_BUILD commands. This validation only excludes interface targets here, so type = "object" with any build-event is accepted and cmkr emits add_custom_command(TARGET obj ...), causing a configure-time failure. Add a target_object guard in this branch.
Useful? React with 👍 / 👎.
| } | ||
| auto &condition_sources = msources[custom_command.condition]; | ||
| for (const auto &output : custom_command.outputs) { | ||
| condition_sources.insert(normalize_generated_output_source(output)); |
There was a problem hiding this comment.
Avoid grouping binary-dir generated outputs under source tree
When a custom-command output is normalized to ${CMAKE_CURRENT_BINARY_DIR}/..., it is later included in the target source list and passed to source_group(TREE ${CMAKE_CURRENT_SOURCE_DIR} FILES ...) below. cmake --help-command source_group says the TREE form fails unless every FILES path starts with the root; with [cmake].build-dir outside the source tree, these valid generated sources make configure fail before building. Keep binary-dir generated outputs out of that source_group or group them under the binary root separately.
Useful? React with 👍 / 👎.
No description provided.