1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-25 17:25:13 +03:00

Fixes for lua_exports generation

This commit is contained in:
Damjan Adamic 2016-10-12 21:20:24 +02:00
parent 85273d07c1
commit e5a5a6319f
2 changed files with 6 additions and 6 deletions

View file

@ -21,8 +21,6 @@
#ifndef _DATACONSTANTS_H_
#define _DATACONSTANTS_H_
#include "board.h"
#define NUM_STICKS 4
#if defined(EXPORT)

View file

@ -5,7 +5,9 @@ endif()
macro(add_lua_export_target target)
add_custom_command(
OUTPUT lua_exports_${target}.inc
COMMAND ${CMAKE_C_COMPILER} -E ${ARGN} -DEXPORT ${INTTYPES_INCLUDE_OPTION} ${RADIO_SRC_DIRECTORY}/myeeprom.h | grep LEXP > lua_exports_${target}.txt
COMMAND ${CMAKE_C_COMPILER} -E ${ARGN} -DEXPORT ${INTTYPES_INCLUDE_OPTION} ${RADIO_SRC_DIRECTORY}/dataconstants.h > lua_exports_${target}.tmp
COMMAND grep LEXP lua_exports_${target}.tmp > lua_exports_${target}.txt
COMMAND rm lua_exports_${target}.tmp
COMMAND python ${RADIO_DIRECTORY}/util/luaexport.py ${VERSION} lua_exports_${target}.txt lua_exports_${target}.inc lua_fields_${target}.txt
)
add_custom_target(lua_export_${target} DEPENDS lua_exports_${target}.inc)
@ -38,4 +40,4 @@ set(LUA_INCLUDES_STM32F4
add_lua_export_target(taranis ${LUA_INCLUDES_STM32F2} -DPCBTARANIS)
add_lua_export_target(taranis_x9e ${LUA_INCLUDES_STM32F4} -DPCBTARANIS -DPCBX9E -DSTM32F40_41xxx)
add_lua_export_target(horus ${LUA_INCLUDES_STM32F4} -DPCBHORUS -DSTM32F40_41xxx -I${RADIO_SRC_DIRECTORY}/gui/480x272)
add_lua_export_target(horus ${LUA_INCLUDES_STM32F4} -DPCBHORUS -DSTM32F40_41xxx)