Move FindLua to main cmake file
This commit is contained in:
		
							parent
							
								
									4a6efb8d98
								
							
						
					
					
						commit
						4544278ca6
					
				| @ -7,6 +7,10 @@ set(CMAKE_CXX_FLAGS_RELEASE -O2) | ||||
| option(LUA_ENABLED "Lua scripting support" ON) | ||||
| if (LUA_ENABLED) | ||||
|   add_compile_definitions(LUA_SCRIPTING) | ||||
|   ## Find Lua | ||||
|   ## Do it here because it's needed in a bunch of places and the debian cmake is a stickler | ||||
|   find_package(Lua REQUIRED) | ||||
|   include_directories(${LUA_INCLUDE_DIR}) | ||||
| endif () | ||||
| add_executable(couch core/couch.cpp) | ||||
| 
 | ||||
|  | ||||
| @ -11,12 +11,6 @@ find_package(Bullet REQUIRED) | ||||
| ## Find AssImp | ||||
| find_package(ASSIMP REQUIRED) | ||||
| 
 | ||||
| if (LUA_ENABLED) | ||||
| ## Find Lua | ||||
| find_package(Lua REQUIRED) | ||||
| include_directories(${LUA_INCLUDE_DIR}) | ||||
| endif () | ||||
| 
 | ||||
| add_library(couchlib STATIC) | ||||
| target_sources(couchlib PUBLIC | ||||
|   Camera.h | ||||
|  | ||||
| @ -5,8 +5,6 @@ set_property(SOURCE couch.i PROPERTY USE_TARGET_INCLUDE_DIRECTORIES ON) | ||||
| 
 | ||||
| if (LUA_ENABLED) | ||||
|   ## Find Lua | ||||
|   find_package(Lua REQUIRED) | ||||
| 
 | ||||
|   swig_add_library(couchlua | ||||
|     TYPE STATIC | ||||
|     LANGUAGE lua | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Dane Johnson
						Dane Johnson