more module fixes and sixense readme change for OS X dylib

This commit is contained in:
Stephen Birarda 2014-03-07 13:59:50 -08:00
parent 569dd694fe
commit 1bd3529395
5 changed files with 16 additions and 8 deletions

View file

@ -13,7 +13,7 @@
# Adapted from FindGLEW.cmake available in the nvidia-texture-tools repository # Adapted from FindGLEW.cmake available in the nvidia-texture-tools repository
# (https://code.google.com/p/nvidia-texture-tools/source/browse/trunk/cmake/FindGLEW.cmake?r=96) # (https://code.google.com/p/nvidia-texture-tools/source/browse/trunk/cmake/FindGLEW.cmake?r=96)
if (GLEW_INCLUDE_DIRS AND GLEW_LIBRARY) if (GLEW_INCLUDE_DIRS AND GLEW_LIBRARY AND (NOT WIN32 OR GLEW_WIN_DLL))
set(GLEW_FOUND TRUE) set(GLEW_FOUND TRUE)
else () else ()
if (WIN32) if (WIN32)
@ -32,7 +32,12 @@ else ()
endif () endif ()
include(FindPackageHandleStandardArgs) include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(GLEW DEFAULT_MSG GLEW_INCLUDE_DIRS GLEW_LIBRARY)
if (WIN32)
find_package_handle_standard_args(GLEW DEFAULT_MSG GLEW_INCLUDE_DIRS GLEW_LIBRARY GLEW_WIN_DLL)
else ()
find_package_handle_standard_args(GLEW DEFAULT_MSG GLEW_INCLUDE_DIRS GLEW_LIBRARY)
endif()
if (GLEW_FOUND) if (GLEW_FOUND)
if (NOT GLEW_FIND_QUIETLY) if (NOT GLEW_FIND_QUIETLY)

View file

@ -11,7 +11,7 @@
# Adapted from FindGLUT.cmake available in tlorach's OpenGLText Repository # Adapted from FindGLUT.cmake available in tlorach's OpenGLText Repository
# https://raw.github.com/tlorach/OpenGLText/master/cmake/FindGLUT.cmake # https://raw.github.com/tlorach/OpenGLText/master/cmake/FindGLUT.cmake
if (GLUT_INCLUDE_DIR AND GLUT_LIBRARIES) if (GLUT_INCLUDE_DIR AND GLUT_LIBRARIES AND (NOT WIN32 OR GLUT_WIN_DLL))
set(GLUT_FOUND TRUE) set(GLUT_FOUND TRUE)
else () else ()
if (WIN32) if (WIN32)
@ -71,7 +71,12 @@ else ()
endif () endif ()
include(FindPackageHandleStandardArgs) include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(GLUT DEFAULT_MSG GLUT_INCLUDE_DIR GLUT_LIBRARIES)
if (WIN32)
find_package_handle_standard_args(GLUT DEFAULT_MSG GLUT_INCLUDE_DIR GLUT_LIBRARIES GLUT_WIN_DLL)
else ()
find_package_handle_standard_args(GLUT DEFAULT_MSG GLUT_INCLUDE_DIR GLUT_LIBRARIES)
endif()
if (GLUT_FOUND) if (GLUT_FOUND)
if (NOT GLUT_FIND_QUIETLY) if (NOT GLUT_FIND_QUIETLY)

View file

@ -18,7 +18,7 @@ if (LIBOVR_LIBRARIES AND LIBOVR_INCLUDE_DIRS)
else (LIBOVR_LIBRARIES AND LIBOVR_INCLUDE_DIRS) else (LIBOVR_LIBRARIES AND LIBOVR_INCLUDE_DIRS)
set(LIBOVR_SEARCH_DIRS "${LIBOVR_ROOT_DIR}" "$ENV{HIFI_LIB_DIR}/oculus") set(LIBOVR_SEARCH_DIRS "${LIBOVR_ROOT_DIR}" "$ENV{HIFI_LIB_DIR}/oculus")
find_path(LIBOVR_INCLUDE_DIRS Include/OVR.h HINTS ${LIBOVR_SEARCH_DIRS}) find_path(LIBOVR_INCLUDE_DIRS OVR.h PATH_SUFFIXES Include HINTS ${LIBOVR_SEARCH_DIRS})
if (APPLE) if (APPLE)

View file

@ -19,7 +19,7 @@ else ()
set(SIXENSE_SEARCH_DIRS "${SIXENSE_ROOT_DIR}" "$ENV{HIFI_LIB_DIR}/sixense") set(SIXENSE_SEARCH_DIRS "${SIXENSE_ROOT_DIR}" "$ENV{HIFI_LIB_DIR}/sixense")
find_path(SIXENSE_INCLUDE_DIRS include/sixense.h HINTS ${SIXENSE_SEARCH_DIRS}) find_path(SIXENSE_INCLUDE_DIRS sixense.h PATH_SUFFIXES include HINTS ${SIXENSE_SEARCH_DIRS})
if (APPLE) if (APPLE)
find_library(SIXENSE_LIBRARIES lib/osx_x64/release_dll/libsixense_x64.dylib HINTS ${SIXENSE_SEARCH_DIRS}) find_library(SIXENSE_LIBRARIES lib/osx_x64/release_dll/libsixense_x64.dylib HINTS ${SIXENSE_SEARCH_DIRS})

View file

@ -9,6 +9,4 @@ NOTE: Without doing step 2, you will crash at program start time.
You may optionally choose to copy the SDK folders to a location outside the repository (so you can re-use with different checkouts and different projects). You may optionally choose to copy the SDK folders to a location outside the repository (so you can re-use with different checkouts and different projects).
If so our CMake find module expects you to set the ENV variable 'HIFI_LIB_DIR' to a directory containing a subfolder 'sixense' that contains the folders mentioned above. If so our CMake find module expects you to set the ENV variable 'HIFI_LIB_DIR' to a directory containing a subfolder 'sixense' that contains the folders mentioned above.
2. IMPORTANT: Copy the file interface/external/Sixense/lib/osx_x64/release_dll/libsixense_x64.dylib to /usr/lib
3. Delete your build directory, run cmake and build, and you should be all set. 3. Delete your build directory, run cmake and build, and you should be all set.