Skip to content

Commit

Permalink
custom-build: added build-specific options to compile LuaJIT
Browse files Browse the repository at this point in the history
  • Loading branch information
pcherenkov committed May 18, 2012
1 parent eb22947 commit 0ccf65f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion third_party/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,16 @@ add_subdirectory(gopt)

macro (luajit_build)
set (luajit_buildoptions BUILDMODE=static)
set (luajit_buildoptions ${luajit_buildoptions} CCOPT='-I.. -O1')
set (luajit_copt ${CCOPT})
if (${CMAKE_BUILD_TYPE} STREQUAL "Debug")
set (luajit_buildoptions ${luajit_buildoptions} CCDEBUG=-ggdb)
set (luajit_copt ${luajit_copt} -O1)
set (luajit_buildoptions ${luajit_buildoptions} XCFLAGS='-DLUA_USE_APICHECK -DLUA_USE_ASSERT')
else ()
set (luajit_copt ${luajit_copt} -O2)
endif()
set (luajit_copt ${luajit_copt} -I.. )
set (luajit_buildoptions ${luajit_buildoptions} CCOPT="${luajit_copt}")
set (luajit_buildoptions ${luajit_buildoptions} Q='')
if (${PROJECT_BINARY_DIR} STREQUAL ${PROJECT_SOURCE_DIR})
add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/third_party/luajit/src/libluajit.a
Expand Down
File renamed without changes.

0 comments on commit 0ccf65f

Please sign in to comment.