Skip to content

Commit

Permalink
Second attempt at adding lutefisk3d as a submodule (Segs#672)
Browse files Browse the repository at this point in the history
  • Loading branch information
nemerle authored Oct 31, 2018
1 parent ca8523a commit a0285a3
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "3rd_party/Lutefisk3D"]
path = 3rd_party/Lutefisk3D
url = https://github.com/Lutefisk3D/lutefisk3d
13 changes: 6 additions & 7 deletions 3rd_party/ExternalProject_Lutefisk3D.cmake
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
if(NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/Lutefisk3D/CMake/LutefiskOptions.cmake")
message(FATAL_ERROR "Lutefisk3D git submodule has not been checked out.")
endif()
if(FALSE)
set(LUTEFISK3D_NETWORK OFF) # don't need it, and it doesn't compile anyway :)
add_subdirectory(Lute)
add_subdirectory(Lutefisk3D)
else()
#NOTE: by default lutefisk builds in RelWithDebInfo
# for our use case this seems the most optimal build type.
libname(lutefisk3d Lutefisk3D)
# add the main options for lutefisk,
# NOTE: this only works when Lutefisk is aleady checked-out submodule
# this will likely happen, but not just yet.
#include(${CMAKE_CURRENT_SOURCE_DIR}/Lute/CMake/LutefiskOptions.cmake)
include(${CMAKE_CURRENT_SOURCE_DIR}/Lutefisk3D/CMake/LutefiskOptions.cmake)
set(LUTEFISK3D_NETWORK OFF) # don't need it, and it doesn't compile anyway :)

set(lutefisk_cmake_options
Expand All @@ -30,9 +31,7 @@ else()

ExternalProject_Add(
l3d_BUILD
# SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/Lute
GIT_REPOSITORY https://github.com/Lutefisk3D/lutefisk3d
GIT_SHALLOW 1
SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/Lutefisk3D
UPDATE_COMMAND ""
INSTALL_DIR ${ThirdParty_Install_Dir}
CMAKE_ARGS ${lutefisk_cmake_options}
Expand Down
1 change: 1 addition & 0 deletions 3rd_party/Lutefisk3D
Submodule Lutefisk3D added at 75576e

0 comments on commit a0285a3

Please sign in to comment.