add LJ_ENDIAN and LJ_NO_UNWIND checks
@@ -152,6 +152,12 @@ SET(DASM_ARCH ${TARGET_LJARCH})
SET(DASM_FLAGS)
SET(TARGET_ARCH)
LIST(APPEND TARGET_ARCH "LUAJIT_TARGET=LUAJIT_ARCH_${TARGET_LJARCH}")
+LJ_TEST_ARCH_VALUE(LJ_LE 1)
+IF(LJ_LE_1)
+ SET(DASM_FLAGS ${DASM_FLAGS} -D ENDIAN_LE)
+ELSE()
+ SET(DASM_FLAGS ${DASM_FLAGS} -D ENDIAN_BE)
+ENDIF()
LJ_TEST_ARCH_VALUE(LJ_ARCH_BITS 64)
IF(LJ_ARCH_BITS_64)
SET(DASM_FLAGS ${DASM_FLAGS} -D P64)
@@ -182,6 +188,11 @@ IF(NOT LJ_ABI_SOFTFP_1)
ELSE()
LIST(APPEND TARGET_ARCH "LJ_ABI_SOFTFP=1")
ENDIF()
+LJ_TEST_ARCH_VALUE(LJ_NO_UNWIND 1)
+IF(LJ_NO_UNWIND_1)
+ SET(DASM_FLAGS ${DASM_FLAGS} -D NO_UNWIND)
+ LIST(APPEND TARGET_ARCH "LUAJIT_NO_UNWIND=1")
+ENDIF()
IF(WIN32)
SET(DASM_FLAGS ${DASM_FLAGS} -LN -D WIN)
ENDIF()
