function (generate_constant PREFIX)
  set (GENERATOR_PATH "${SOURCE_PATH}/processor/generator/constant")
  set (TARGET_PATH ${CMAKE_CURRENT_SOURCE_DIR})

  include (GenerateConstantProcessor)
  generate_constant_processor (${PREFIX} ${TARGET_PATH})

  if (DEFINED CMAKE_CONSTANT_SYMBOLS)
    file (RELATIVE_PATH RELATIVE_SOURCE_PATH ${TARGET_PATH} ${SOURCE_PATH})

    configure_file ("${GENERATOR_PATH}/main.h.in" "${TARGET_PATH}/main.h")
    configure_file ("${GENERATOR_PATH}/main.c.in" "${TARGET_PATH}/main.c")
  endif ()
endfunction ()
