diff --git a/CMakeLists.txt b/CMakeLists.txt index 8a559b85c158..71662bd37279 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -209,13 +209,6 @@ if(USE_VM_PROFILER) list(APPEND COMPILER_SRCS ${BACKEND_VM_PROFILER_SRCS}) endif(USE_VM_PROFILER) -if(BUILD_FOR_HEXAGON) - # Add file implementing posix_memalign. - list(APPEND RUNTIME_SRCS src/runtime/hexagon/hexagon_posix.cc) - - add_definitions(-D_MACH_I32=int) -endif() - file(GLOB DATATYPE_SRCS src/target/datatype/*.cc) list(APPEND COMPILER_SRCS ${DATATYPE_SRCS}) @@ -229,6 +222,13 @@ file(GLOB RUNTIME_SRCS src/runtime/vm/*.cc ) +if(BUILD_FOR_HEXAGON) + # Add file implementing posix_memalign. + list(APPEND RUNTIME_SRCS src/runtime/hexagon/hexagon_posix.cc) + + add_definitions(-D_MACH_I32=int) +endif() + # Package runtime rules if(NOT USE_RTTI) add_definitions(-DDMLC_ENABLE_RTTI=0)