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

fix: only use CPack if this is the main project #902

Merged
merged 1 commit into from
Sep 15, 2023
Merged

Conversation

henryiii
Copy link
Collaborator

@henryiii henryiii commented Jun 29, 2023

Alternative fix to, and closes #900.

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
@codecov
Copy link

codecov bot commented Jun 29, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (985a19f) 99.46% compared to head (7b8c9c5) 99.46%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #902   +/-   ##
=======================================
  Coverage   99.46%   99.46%           
=======================================
  Files          18       18           
  Lines        4099     4099           
=======================================
  Hits         4077     4077           
  Misses         22       22           

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@Jo5ta
Copy link

Jo5ta commented Jun 30, 2023

it would also be nice to have also a option to enable this.

@henryiii
Copy link
Collaborator Author

Why? If you want to pack CLI11 into a parent project, I don't think this works, does it? I don't think CPack is aware of subprojects. Though I'm not sure about that.

@henryiii
Copy link
Collaborator Author

Most of the variables don't seem to be useful in the context of a superproject, IMO. The parent project would want to set its own name - CPACK_DEBIAN_PACKAGE_NAME isn't correct if you aren't CLI11! Etc. I don't think anything would be reusable if you aren't running CLI11 directly.

@phlptp
Copy link
Collaborator

phlptp commented Jun 30, 2023

I was thinking I might want a variable to disable this normally. Since most of the time I don't want any packaging regardless if it was the main project or not. Then if it was enabled by default if it is the main project, disabled by default if it was not, either way in the unusual use cases where you want something different, there is a variable setting that can change it.

@henryiii
Copy link
Collaborator Author

It doesn't package by default - you have to run CPack. The only thing this does is set some variables and add two targets (that you don't have to build - they are not in ALL).

@henryiii henryiii merged commit 826415f into main Sep 15, 2023
@henryiii henryiii deleted the henryiii/fix/cpack branch September 15, 2023 20:21
@github-actions github-actions bot added needs changelog Hasn't been added to the changelog yet needs README Needs to be mentioned in the README labels Sep 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs changelog Hasn't been added to the changelog yet needs README Needs to be mentioned in the README
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants