Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Use the cross-compilation tool to generate arm64 litecov.#91

Open
secnotes wants to merge 1 commit intogoogleprojectzero:master from
secnotes:master
Open

Use the cross-compilation tool to generate arm64 litecov. #91
secnotes wants to merge 1 commit intogoogleprojectzero:master from
secnotes:master

Conversation

@secnotes
Copy link

@secnotes secnotes commented Oct 13, 2025
edited
Loading

This PR allows us to generate arm64 litecov in an x86 Linux environment using cross-compilation tools. The advantage of using cross-compilation is that you can generate Tinyinst binaries that can be used by Android or other arm64 systems without the need for Android NDK.

Tip: Of course, in this environment, when compiling, we often need to generate a statically linked binary. Therefore, please add the build option -DCMAKE_EXE_LINKER_FLAGS=-static

Copy link
Collaborator

@ifratric ifratric left a comment

Choose a reason for hiding this comment

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

Thanks! Some comments below.

bool operator< (LoadedModule const& lhs, LoadedModule const& rhs);

#ifdef ARM64
#include <asm/ptrace.h>
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this needed given that we already include sys/ptrace.h from debugger.h. And if it's needed for cross-compiling, will it cause issues when building for Android using the Android NDK?

cmake --build . --config Release
```

#### Cross-compiling for Linux
Copy link
Collaborator

Choose a reason for hiding this comment

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

"Cross-compiling for aarch64 Linux"?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@ifratric ifratric ifratric left review comments

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /