Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
iMSTK
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
37
Issues
37
List
Boards
Labels
Service Desk
Milestones
Merge Requests
12
Merge Requests
12
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
iMSTK
iMSTK
Commits
51ff4efa
Commit
51ff4efa
authored
Mar 25, 2020
by
Aaron Bray
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix bugs in imstkconfig.cmake support
- Support debug config - disable imgui search in find for config
parent
a9b46329
Pipeline
#165699
passed with stage
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
41 additions
and
33 deletions
+41
-33
CMake/FindPhysX.cmake
CMake/FindPhysX.cmake
+2
-2
CMake/Findimgui.cmake
CMake/Findimgui.cmake
+22
-20
CMake/Utilities/imstkFind.cmake
CMake/Utilities/imstkFind.cmake
+10
-9
CMake/iMSTKConfig.cmake.in
CMake/iMSTKConfig.cmake.in
+3
-2
CMakeLists.txt
CMakeLists.txt
+4
-0
No files found.
CMake/FindPhysX.cmake
View file @
51ff4efa
...
...
@@ -23,5 +23,5 @@ imstk_find_libary(PhysX PhysXPvdSDK _static${physx_release_type}_64 _staticDEBUG
imstk_find_package
(
PhysX
)
message
(
STATUS
"PhysX include :
${
PHYSX_INCLUDE_DIRS
}
"
)
message
(
STATUS
"PhysX libraries :
${
PHYSX_LIBRARIES
}
"
)
#
message(STATUS "PhysX include : ${PHYSX_INCLUDE_DIRS}")
#
message(STATUS "PhysX libraries : ${PHYSX_LIBRARIES}")
CMake/Findimgui.cmake
View file @
51ff4efa
...
...
@@ -6,24 +6,26 @@ imstk_find_header(imgui imgui.h imgui)
imstk_find_header_package
(
imgui
)
#message(STATUS "imgui includes : ${IMGUI_INCLUDE_DIRS}")
#-----------------------------------------------------------------------------
# Find Source
# Since imgui has no CMake, code is pulled into an iMSTK component directly
#-----------------------------------------------------------------------------
find_path
(
IMGUI_SOURCE_DIR
NAMES
imgui.cpp
PATHS
${
CMAKE_BINARY_DIR
}
/../External/imgui/src
NO_DEFAULT_PATH
)
mark_as_advanced
(
IMGUI_SOURCE_DIR
)
#message(STATUS "imgui source : ${IMGUI_SOURCE_DIR}")
if
(
FIND_IMGUI_SOURCE
)
#-----------------------------------------------------------------------------
# Find Source
# Since imgui has no CMake, code is pulled into an iMSTK component directly
#-----------------------------------------------------------------------------
find_path
(
IMGUI_SOURCE_DIR
NAMES
imgui.cpp
PATHS
${
CMAKE_BINARY_DIR
}
/../External/imgui/src
NO_DEFAULT_PATH
)
mark_as_advanced
(
IMGUI_SOURCE_DIR
)
#message(STATUS "imgui source : ${IMGUI_SOURCE_DIR}")
#-----------------------------------------------------------------------------
# Find package
#-----------------------------------------------------------------------------
include
(
FindPackageHandleStandardArgs
)
find_package_handle_standard_args
(
imgui
REQUIRED_VARS
IMGUI_SOURCE_DIR
)
#-----------------------------------------------------------------------------
# Find package
#-----------------------------------------------------------------------------
include
(
FindPackageHandleStandardArgs
)
find_package_handle_standard_args
(
imgui
REQUIRED_VARS
IMGUI_SOURCE_DIR
)
endif
()
CMake/Utilities/imstkFind.cmake
View file @
51ff4efa
...
...
@@ -32,7 +32,7 @@ macro(imstk_find_header package header)
else
()
set
(
_SEARCH_DIR
${
PACKAGE_PREFIX_DIR
}
/include/
${
sub_dir
}
)
endif
()
message
(
STATUS
"Searching for :
${
_SEARCH_DIR
}
/
${
header
}
"
)
#
message(STATUS "Searching for : ${_SEARCH_DIR}/${header}")
find_path
(
${
package
}
_INCLUDE_DIR
NAMES
...
...
@@ -42,13 +42,13 @@ macro(imstk_find_header package header)
NO_DEFAULT_PATH
)
else
()
message
(
STATUS
"I am looking in system for
${
package
}
"
)
#
message(STATUS "I am looking in system for ${package}")
find_path
(
${
package
}
_INCLUDE_DIR
NAMES
${
header
}
)
endif
()
message
(
STATUS
"Found it :
${${
package
}
_INCLUDE_DIR
}
/
${
header
}
"
)
#
message(STATUS "Found it : ${${package}_INCLUDE_DIR}/${header}")
if
(
EXISTS
${${
package
}
_INCLUDE_DIR
}
/
${
header
}
)
...
...
@@ -58,7 +58,7 @@ macro(imstk_find_header package header)
else
()
message
(
FATAL_ERROR
"Could not find
${${
package
}
_INCLUDE_DIR
}
/
${
header
}
"
)
endif
()
message
(
STATUS
"
${
package
}
_INCLUDE_DIRS :
${${
package
}
_INCLUDE_DIRS
}
"
)
#
message(STATUS "${package}_INCLUDE_DIRS : ${${package}_INCLUDE_DIRS}")
unset
(
${
package
}
_INCLUDE_DIR CACHE
)
endmacro
()
...
...
@@ -83,7 +83,7 @@ macro(imstk_find_libary package library)
string
(
STRIP
${
release_postfix
}
release_postfix
)
list
(
GET extra_macro_args 1 debug_postfix
)
string
(
STRIP
${
debug_postfix
}
debug_postfix
)
message
(
STATUS
"Looking for
${
package
}
libraries
${
library
}${
release_postfix
}
and
${
library
}${
debug_postfix
}
"
)
#
message(STATUS "Looking for ${package} libraries ${library}${release_postfix} and ${library}${debug_postfix}")
endif
()
# Should I look in system locations?
...
...
@@ -100,11 +100,10 @@ macro(imstk_find_libary package library)
if
(
${
package
}
_LIB_DIR
)
set
(
_SEARCH_DIR
${${
package
}
_ROOT_DIR
}
/
${${
package
}
_LIB_DIR
}
)
endif
()
#message(STATUS "Looking for ${package} libs in ${_SEARCH_DIR}")
else
()
set
(
_SEARCH_DIR
${
PACKAGE_PREFIX_DIR
}
/lib
)
endif
()
#message(STATUS "Looking for ${package} libs in ${_SEARCH_DIR}")
unset
(
${
PACKAGE
}
_LIBRARY_
${
library
}
-RELEASE CACHE
)
string
(
TOUPPER
${
package
}
PACKAGE
)
...
...
@@ -146,21 +145,23 @@ macro(imstk_find_libary package library)
endif
()
#message(STATUS "Looking for Release Library : ${library}${release_postfix} in ${_SEARCH_DIR}")
if
(
EXISTS
${${
PACKAGE
}
_LIBRARY_
${
library
}
-RELEASE
}
)
#message(STATUS "${PACKAGE}_LIBRARY_${library}-RELEASE : ${${PACKAGE}_LIBRARY_${library}-RELEASE}")
list
(
APPEND
${
PACKAGE
}
_LIBRARIES optimized
${${
PACKAGE
}
_LIBRARY_
${
library
}
-RELEASE
}
)
list
(
APPEND
${
PACKAGE
}
_RELEASE_LIBRARIES
${${
PACKAGE
}
_LIBRARY_
${
library
}
-RELEASE
}
)
endif
()
mark_as_advanced
(
${
PACKAGE
}
_LIBRARY_
${
library
}
-RELEASE
)
#message(STATUS "Libraries : ${${PACKAGE}_RELEASE_LIBRARIES}")
#message(STATUS "
Release
Libraries : ${${PACKAGE}_RELEASE_LIBRARIES}")
#message(STATUS "Looking for Debug Library : ${library}${debug_postfix} in ${_SEARCH_DIR}")
if
(
EXISTS
${${
PACKAGE
}
_LIBRARY_
${
library
}
-DEBUG
}
)
#message(STATUS "${PACKAGE}_LIBRARY_${library}-DEBUG : ${${PACKAGE}_LIBRARY_${library}-DEBUG}")
list
(
APPEND
${
PACKAGE
}
_LIBRARIES debug
${${
PACKAGE
}
_LIBRARY_
${
library
}
-DEBUG
}
)
list
(
APPEND
${
PACKAGE
}
_DEBUG_LIBRARIES
${${
PACKAGE
}
_LIBRARY_
${
library
}
-DEBUG
}
)
endif
()
mark_as_advanced
(
${
PACKAGE
}
_LIBRARY_
${
library
}
-DEBUG
)
#message(STATUS "Libraries : ${${PACKAGE}_DEBUG_LIBRARIES}")
#message(STATUS "
Debug
Libraries : ${${PACKAGE}_DEBUG_LIBRARIES}")
endmacro
()
#-----------------------------------------------------------------------------
...
...
CMake/iMSTKConfig.cmake.in
View file @
51ff4efa
...
...
@@ -17,6 +17,7 @@ set(iMSTK_BUILD_TESTING @iMSTK_BUILD_TESTING@)
set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/modules")
include(${CMAKE_CURRENT_LIST_DIR}/modules/imstkFind)
include(CMakeFindDependencyMacro)
set(CMAKE_DEBUG_POSTFIX @CMAKE_DEBUG_POSTFIX@)
# Assimp
find_package( Assimp REQUIRED )
...
...
@@ -56,7 +57,7 @@ find_package( Libusb REQUIRED)
if(iMSTK_ENABLE_VR)
add_definitions( -DiMSTK_ENABLE_VR )
find_package( openvr REQUIRED )
e
lse
()
e
ndif
()
# PhysX
find_package(PhysX REQUIRED)
...
...
@@ -114,7 +115,7 @@ else()
RenderingCore
RenderingOpenGL2
RenderingVolume
RenderingVolumeOpenGL2
RenderingVolumeOpenGL2
)
endif()
# glfw, gli
...
...
CMakeLists.txt
View file @
51ff4efa
...
...
@@ -201,6 +201,10 @@ find_package( g3log REQUIRED )
# glm
find_package
(
glm REQUIRED
)
# imgui
# iMSTK actually includes and compiles imgui code
# As imgui does not have any cmake support
# So tell our find_package to also find the imgui source directory
set
(
FIND_IMGUI_SOURCE ON
)
find_package
(
imgui REQUIRED
)
# LibNiFalcon
find_package
(
LibNiFalcon REQUIRED
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment