Don't define sentry_add_version_resource() command when building the static version#1084
Don't define sentry_add_version_resource() command when building the static version#1084dacap wants to merge 1 commit intogetsentry:masterfrom
Conversation
… static version As crashpad now checks the existence of sentry_add_version_resource() command in: getsentry/crashpad@8961424 We cannot define the command if the sentry.rc file is not going to be created, i.e. only the static version of Sentry is going to be built. Without this fix we'll get the following error: CMake Error: File .../sentry.rc.in does not exist. CMake Error at sentry-native/cmake/utils.cmake:14 (configure_file): configure_file Problem configuring file Call Stack (most recent call first): sentry-native/external/crashpad/handler/CMakeLists.txt:118 (sentry_add_version_resource)
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1084 +/- ##
==========================================
+ Coverage 82.41% 82.42% +0.01%
==========================================
Files 53 53
Lines 7752 7751 -1
Branches 1216 1216
==========================================
Hits 6389 6389
+ Misses 1252 1251 -1
Partials 111 111
|
|
Thanks for the report, @dacap. As you can see by the failing tests, this won't work because the The placement of the Even if we build shared, there is never a
As you can see in your error message, the problem seems to be that We do test our builds in the static configuration: https://github.com/getsentry/sentry-native/actions/runs/11930882865/job/33252573289#step:13:180 And with the given configuration the build seems to work. |
Do you add sentry as a subdirectory to your project? |
If yes, can you please try #1086? |
That's right, I'm using Sentry as a "subdirectory" (actually importing it from outside with I'll give a try to your PR and answer there. Thanks! |
|
closing in favor of #1086 |
As crashpad now checks the existence of sentry_add_version_resource() command in:
getsentry/crashpad@8961424
We cannot define the command if the sentry.rc file is not going to be created, i.e. only the static version of Sentry is going to be built.
Without this fix we'll get the following error:
This regression was introduced in #1076