Skip to content

Fix cmake error when build with capstone as submodule#2619

Merged
kabeor merged 1 commit intocapstone-engine:v5from
WerWolv:v5
Mar 3, 2025
Merged

Fix cmake error when build with capstone as submodule#2619
kabeor merged 1 commit intocapstone-engine:v5from
WerWolv:v5

Conversation

@WerWolv
Copy link
Copy Markdown

@WerWolv WerWolv commented Feb 2, 2025

Your checklist for this pull request

  • I've documented or updated the documentation of every API function and struct this PR changes.
  • I've added tests that prove my fix is effective or that my feature works (if possible)

Detailed description

Hey, really simple change making sure that cpack doesn't try to look for a LICENSE.TXT file in the main project root but in the current project root. This fixes the usecase where capstone is being included as a submodule and loaded using add_subdirectory in a cmake project. Previously it would look for LICENSE.TXT in the main project root directory, now it's looking for it in the capstone subdirectory.

Test plan

  • Create a sample cmake project, put capstone into a subfolder and include it in the main cmake script using add_subdirectory. Previously this would fail with a cpack error. Now it doesn't anymore.

Closing issues

  • None

@imphil
Copy link
Copy Markdown
Contributor

imphil commented Feb 19, 2025

I just saw this PR, it's fixing the same problem as #2629.

@Rot127
Copy link
Copy Markdown
Collaborator

Rot127 commented Feb 20, 2025

Yes, but this is for the v5 branch.
Feel free to duplicate your PR for the v5 branch as well.

@WerWolv didn't seem to have time to fix the CI.

@imphil
Copy link
Copy Markdown
Contributor

imphil commented Feb 20, 2025

Ah, I did overlook that this PR is targeting v5.

Feel free to duplicate your PR for the v5 branch as well.

I personally don't use v5, but I'm happy happy to backport the fix (if needed there) as soon as it is merged in to the next branch.

@Rot127
Copy link
Copy Markdown
Collaborator

Rot127 commented Feb 20, 2025

It would be pretty helpful. A lot of people use v5 still. Because they can't put the effort into changing to v6 currently (or don't get enough out of it).
So we would really appreciate it!

Copy link
Copy Markdown
Member

@kabeor kabeor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, merged.

@kabeor kabeor merged commit cc49ae6 into capstone-engine:v5 Mar 3, 2025
netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this pull request Apr 12, 2025
Version 5.0.6: March 23th, 2025

What's Changed
* V5 - Fix sdist build and add CI job for testing it.
* Build Tarball before DEB/RPM package.
* Fix cmake error when build with capstone as submodule
* [v5] Tms32c64x little endian

New Contributors
* @WerWolv made their first contribution in capstone-engine/capstone#2619

Version 5.0.5: January 16th, 2025

What's Changed
* Fix code missing in v5.0.4

Version 5.0.4: January 16th, 2025

What's Changed
* [v5][SuperH] Fix missing setting detail->sh
* tricore: fixes 2386 in v5
* Creating a functional Debian Package for Capstone v5
* Duplicate of 2590 for v5 Branch
* Update version to v5.0.4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants