Squashed 'cmake/' changes from 8647ab0..93c492f

93c492f update help
bdbb86e Remove outdated modules
2eeb40f don't force MACOSX_BUNDLE to be on.
57f63d8 move fixupbundle.cmake.in and improve finding it
bcc9e7b no need to include juggler resource files here when they're included with jugger
9a9b875 make juggler find its config files more safely
032b44d fix typo in comment
46224b1 fixes to findwinhid from vrpn
6c61b84 fix lua targets handling of imported luac and luac in the build.
e449cd7 add support for visual studio 2010 to createlaunchers
f9dc1ea GetGitRevisionDescription: Fixes HASH value in a named branch checkout
f914306 add cppunit module
19bd3ea add fftw module from itk

git-subtree-dir: cmake
git-subtree-split: 93c492fb8fe8c7c9434af72d051795a6ad19cbcd
This commit is contained in:
Ryan Pavlik
2011-02-18 10:22:20 -06:00
parent 6481cc3d75
commit 23e7c6d860
20 changed files with 290 additions and 451 deletions

View File

@@ -20,7 +20,7 @@
# [RUNTIME_LIBRARY_DIRS <dir...>]
# [WORKING_DIRECTORY <dir>]
# [ENVIRONMENT <VAR=value> [<VAR=value>...]])
# - sets GENERIC_LAUNCHER_COMMAND amd GENERIC_LAUNCHER_FAIL_REGULAR_EXPRESSION
# - sets GENERIC_LAUNCHER_COMMAND and GENERIC_LAUNCHER_FAIL_REGULAR_EXPRESSION
#
# Requires these CMake modules:
# ListFilter
@@ -64,18 +64,28 @@ macro(_launcher_system_settings)
# Find user and system name
set(SYSTEM_NAME $ENV{USERDOMAIN})
set(USER_NAME $ENV{USERNAME})
if(MSVC100)
set(VCPROJ_TYPE vcproj)
set(USERFILE_EXTENSION ${SYSTEM_NAME}.${USER_NAME}.user)
set(LAUNCHER_LINESEP "&#x0A;")
if(MSVC10)
set(LAUNCHER_LINESEP "\n")
set(USERFILE_VC_VERSION 10.00)
set(USERFILE_EXTENSION user)
set(VCPROJ_TYPE vcxproj)
elseif(MSVC90)
set(USERFILE_VC_VERSION 9.00)
elseif(MSVC80)
set(USERFILE_VC_VERSION 8.00)
elseif(MSVC71)
set(USERFILE_VC_VERSION 7.10)
elseif(MSVC)
message(STATUS "MSVC but unrecognized version!")
endif()
if(BITS EQUAL 64)
set(USERFILE_PLATFORM x64)
else()
set(USERFILE_PLATFORM Win${BITS})
endif()
set(USERFILE_PLATFORM Win${BITS})
set(_pathdelim ";")
set(_suffix "cmd")
else()
@@ -176,7 +186,7 @@ macro(_launcher_process_args)
set(USERFILE_ENV_COMMANDS)
foreach(_arg "${RUNTIME_LIBRARIES_ENVIRONMENT}" ${ENVIRONMENT})
string(CONFIGURE
"@USERFILE_ENVIRONMENT@&#x0A;@_arg@"
"@USERFILE_ENVIRONMENT@@LAUNCHER_LINESEP@@_arg@"
USERFILE_ENVIRONMENT
@ONLY)
string(CONFIGURE
@@ -189,7 +199,7 @@ endmacro()
macro(_launcher_produce_vcproj_user)
if(MSVC)
file(READ
"${_launchermoddir}/perconfig.vcproj.user.in"
"${_launchermoddir}/perconfig.${VCPROJ_TYPE}.user.in"
_perconfig)
set(USERFILE_CONFIGSECTIONS)
foreach(USERFILE_CONFIGNAME ${CMAKE_CONFIGURATION_TYPES})
@@ -207,8 +217,8 @@ macro(_launcher_produce_vcproj_user)
endforeach()
configure_file("${_launchermoddir}/vcproj.user.in"
${VCPROJNAME}.vcproj.${SYSTEM_NAME}.${USER_NAME}.user
configure_file("${_launchermoddir}/${VCPROJ_TYPE}.user.in"
${VCPROJNAME}.${VCPROJ_TYPE}.${USERFILE_EXTENSION}
@ONLY)
endif()
@@ -244,9 +254,6 @@ function(create_default_target_launcher _targetname)
set(VCPROJNAME "${CMAKE_BINARY_DIR}/ALL_BUILD")
_launcher_produce_vcproj_user()
set(VCPROJNAME "${CMAKE_CURRENT_BINARY_DIR}/${_targetname}")
_launcher_produce_vcproj_user()
_launcher_create_target_launcher()
endfunction()

View File

@@ -250,13 +250,11 @@ if(VRJUGGLER22_FOUND)
set(_vrj22_base_dir "${_vrj22_base_dir}" CACHE INTERNAL "" FORCE)
if(_vrj22_have_base_dir)
file(GLOB
_poss_dirs
${VRJUGGLER22_VJ_BASE_DIR}/share/vrjuggler*/data/configFiles)
find_path(VRJUGGLER22_VJ_CFG_DIR
standalone.jconf
PATHS
${_poss_dirs}
${VRJUGGLER22_VJ_BASE_DIR}/share/vrjuggler-2.2/data/configFiles
${VRJUGGLER22_VJ_BASE_DIR}/share/vrjuggler/data/configFiles
NO_DEFAULT_PATH)
mark_as_advanced(VRJUGGLER22_VJ_CFG_DIR)
endif()
@@ -416,20 +414,19 @@ endfunction()
function(get_vrjuggler_bundle_sources _target_sources)
if(APPLE)
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set(_bundledir "${VRJUGGLER22_VJ_CFG_DIR}/../bundle")
get_filename_component(_bundledir "${_bundledir}" ABSOLUTE)
set(_vj_base_dir .)
set(_vj_data_dir ${vj_base_dir}/share/vrjuggler-2.2)
# Append Mac-specific sources to source list
set(_vj_bundle_src
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib)
${_bundledir}/vrjuggler.icns
${_bundledir}/vrjuggler.plist
${_bundledir}/en.lproj/MainMenu.nib/classes.nib
${_bundledir}/MainMenu.nib/info.nib
${_bundledir}/MainMenu.nib/keyedobjects.nib)
message(STATUS "vjbundlesrc: ${_vj_bundle_src}")
set(${_target_sources}
@@ -438,22 +435,25 @@ function(get_vrjuggler_bundle_sources _target_sources)
PARENT_SCOPE)
# Set destination of nib files
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib
set_source_files_properties(${_bundledir}/MainMenu.nib/classes.nib
${_bundledir}/MainMenu.nib/info.nib
${_bundledir}/MainMenu.nib/keyedobjects.nib
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/en.lproj/MainMenu.nib/)
# Set destination of Resources
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
set_source_files_properties(${_bundledir}/vrjuggler.icns
${_bundledir}/vrjuggler.plist
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/)
endif()
endfunction()
get_filename_component(_vrjuggler22moddir
${CMAKE_CURRENT_LIST_FILE}
PATH)
function(fixup_vrjuggler_app_bundle
_target
_targetInstallDest
@@ -464,9 +464,8 @@ function(fixup_vrjuggler_app_bundle
return()
endif()
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set(PACKAGE_DIR ${_vrjuggler22moddir}/package)
set(MACOSX_PACKAGE_DIR ${PACKAGE_DIR}/macosx)
set(TARGET_LOCATION
"${_targetInstallDest}/${_target}${CMAKE_EXECUTABLE_SUFFIX}")
@@ -476,8 +475,6 @@ function(fixup_vrjuggler_app_bundle
set_target_properties(${_target}
PROPERTIES
MACOSX_BUNDLE
true
MACOSX_BUNDLE_INFO_PLIST
${MACOSX_PACKAGE_DIR}/VRJuggler22BundleInfo.plist.in
MACOSX_BUNDLE_ICON_FILE
@@ -498,7 +495,7 @@ function(fixup_vrjuggler_app_bundle
set(BUNDLE_LIBS ${_extralibs})
set(BUNDLE_LIB_DIRS "${VRJUGGLER22_VJ_BASE_DIR}" ${_libdirs})
configure_file(${MACOSX_PACKAGE_DIR}/fixupbundle.cmake.in
configure_file(${PACKAGE_DIR}/fixupbundle.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/${_target}-fixupbundle-juggler.cmake
@ONLY)
install(SCRIPT

View File

@@ -247,13 +247,11 @@ if(VRJUGGLER30_FOUND)
set(_vrj30_base_dir "${_vrj30_base_dir}" CACHE INTERNAL "" FORCE)
if(_vrj30_have_base_dir)
file(GLOB
_poss_dirs
${VRJUGGLER30_VJ_BASE_DIR}/share/vrjuggler*/data/configFiles)
find_path(VRJUGGLER30_VJ_CFG_DIR
standalone.jconf
PATHS
${_poss_dirs}
${VRJUGGLER30_VJ_BASE_DIR}/share/vrjuggler-3.0/data/configFiles
${VRJUGGLER30_VJ_BASE_DIR}/share/vrjuggler/data/configFiles
NO_DEFAULT_PATH)
mark_as_advanced(VRJUGGLER30_VJ_CFG_DIR)
endif()
@@ -412,20 +410,19 @@ endfunction()
function(get_vrjuggler_bundle_sources _target_sources)
if(APPLE)
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set(_bundledir "${VRJUGGLER30_VJ_CFG_DIR}/../bundle")
get_filename_component(_bundledir "${_bundledir}" ABSOLUTE)
set(_vj_base_dir .)
set(_vj_data_dir ${vj_base_dir}/share/vrjuggler-3.0)
# Append Mac-specific sources to source list
set(_vj_bundle_src
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib)
${_bundledir}/vrjuggler.icns
${_bundledir}/vrjuggler.plist
${_bundledir}/en.lproj/MainMenu.nib/classes.nib
${_bundledir}/MainMenu.nib/info.nib
${_bundledir}/MainMenu.nib/keyedobjects.nib)
message(STATUS "vjbundlesrc: ${_vj_bundle_src}")
set(${_target_sources}
@@ -434,22 +431,25 @@ function(get_vrjuggler_bundle_sources _target_sources)
PARENT_SCOPE)
# Set destination of nib files
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib
set_source_files_properties(${_bundledir}/MainMenu.nib/classes.nib
${_bundledir}/MainMenu.nib/info.nib
${_bundledir}/MainMenu.nib/keyedobjects.nib
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/en.lproj/MainMenu.nib/)
# Set destination of Resources
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
set_source_files_properties(${_bundledir}/vrjuggler.icns
${_bundledir}/vrjuggler.plist
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/)
endif()
endfunction()
get_filename_component(_vrjuggler30moddir
${CMAKE_CURRENT_LIST_FILE}
PATH)
function(fixup_vrjuggler_app_bundle
_target
_targetInstallDest
@@ -460,9 +460,9 @@ function(fixup_vrjuggler_app_bundle
return()
endif()
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set(PACKAGE_DIR ${_vrjuggler30moddir}/package)
set(MACOSX_PACKAGE_DIR ${PACKAGE_DIR}/macosx)
set(TARGET_LOCATION
"${_targetInstallDest}/${_target}${CMAKE_EXECUTABLE_SUFFIX}")
@@ -472,8 +472,6 @@ function(fixup_vrjuggler_app_bundle
set_target_properties(${_target}
PROPERTIES
MACOSX_BUNDLE
true
MACOSX_BUNDLE_INFO_PLIST
${MACOSX_PACKAGE_DIR}/VRJuggler30BundleInfo.plist.in
MACOSX_BUNDLE_ICON_FILE
@@ -494,7 +492,7 @@ function(fixup_vrjuggler_app_bundle
set(BUNDLE_LIBS ${_extralibs})
set(BUNDLE_LIB_DIRS "${VRJUGGLER30_VJ_BASE_DIR}" ${_libdirs})
configure_file(${MACOSX_PACKAGE_DIR}/fixupbundle.cmake.in
configure_file(${PACKAGE_DIR}/fixupbundle.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/${_target}-fixupbundle-juggler.cmake
@ONLY)
install(SCRIPT

View File

@@ -78,7 +78,10 @@ find_path(WINHID_INCLUDE_DIR
PATHS
"${WINHID_ROOT_DIR}"
PATH_SUFFIXES
inc/api)
inc/api
inc/w2k
inc/wxp
inc/wnet)
find_path(WINHID_CRT_INCLUDE_DIR # otherwise you get weird compile errors
NAMES

75
Findcppunit.cmake Normal file
View File

@@ -0,0 +1,75 @@
# - try to find cppunit library
#
# Cache Variables: (probably not for direct use in your scripts)
# CPPUNIT_INCLUDE_DIR
# CPPUNIT_LIBRARY
#
# Non-cache variables you might use in your CMakeLists.txt:
# CPPUNIT_FOUND
# CPPUNIT_INCLUDE_DIRS
# CPPUNIT_LIBRARIES
#
# Requires these CMake modules:
# SelectLibraryConfigurations (included with CMake >= 2.8.0)
# FindPackageHandleStandardArgs (known included with CMake >=2.6.2)
#
# Original Author:
# 2009-2011 Ryan Pavlik <rpavlik@iastate.edu> <abiryan@ryand.net>
# http://academic.cleardefinition.com
# Iowa State University HCI Graduate Program/VRAC
#
# Copyright Iowa State University 2009-2011.
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)
set(CPPUNIT_ROOT_DIR
"${CPPUNIT_ROOT_DIR}"
CACHE
PATH
"Directory to search")
find_library(CPPUNIT_LIBRARY_RELEASE
NAMES
cppunit
HINTS
"${CPPUNIT_ROOT_DIR}")
find_library(CPPUNIT_LIBRARY_DEBUG
NAMES
cppunitd
HINTS
"${CPPUNIT_ROOT_DIR}")
include(SelectLibraryConfigurations)
select_library_configurations(CPPUNIT)
# Might want to look close to the library first for the includes.
get_filename_component(_libdir "${MYSIMPLEPACKAGE_LIBRARY}" PATH)
find_path(CPPUNIT_INCLUDE_DIR
NAMES
cppunit/TestCase.h
HINTS
"${_libdir}/.."
PATHS
"${CPPUNIT_ROOT_DIR}"
PATH_SUFFIXES
include/)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(cppunit
DEFAULT_MSG
CPPUNIT_LIBRARY
CPPUNIT_INCLUDE_DIR)
if(CPPUNIT_FOUND)
set(CPPUNIT_LIBRARIES ${CPPUNIT_LIBRARY} ${CMAKE_DL_LIBS})
set(CPPUNIT_INCLUDE_DIRS "${CPPUNIT_INCLUDE_DIR}")
mark_as_advanced(CPPUNIT_ROOT_DIR)
endif()
mark_as_advanced(CPPUNIT_INCLUDE_DIR
CPPUNIT_LIBRARY_RELEASE
CPPUNIT_LIBRARY_DEBUG)

View File

@@ -28,6 +28,3 @@ endif()
file(READ "@GIT_DATA@/head-ref" HEAD_HASH LIMIT 1024)
string(STRIP "${HEAD_HASH}" HEAD_HASH)
set(HEAD_HASH "${HEAD_CONTENTS}")

View File

@@ -30,15 +30,26 @@ set(__add_lua YES)
include(FileCopyTargets)
function(add_lua_target _target _dest)
if(NOT ARGN)
message(WARNING
"In add_lua_target call for target ${_target}, no source files were specified!")
return()
endif()
if(NOT LUA_TARGET_LUAC_EXECUTABLE)
set(LUA_TARGET_LUAC_EXECUTABLE luac)
if(TARGET luac)
message(STATUS "luac target found, using that in add_lua_target")
set(LUA_TARGET_LUAC_EXECUTABLE luac)
else()
find_executable(LUA_TARGET_LUAC_EXECUTABLE
NAMES
luac)
endif()
endif()
if(NOT LUA_TARGET_LUAC_EXECUTABLE)
message(FATAL_ERROR "Can't find luac: please give LUA_TARGET_LUAC_EXECUTABLE a useful value - currently ${LUA_TARGET_LUAC_EXECUTABLE}")
endif()
set(ALLFILES)
@@ -70,7 +81,10 @@ function(add_lua_target _target _dest)
SOURCES ${ARGN}
DEPENDS ${ALLFILES})
if(TARGET "${LUA_TARGET_LUAC_EXECUTABLE}")
add_dependencies(${_target} ${LUA_TARGET_LUAC_EXECUTABLE})
get_property(_luac_imported TARGET "${LUA_TARGET_LUAC_EXECUTABLE}" PROPERTY IMPORTED)
if(NOT _luac_imported)
add_dependencies(${_target} ${LUA_TARGET_LUAC_EXECUTABLE})
endif()
endif()
set_property(TARGET ${_target} PROPERTY FILE_COPY_TARGET YES)

View File

@@ -1,149 +0,0 @@
# - A script to turn a VR Juggler app target into a Mac OS X bundle
#
# add_vrjuggler_bundle_sources(SOURCES_VAR_NAME) - run before add_executable
# finish_vrjuggler_bundle(TARGET_NAME LIB_DIRS) - run after add_executable
#
# Original Author:
# 2009-2010 Ryan Pavlik <rpavlik@iastate.edu> <abiryan@ryand.net>
# http://academic.cleardefinition.com
# Iowa State University HCI Graduate Program/VRAC
#
# Copyright Iowa State University 2009-2010.
# Distributed under the Boost Software License, Version 1.0.
# (See accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)
function(add_vrjuggler_bundle_sources _target_sources)
if(APPLE)
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set(_vj_base_dir .)
set(_vj_data_dir ${vj_base_dir}/share/vrjuggler-2.2)
# Append Mac-specific sources to source list
set(_vj_bundle_src
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib)
# Add and set destination of VR Juggler required files
# configFiles *.jconf
file(GLOB
_vj_config_files
${VRJ22_LIBRARY_DIR}/../share/vrjuggler-2.2/data/configFiles/*.jconf)
list(APPEND _vj_bundle_src ${_vj_config_files})
# definitions *.jdef
file(GLOB
_vj_defs_files
${VRJ22_LIBRARY_DIR}/../share/vrjuggler-2.2/data/definitions/*.jdef)
list(APPEND _vj_bundle_src ${_vj_defs_files})
# models *.flt
file(GLOB
_vj_model_files
${VRJ22_LIBRARY_DIR}/../share/vrjuggler-2.2/data/models/*.flt)
list(APPEND _vj_bundle_src ${_vj_model_files})
# sounds *.wav
file(GLOB
_vj_sound_files
${VRJ22_LIBRARY_DIR}/../share/vrjuggler-2.2/data/sounds/*.wav)
list(APPEND _vj_bundle_src ${_vj_sound_files})
# calibration.table - needed?
list(APPEND
_vj_bundle_src
${VRJ22_LIBRARY_DIR}/../share/vrjuggler-2.2/data/calibration.table)
message(STATUS "vjbundlesrc: ${_vj_bundle_src}")
set(${_target_sources}
${${_target_sources}}
${_vj_bundle_src}
PARENT_SCOPE)
# Set destination of nib files
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/en.lproj/MainMenu.nib/)
# Set destination of Resources
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/)
set_source_files_properties(${_vj_config_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/configFiles/)
set_source_files_properties(${_vj_defs_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/definitions/)
set_source_files_properties(${_vj_model_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/models/)
set_source_files_properties(${_vj_sound_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/sounds/)
set_source_files_properties(${VRJ22_LIBRARY_DIR}/../share/vrjuggler-2.2/data/calibration.table
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/)
endif()
endfunction()
function(finish_vrjuggler_bundle _target _libdirs)
if(APPLE)
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set_target_properties(${_target}
PROPERTIES
MACOSX_BUNDLE
true
MACOSX_BUNDLE_INFO_PLIST
${MACOSX_PACKAGE_DIR}/VRJuggler22BundleInfo.plist.in
MACOSX_BUNDLE_ICON_FILE
vrjuggler.icns
MACOSX_BUNDLE_INFO_STRING
"${PROJECT_NAME} (VR Juggler Application) version ${CPACK_PACKAGE_VERSION}, created by ${CPACK_PACKAGE_VENDOR}"
MACOSX_BUNDLE_GUI_IDENTIFIER
org.vrjuggler.${PROJECT_NAME}
MACOSX_BUNDLE_SHORT_VERSION_STRING
${CPACK_PACKAGE_VERSION}
MACOSX_BUNDLE_BUNDLE_VERSION
${CPACK_PACKAGE_VERSION})
set(BUNDLE_LIBS
libboost_filesystem-1_34_1.dylib
libboost_signals-1_34_1.dylib)
set(BUNDLE_LIB_DIRS ${_libdirs})
configure_file(${MACOSX_PACKAGE_DIR}/fixupbundle.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/${_target}-fixupbundle.cmake
@ONLY)
add_custom_command(TARGET
${_target}
POST_BUILD
COMMAND
${CMAKE_COMMAND}
-P
${CMAKE_CURRENT_BINARY_DIR}/${_target}-fixupbundle.cmake
VERBATIM)
endif()
endfunction()

View File

@@ -1,146 +0,0 @@
# - A script to turn a VR Juggler app target into a Mac OS X bundle
#
# add_vrjuggler_bundle_sources(SOURCES_VAR_NAME) - run before add_executable
# finish_vrjuggler_bundle(TARGET_NAME LIB_DIRS) - run after add_executable
#
# Original Author:
# 2009-2010 Ryan Pavlik <rpavlik@iastate.edu> <abiryan@ryand.net>
# http://academic.cleardefinition.com
# Iowa State University HCI Graduate Program/VRAC
# Updated for VR Juggler 3.0 by:
# Brandon Newendorp <brandon@newendorp.com>
function(add_vrjuggler_bundle_sources _target_sources)
if(APPLE)
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set(_vj_base_dir .)
set(_vj_data_dir ${vj_base_dir}/share/vrjuggler-3.0)
# Append Mac-specific sources to source list
set(_vj_bundle_src
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib)
# Add and set destination of VR Juggler required files
# configFiles *.jconf
file(GLOB
_vj_config_files
${VRJ30_LIBRARY_DIR}/../share/vrjuggler-3.0/data/configFiles/*.jconf)
list(APPEND _vj_bundle_src ${_vj_config_files})
# definitions *.jdef
file(GLOB
_vj_defs_files
${VRJ30_LIBRARY_DIR}/../share/vrjuggler-3.0/data/definitions/*.jdef)
list(APPEND _vj_bundle_src ${_vj_defs_files})
# models *.flt
file(GLOB
_vj_model_files
${VRJ30_LIBRARY_DIR}/../share/vrjuggler-3.0/data/models/*.flt)
list(APPEND _vj_bundle_src ${_vj_model_files})
# sounds *.wav
file(GLOB
_vj_sound_files
${VRJ30_LIBRARY_DIR}/../share/vrjuggler-3.0/data/sounds/*.wav)
list(APPEND _vj_bundle_src ${_vj_sound_files})
# calibration.table - needed?
list(APPEND
_vj_bundle_src
${VRJ30_LIBRARY_DIR}/../share/vrjuggler-3.0/data/calibration.table)
message(STATUS "vjbundlesrc: ${_vj_bundle_src}")
set(${_target_sources}
${${_target_sources}}
${_vj_bundle_src}
PARENT_SCOPE)
# Set destination of nib files
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/classes.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/info.nib
${MACOSX_PACKAGE_DIR}/Resources/en.lproj/MainMenu.nib/keyedobjects.nib
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/en.lproj/MainMenu.nib/)
# Set destination of Resources
set_source_files_properties(${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.icns
${MACOSX_PACKAGE_DIR}/Resources/vrjuggler.plist
PROPERTIES
MACOSX_PACKAGE_LOCATION
Resources/)
set_source_files_properties(${_vj_config_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/configFiles/)
set_source_files_properties(${_vj_defs_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/definitions/)
set_source_files_properties(${_vj_model_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/models/)
set_source_files_properties(${_vj_sound_files}
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/sounds/)
set_source_files_properties(${VRJ30_LIBRARY_DIR}/../share/vrjuggler-3.0/data/calibration.table
PROPERTIES
MACOSX_PACKAGE_LOCATION
${_vj_data_dir}/data/)
endif()
endfunction()
function(finish_vrjuggler_bundle _target _libdirs)
if(APPLE)
if(NOT MACOSX_PACKAGE_DIR)
set(MACOSX_PACKAGE_DIR ${CMAKE_SOURCE_DIR}/cmake/package/macosx)
endif()
set_target_properties(${_target}
PROPERTIES
MACOSX_BUNDLE
true
MACOSX_BUNDLE_INFO_PLIST
${MACOSX_PACKAGE_DIR}/VRJuggler30BundleInfo.plist.in
MACOSX_BUNDLE_ICON_FILE
vrjuggler.icns
MACOSX_BUNDLE_INFO_STRING
"${PROJECT_NAME} (VR Juggler Application) version ${CPACK_PACKAGE_VERSION}, created by ${CPACK_PACKAGE_VENDOR}"
MACOSX_BUNDLE_GUI_IDENTIFIER
org.vrjuggler.${PROJECT_NAME}
MACOSX_BUNDLE_SHORT_VERSION_STRING
${CPACK_PACKAGE_VERSION}
MACOSX_BUNDLE_BUNDLE_VERSION
${CPACK_PACKAGE_VERSION})
set(BUNDLE_LIBS
libboost_filesystem-mt.dylib
libboost_signals-mt.dylib)
set(BUNDLE_LIB_DIRS ${_libdirs})
configure_file(${MACOSX_PACKAGE_DIR}/fixupbundle.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/${_target}-fixupbundle.cmake
@ONLY)
add_custom_command(TARGET
${_target}
POST_BUILD
COMMAND
${CMAKE_COMMAND}
-P
${CMAKE_CURRENT_BINARY_DIR}/${_target}-fixupbundle.cmake
VERBATIM)
endif()
endfunction()

View File

@@ -0,0 +1,68 @@
## FFTW can be compiled and subsequently linked against
## various data types.
## There is a single set of include files, and then muttiple libraries,
## One for each type. I.e. libfftw.a-->double, libfftwf.a-->float
## The following logic belongs in the individual package
## MARK_AS_ADVANCED(USE_FFTWD)
## OPTION(USE_FFTWD "Use double precision FFTW if found" ON)
## MARK_AS_ADVANCED(USE_FFTWF)
## OPTION(USE_FFTWF "Use single precision FFTW if found" ON)
IF(USE_FFTWD OR USE_FFTWF)
SET(FFTW_INC_SEARCHPATH
/sw/include
/usr/include
/usr/local/include
/usr/include/fftw
/usr/local/include/fftw
)
FIND_PATH(FFTW_INCLUDE_PATH fftw3.h ${FFTW_INC_SEARCHPATH})
IF(FFTW_INCLUDE_PATH)
SET(FFTW_INCLUDE ${FFTW_INCLUDE_PATH})
ENDIF (FFTW_INCLUDE_PATH)
IF(FFTW_INCLUDE)
INCLUDE_DIRECTORIES( ${FFTW_INCLUDE})
ENDIF(FFTW_INCLUDE)
GET_FILENAME_COMPONENT(FFTW_INSTALL_BASE_PATH ${FFTW_INCLUDE_PATH} PATH)
SET(FFTW_LIB_SEARCHPATH
${FFTW_INSTALL_BASE_PATH}/lib
/usr/lib/fftw
/usr/local/lib/fftw
)
IF(USE_FFTWD)
MARK_AS_ADVANCED(FFTWD_LIB)
# OPTION(FFTWD_LIB "The full path to the fftw3 library (including the library)" )
FIND_LIBRARY(FFTWD_LIB fftw3 ${FFTW_LIB_SEARCHPATH}) #Double Precision Lib
FIND_LIBRARY(FFTWD_THREADS_LIB fftw3_threads ${FFTW_LIB_SEARCHPATH}) #Double Precision Lib only if compiled with threads support
IF(FFTWD_LIB)
SET(FFTWD_FOUND 1)
IF(FFTWD_THREADS_LIB)
SET(FFTWD_LIB ${FFTWD_LIB} ${FFTWD_THREADS_LIB} )
ENDIF(FFTWD_THREADS_LIB)
ENDIF(FFTWD_LIB)
ENDIF(USE_FFTWD)
IF(USE_FFTWF)
MARK_AS_ADVANCED(FFTWF_LIB)
# OPTION(FFTWF_LIB "The full path to the fftw3f library (including the library)" )
FIND_LIBRARY(FFTWF_LIB fftw3f ${FFTW_LIB_SEARCHPATH}) #Single Precision Lib
FIND_LIBRARY(FFTWF_THREADS_LIB fftw3f_threads ${FFTW_LIB_SEARCHPATH}) #Single Precision Lib only if compiled with threads support
IF(FFTWF_LIB)
SET(FFTWF_FOUND 1)
IF(FFTWF_THREADS_LIB)
SET(FFTWF_LIB ${FFTWF_LIB} ${FFTWF_THREADS_LIB} )
ENDIF(FFTWF_THREADS_LIB)
ENDIF(FFTWF_LIB)
ENDIF(USE_FFTWF)
ENDIF(USE_FFTWD OR USE_FFTWF)

View File

@@ -0,0 +1,7 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='@USERFILE_CONFIGNAME@|@USERFILE_PLATFORM@'">
<LocalDebuggerEnvironment>@USERFILE_ENVIRONMENT@</LocalDebuggerEnvironment>
<DebuggerFlavor>WindowsLocalDebugger</DebuggerFlavor>
<LocalDebuggerCommand>${USERFILE_@USERFILE_CONFIGNAME@_COMMAND}</LocalDebuggerCommand>
<LocalDebuggerCommandArguments>@USERFILE_COMMAND_ARGUMENTS@</LocalDebuggerCommandArguments>
<LocalDebuggerWorkingDirectory>@USERFILE_WORKING_DIRECTORY@</LocalDebuggerWorkingDirectory>
</PropertyGroup>

View File

@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
@USERFILE_CONFIGSECTIONS@
</Project>

File diff suppressed because one or more lines are too long

View File

@@ -470,7 +470,7 @@ a few.
[RUNTIME_LIBRARY_DIRS <dir...>]
[WORKING_DIRECTORY <dir>]
[ENVIRONMENT <VAR=value> [<VAR=value>...]])
- sets GENERIC_LAUNCHER_COMMAND amd GENERIC_LAUNCHER_FAIL_REGULAR_EXPRESSION
- sets GENERIC_LAUNCHER_COMMAND and GENERIC_LAUNCHER_FAIL_REGULAR_EXPRESSION
@@ -2658,6 +2658,41 @@ a few.
Boost Software License, Version 1.0. (See accompanying file
LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
Findcppunit
try to find cppunit library
Cache Variables: (probably not for direct use in your scripts)
CPPUNIT_INCLUDE_DIR
CPPUNIT_LIBRARY
Non-cache variables you might use in your CMakeLists.txt:
CPPUNIT_FOUND
CPPUNIT_INCLUDE_DIRS
CPPUNIT_LIBRARIES
Requires these CMake modules:
SelectLibraryConfigurations (included with CMake >= 2.8.0)
FindPackageHandleStandardArgs (known included with CMake >=2.6.2)
Original Author: 2009-2011 Ryan Pavlik <rpavlik@iastate.edu>
<abiryan@ryand.net> http://academic.cleardefinition.com Iowa State
University HCI Graduate Program/VRAC
Copyright Iowa State University 2009-2011. Distributed under the
Boost Software License, Version 1.0. (See accompanying file
LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
Findcutil
find NVIDIA CUDA and source for the cutil library, building cutil if
needed.
@@ -3183,39 +3218,6 @@ a few.
Boost Software License, Version 1.0. (See accompanying file
LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
MakeVRJugglerAppBundle
A script to turn a VR Juggler app target into a Mac OS X bundle
add_vrjuggler_bundle_sources(SOURCES_VAR_NAME) - run before add_executable
finish_vrjuggler_bundle(TARGET_NAME LIB_DIRS) - run after add_executable
Original Author: 2009-2010 Ryan Pavlik <rpavlik@iastate.edu>
<abiryan@ryand.net> http://academic.cleardefinition.com Iowa State
University HCI Graduate Program/VRAC
Copyright Iowa State University 2009-2010. Distributed under the
Boost Software License, Version 1.0. (See accompanying file
LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
MakeVRJugglerAppBundle30
A script to turn a VR Juggler app target into a Mac OS X bundle
add_vrjuggler_bundle_sources(SOURCES_VAR_NAME) - run before add_executable
finish_vrjuggler_bundle(TARGET_NAME LIB_DIRS) - run after add_executable
Original Author: 2009-2010 Ryan Pavlik <rpavlik@iastate.edu>
<abiryan@ryand.net> http://academic.cleardefinition.com Iowa State
University HCI Graduate Program/VRAC Updated for VR Juggler 3.0 by:
Brandon Newendorp <brandon@newendorp.com>
OptionRequires
Add an option that depends on one or more variables being true.

View File

@@ -1,4 +0,0 @@
{
IBClasses = ({CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; });
IBVersion = 1;
}

View File

@@ -1,23 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IBDocumentLocation</key>
<string>94 80 356 240 0 0 1280 832 </string>
<key>IBEditorPositions</key>
<dict>
<key>29</key>
<string>501 350 260 44 0 0 1280 832 </string>
</dict>
<key>IBFramework Version</key>
<string>446.1</string>
<key>IBOldestOS</key>
<integer>3</integer>
<key>IBOpenObjects</key>
<array>
<integer>29</integer>
</array>
<key>IBSystem Version</key>
<string>8P135</string>
</dict>
</plist>

View File

@@ -1,10 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>VRJConfigHandling</key>
<false/>
<key>VRJDelegateClass</key>
<string>VRJBasicDelegate</string>
</dict>
</plist>