mie: add value type hierarchy definitions

every construct within Mie, such as constants, instructions, functions, and translation units, are sub-types of the generic mie_value struct.

mie_value will facilitate iterating through the IR, as well as converting the IR to/from different formats.
This commit is contained in:
2025-04-03 10:50:35 +01:00
parent df8d9689d1
commit e7f6d54fa2
9 changed files with 139 additions and 0 deletions

15
mie/CMakeLists.txt Normal file
View File

@@ -0,0 +1,15 @@
file(GLOB_RECURSE mie_sources *.c *.h include/mie/*.h)
if (WIN32)
set(rc_file ${CMAKE_CURRENT_SOURCE_DIR}/../res/win32/mie.rc)
endif ()
if (IVY_STATIC)
add_library(mie STATIC ${mie_sources} ${rc_file})
else ()
add_library(mie SHARED ${mie_sources} ${rc_file})
endif ()
target_include_directories(mie PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include/)
target_link_libraries(mie Bluelib::Core Bluelib::Object)
target_compile_definitions(mie PRIVATE MIE_EXPORT=1 MIE_STATIC=${IVY_STATIC})