mirror of
https://github.com/bitdefender/bddisasm.git
synced 2025-01-03 11:50:55 +00:00
cmake: Add isagenerator target
This commit is contained in:
parent
283c00b4c7
commit
9ee41d6dd1
@ -167,6 +167,11 @@ if((${CMAKE_PROJECT_NAME} STREQUAL ${PROJECT_NAME}) OR BDD_INCLUDE_TOOL)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# If this is the master project (or if the user requested it) add isagenerator.
|
||||
if((${CMAKE_PROJECT_NAME} STREQUAL ${PROJECT_NAME}) OR BDD_INCLUDE_ISAGENERATOR)
|
||||
add_subdirectory(isagenerator)
|
||||
endif()
|
||||
|
||||
# If this is the master project add install and package targets.
|
||||
if(${CMAKE_PROJECT_NAME} STREQUAL ${PROJECT_NAME})
|
||||
set(BDDISASM_INSTALL_CMAKEDIR
|
||||
|
14
isagenerator/CMakeLists.txt
Normal file
14
isagenerator/CMakeLists.txt
Normal file
@ -0,0 +1,14 @@
|
||||
cmake_minimum_required(VERSION 3.12)
|
||||
|
||||
project(isagenerator)
|
||||
|
||||
include(FindPython3)
|
||||
|
||||
find_package(Python3 COMPONENTS Interpreter)
|
||||
if(Python3_FOUND)
|
||||
add_custom_target(
|
||||
isagenerator
|
||||
COMMAND Python3::Interpreter generate_tables.py instructions
|
||||
WORKING_DIRECTORY "${CMAKE_CURRENT_LIST_DIR}"
|
||||
COMMENT "Generating instruction tables")
|
||||
endif(Python3_FOUND)
|
Loading…
Reference in New Issue
Block a user