--- safetyhook/meson.build +++ safetyhook/meson.build @@ -0,0 +1,15 @@ +project('safetyhook', 'c', 'cpp', version: '0.1.3') + +safetyhook_inc = include_directories('.') +safetyhook_lib = static_library( + 'safetyhook', + include_directories: safetyhook_inc, + sources: [ + 'safetyhook.cpp', + 'Zydis.c' + ] +) +safetyhook_dep = declare_dependency( + link_with: safetyhook_lib, + include_directories: safetyhook_inc, +) --- safetyhook/safetyhook.cpp +++ safetyhook/safetyhook.cpp @@ -14,7 +14,7 @@ #include #define NOMINMAX -#include +#include namespace safetyhook { @@ -324,7 +324,7 @@ VmtHook create_vmt(void* object) { #include -#include +#include #if __has_include() #include @@ -858,7 +858,7 @@ std::expected MidHook::setup( // Source file: thread_freezer.cpp // -#include +#include #include @@ -992,7 +992,7 @@ void fix_ip(CONTEXT& ctx, uint8_t* old_ip, uint8_t* new_ip) { // Source file: utility.cpp // -#include +#include namespace safetyhook { @@ -1046,7 +1046,7 @@ bool is_executable(uint8_t* address) { // Source file: vmt_hook.cpp // -#include +#include --- safetyhook/safetyhook.hpp +++ safetyhook/safetyhook.hpp @@ -898,7 +898,7 @@ namespace safetyhook { #include #include -#include +#include namespace safetyhook { /// @brief Executes a function while all other threads are frozen. Also allows for visiting each frozen thread and