Hermes/Dyforge is a program written in c++ allows you to inject a dll that can analyze all processes in a program, can be used for mod and reverse engeneering
| 1 | cmake_minimum_required(VERSION 3.10) |
| 2 | project(DyHexInject VERSION 1.0.0 LANGUAGES C) |
| 3 | |
| 4 | # Imposta C11 |
| 5 | set(CMAKE_C_STANDARD 11) |
| 6 | set(CMAKE_C_STANDARD_REQUIRED ON) |
| 7 | |
| 8 | # Evita conflitti tra winsock.h e winsock2.h |
| 9 | if(WIN32) |
| 10 | add_definitions(-DWIN32_LEAN_AND_MEAN) |
| 11 | add_definitions(-DDYHEXINJECT_EXPORTS) |
| 12 | endif() |
| 13 | |
| 14 | # File sorgenti |
| 15 | set(SOURCES |
| 16 | DyHexInject.c |
| 17 | ) |
| 18 | |
| 19 | # File header |
| 20 | set(HEADERS |
| 21 | include/DyHexInject.h |
| 22 | include/DyHexInjectTypes.h |
| 23 | ) |
| 24 | |
| 25 | # Crea la libreria dinamica (DLL) |
| 26 | add_library(DyHexInject SHARED ${SOURCES} ${HEADERS}) |
| 27 | |
| 28 | # Directory degli include |
| 29 | target_include_directories(DyHexInject |
| 30 | PUBLIC |
| 31 | ${CMAKE_CURRENT_SOURCE_DIR}/include |
| 32 | PRIVATE |
| 33 | ${CMAKE_CURRENT_SOURCE_DIR}/src |
| 34 | ) |
| 35 | |
| 36 | # Collega le librerie |
| 37 | target_link_libraries(DyHexInject |
| 38 | PRIVATE |
| 39 | psapi |
| 40 | ) |
| 41 | |
| 42 | # Imposta directory di output e suffisso per debug |
| 43 | set_target_properties(DyHexInject PROPERTIES |
| 44 | RUNTIME_OUTPUT_DIRECTORY "${CMAKE_SOURCE_DIR}/bin" |
| 45 | LIBRARY_OUTPUT_DIRECTORY "${CMAKE_SOURCE_DIR}/lib" |
| 46 | DEBUG_POSTFIX "d" |
| 47 | ) |
| 48 | |
| 49 | # Installa la libreria |
| 50 | install(TARGETS DyHexInject |
| 51 | RUNTIME DESTINATION bin |
| 52 | LIBRARY DESTINATION lib |
| 53 | ) |
| 54 | |
| 55 | # Installa gli header |
| 56 | install(DIRECTORY include/ |
| 57 | DESTINATION include |
| 58 | FILES_MATCHING PATTERN "*.h" |
| 59 | ) |