Commit d1640b11 authored by Philip Lowman's avatar Philip Lowman

BUG: Fixed Issue #7331 Bugs in Findosg*.cmake. Also added OPENTHREADS_LIBRARIES.

parent d69e6860
......@@ -38,7 +38,7 @@
# standard install paths.
# Explicit -DVAR=value arguments should still be able to override everything.
FIND_PATH(OPENTHREADS_INCLUDE_DIR OpenThreads/Thread
find_path(OPENTHREADS_INCLUDE_DIR OpenThreads/Thread
HINTS
$ENV{OPENTHREADS_INCLUDE_DIR}
$ENV{OPENTHREADS_DIR}/include
......@@ -62,7 +62,7 @@ FIND_PATH(OPENTHREADS_INCLUDE_DIR OpenThreads/Thread
)
FIND_LIBRARY(OPENTHREADS_LIBRARY
find_library(OPENTHREADS_LIBRARY
NAMES OpenThreads OpenThreadsWin32
HINTS
$ENV{OPENTHREADS_LIBRARY_DIR}
......@@ -95,8 +95,7 @@ FIND_LIBRARY(OPENTHREADS_LIBRARY
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]/lib
)
FIND_LIBRARY(OPENTHREADS_LIBRARY_DEBUG
find_library(OPENTHREADS_LIBRARY_DEBUG
NAMES OpenThreadsd OpenThreadsWin32d
HINTS
$ENV{OPENTHREADS_DEBUG_LIBRARY_DIR}
......@@ -128,18 +127,15 @@ FIND_LIBRARY(OPENTHREADS_LIBRARY_DEBUG
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]/lib
)
if(OPENTHREADS_LIBRARY_DEBUG)
set(OPENTHREADS_LIBRARIES
optimized ${OPENTHREADS_LIBRARY}
debug ${OPENTHREADS_LIBRARY_DEBUG})
else()
set(OPENTHREADS_LIBRARY_DEBUG ${OPENTHREADS_LIBRARY})
set(OPENTHREADS_LIBRARIES ${OPENTHREADS_LIBRARY})
endif()
IF(OPENTHREADS_LIBRARY)
IF(NOT OPENTHREADS_LIBRARY_DEBUG)
#MESSAGE("-- Warning Debug OpenThreads not found, using: ${OPENTHREADS_LIBRARY}")
#SET(OPENTHREADS_LIBRARY_DEBUG "${OPENTHREADS_LIBRARY}")
SET(OPENTHREADS_LIBRARY_DEBUG "${OPENTHREADS_LIBRARY}" CACHE FILEPATH "Debug version of OpenThreads Library (use regular version if not available)" FORCE)
ENDIF(NOT OPENTHREADS_LIBRARY_DEBUG)
ENDIF(OPENTHREADS_LIBRARY)
SET(OPENTHREADS_FOUND "NO")
IF(OPENTHREADS_INCLUDE_DIR AND OPENTHREADS_LIBRARY)
SET(OPENTHREADS_FOUND "YES")
# MESSAGE("-- Found OpenThreads: "${OPENTHREADS_LIBRARY})
ENDIF(OPENTHREADS_INCLUDE_DIR AND OPENTHREADS_LIBRARY)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OPENTHREADS DEFAULT_MSG
OPENTHREADS_LIBRARY OPENTHREADS_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osg
# This module defines
# OSG_LIBRARY
# OSG_FOUND, if false, do not try to link to osg
# OSG_INCLUDE_DIR, where to find the headers
#
# OSG_FOUND - Was the Osg found?
# OSG_INCLUDE_DIR - Where to find the headers
# OSG_LIBRARIES - The libraries to link against for the OSG (use this)
#
# OSG_LIBRARY - The OSG library
# OSG_LIBRARY_DEBUG - The OSG debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,44 +29,9 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgUtil/SceneView>
# Try the user's environment request before anything else.
FIND_PATH(OSG_INCLUDE_DIR osg/PositionAttitudeTransform
HINTS
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSG_LIBRARY
NAMES osg
HINTS
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSG_FOUND "NO")
IF(OSG_LIBRARY AND OSG_INCLUDE_DIR)
SET(OSG_FOUND "YES")
ENDIF(OSG_LIBRARY AND OSG_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSG osg/PositionAttitudeTransform)
OSG_FIND_LIBRARY(OSG osg)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSG DEFAULT_MSG OSG_LIBRARY OSG_INCLUDE_DIR)
# This is part of the Findosg* suite used to find OpenSceneGraph components.
# Each component is separate and you must opt in to each module. You must
# also opt into OpenGL and OpenThreads (and Producer if needed) as these
# modules won't do it for you. This is to allow you control over your own
# system piece by piece in case you need to opt out of certain components
# or change the Find behavior for a particular module (perhaps because the
# default FindOpenGL.cmake module doesn't work with your system as an
# example).
# If you want to use a more convenient module that includes everything,
# use the FindOpenSceneGraph.cmake instead of the Findosg*.cmake modules.
#
# Locate osgAnimation
# This module defines
#
# OSGANIMATION_FOUND - Was osgAnimation found?
# OSGANIMATION_INCLUDE_DIR - Where to find the headers
# OSGANIMATION_LIBRARIES - The libraries to link against for the OSG (use this)
#
# OSGANIMATION_LIBRARY - The OSG library
# OSGANIMATION_LIBRARY_DEBUG - The OSG debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
# used in building osg.
#
# Created by Eric Wing.
# Header files are presumed to be included like
# #include <osg/PositionAttitudeTransform>
# #include <osgAnimation/Animation>
include(Findosg_functions)
OSG_FIND_PATH (OSGANIMATION osgAnimation/Animation)
OSG_FIND_LIBRARY(OSGANIMATION osgAnimation)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGANIMATION DEFAULT_MSG
OSGANIMATION_LIBRARY OSGANIMATION_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgDB
# This module defines
# OSGDB_LIBRARY
# OSGDB_FOUND, if false, do not try to link to osgDB
# OSGDB_INCLUDE_DIR, where to find the headers
#
# OSGDB_FOUND - Was osgDB found?
# OSGDB_INCLUDE_DIR - Where to find the headers
# OSGDB_LIBRARIES - The libraries to link against for the osgDB (use this)
#
# OSGDB_LIBRARY - The osgDB library
# OSGDB_LIBRARY_DEBUG - The osgDB debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgDB/DatabasePager>
# Try the user's environment request before anything else.
FIND_PATH(OSGDB_INCLUDE_DIR osgDB/DatabasePager
HINTS
$ENV{OSGDB_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGDB_LIBRARY
NAMES osgDB
HINTS
$ENV{OSGDB_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGDB_FOUND "NO")
IF(OSGDB_LIBRARY AND OSGDB_INCLUDE_DIR)
SET(OSGDB_FOUND "YES")
ENDIF(OSGDB_LIBRARY AND OSGDB_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGDB osgDB/DatabasePager)
OSG_FIND_LIBRARY(OSGDB osgDB)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGDB DEFAULT_MSG
OSGDB_LIBRARY OSGDB_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgFX
# This module defines
# OSGFX_LIBRARY
# OSGFX_FOUND, if false, do not try to link to osgFX
# OSGFX_INCLUDE_DIR, where to find the headers
#
# OSGFX_FOUND - Was osgFX found?
# OSGFX_INCLUDE_DIR - Where to find the headers
# OSGFX_LIBRARIES - The libraries to link against for the osgFX (use this)
#
# OSGFX_LIBRARY - The osgFX library
# OSGFX_LIBRARY_DEBUG - The osgFX debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgFX/BumpMapping>
# Try the user's environment request before anything else.
FIND_PATH(OSGFX_INCLUDE_DIR osgFX/BumpMapping
HINTS
$ENV{OSGFX_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGFX_LIBRARY
NAMES osgFX
HINTS
$ENV{OSGFX_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGFX_FOUND "NO")
IF(OSGFX_LIBRARY AND OSGFX_INCLUDE_DIR)
SET(OSGFX_FOUND "YES")
ENDIF(OSGFX_LIBRARY AND OSGFX_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGFX osgFX/BumpMapping)
OSG_FIND_LIBRARY(OSGFX osgFX)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGFX DEFAULT_MSG
OSGFX_LIBRARY OSGFX_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgGA
# This module defines
# OSGGA_LIBRARY
# OSGGA_FOUND, if false, do not try to link to osgGA
# OSGGA_INCLUDE_DIR, where to find the headers
#
# OSGGA_FOUND - Was osgGA found?
# OSGGA_INCLUDE_DIR - Where to find the headers
# OSGGA_LIBRARIES - The libraries to link against for the osgGA (use this)
#
# OSGGA_LIBRARY - The osgGA library
# OSGGA_LIBRARY_DEBUG - The osgGA debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgGA/FlightManipulator>
# Try the user's environment request before anything else.
FIND_PATH(OSGGA_INCLUDE_DIR osgGA/FlightManipulator
HINTS
$ENV{OSGGA_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGGA_LIBRARY
NAMES osgGA
HINTS
$ENV{OSGGA_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGGA_FOUND "NO")
IF(OSGGA_LIBRARY AND OSGGA_INCLUDE_DIR)
SET(OSGGA_FOUND "YES")
ENDIF(OSGGA_LIBRARY AND OSGGA_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGGA osgGA/FlightManipulator)
OSG_FIND_LIBRARY(OSGGA osgGA)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGGA DEFAULT_MSG
OSGGA_LIBRARY OSGGA_INCLUDE_DIR)
......@@ -9,11 +9,15 @@
# If you want to use a more convenient module that includes everything,
# use the FindOpenSceneGraph.cmake instead of the Findosg*.cmake modules.
#
# Locate osgIntrospection
# Locate osgINTROSPECTION
# This module defines
# OSGINTROSPECTION_LIBRARY
# OSGINTROSPECTION_FOUND, if false, do not try to link to osgIntrospection
# OSGINTROSPECTION_INCLUDE_DIR, where to find the headers
#
# OSGINTROSPECTION_FOUND - Was osgIntrospection found?
# OSGINTROSPECTION_INCLUDE_DIR - Where to find the headers
# OSGINTROSPECTION_LIBRARIES - The libraries to link for osgIntrospection (use this)
#
# OSGINTROSPECTION_LIBRARY - The osgIntrospection library
# OSGINTROSPECTION_LIBRARY_DEBUG - The osgIntrospection debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgIntrospection/Reflection>
# Try the user's environment request before anything else.
FIND_PATH(OSGINTROSPECTION_INCLUDE_DIR osgIntrospection/Reflection
HINTS
$ENV{OSGINTROSPECTION_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGINTROSPECTION_LIBRARY
NAMES osgIntrospection
HINTS
$ENV{OSGINTROSPECTION_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGINTROSPECTION_FOUND "NO")
IF(OSGINTROSPECTION_LIBRARY AND OSGINTROSPECTION_INCLUDE_DIR)
SET(OSGINTROSPECTION_FOUND "YES")
ENDIF(OSGINTROSPECTION_LIBRARY AND OSGINTROSPECTION_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGINTROSPECTION osgIntrospection/Reflection)
OSG_FIND_LIBRARY(OSGINTROSPECTION osgIntrospection)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGINTROSPECTION DEFAULT_MSG
OSGINTROSPECTION_LIBRARY OSGINTROSPECTION_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgManipulator
# This module defines
# OSG_LIBRARY
# OSGMANIPULATOR_FOUND, if false, do not try to link to osgManipulator
# OSGMANIPULATOR_INCLUDE_DIR, where to find the headers
#
# OSGMANIPULATOR_FOUND - Was osgManipulator found?
# OSGMANIPULATOR_INCLUDE_DIR - Where to find the headers
# OSGMANIPULATOR_LIBRARIES - The libraries to link for osgManipulator (use this)
#
# OSGMANIPULATOR_LIBRARY - The osgManipulator library
# OSGMANIPULATOR_LIBRARY_DEBUG - The osgManipulator debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgManipulator/TrackballDragger>
# Try the user's environment request before anything else.
FIND_PATH(OSGMANIPULATOR_INCLUDE_DIR osgManipulator/TrackballDragger
HINTS
$ENV{OSGMANIPULATOR_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGMANIPULATOR_LIBRARY
NAMES osgManipulator
HINTS
$ENV{OSGMANIPULATOR_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGMANIPULATOR_FOUND "NO")
IF(OSGMANIPULATOR_LIBRARY AND OSGMANIPULATOR_INCLUDE_DIR)
SET(OSGMANIPULATOR_FOUND "YES")
ENDIF(OSGMANIPULATOR_LIBRARY AND OSGMANIPULATOR_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGMANIPULATOR osgManipulator/TrackballDragger)
OSG_FIND_LIBRARY(OSGMANIPULATOR osgManipulator)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGMANIPULATOR DEFAULT_MSG
OSGMANIPULATOR_LIBRARY OSGMANIPULATOR_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgParticle
# This module defines
# OSGPARTICLE_LIBRARY
# OSGPARTICLE_FOUND, if false, do not try to link to osgParticle
# OSGPARTICLE_INCLUDE_DIR, where to find the headers
#
# OSGPARTICLE_FOUND - Was osgParticle found?
# OSGPARTICLE_INCLUDE_DIR - Where to find the headers
# OSGPARTICLE_LIBRARIES - The libraries to link for osgParticle (use this)
#
# OSGPARTICLE_LIBRARY - The osgParticle library
# OSGPARTICLE_LIBRARY_DEBUG - The osgParticle debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgParticle/FireEffect>
# Try the user's environment request before anything else.
FIND_PATH(OSGPARTICLE_INCLUDE_DIR osgParticle/FireEffect
HINTS
$ENV{OSGPARTICLE_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGPARTICLE_LIBRARY
NAMES osgParticle
HINTS
$ENV{OSGPARTICLE_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGPARTICLE_FOUND "NO")
IF(OSGPARTICLE_LIBRARY AND OSGPARTICLE_INCLUDE_DIR)
SET(OSGPARTICLE_FOUND "YES")
ENDIF(OSGPARTICLE_LIBRARY AND OSGPARTICLE_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGPARTICLE osgParticle/FireEffect)
OSG_FIND_LIBRARY(OSGPARTICLE osgParticle)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGPARTICLE DEFAULT_MSG
OSGPARTICLE_LIBRARY OSGPARTICLE_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgProducer
# This module defines
# OSGPRODUCER_LIBRARY
# OSGPRODUCER_FOUND, if false, do not try to link to osgProducer
# OSGPRODUCER_INCLUDE_DIR, where to find the headers
#
# OSGPRODUCER_FOUND - Was osgProducer found?
# OSGPRODUCER_INCLUDE_DIR - Where to find the headers
# OSGPRODUCER_LIBRARIES - The libraries to link for osgProducer (use this)
#
# OSGPRODUCER_LIBRARY - The osgProducer library
# OSGPRODUCER_LIBRARY_DEBUG - The osgProducer debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgProducer/OsgSceneHandler>
# Try the user's environment request before anything else.
FIND_PATH(OSGPRODUCER_INCLUDE_DIR osgProducer/OsgSceneHandler
HINTS
$ENV{OSGPRODUCER_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGPRODUCER_LIBRARY
NAMES osgProducer
HINTS
$ENV{OSGPRODUCER_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGPRODUCER_FOUND "NO")
IF(OSGPRODUCER_LIBRARY AND OSGPRODUCER_INCLUDE_DIR)
SET(OSGPRODUCER_FOUND "YES")
ENDIF(OSGPRODUCER_LIBRARY AND OSGPRODUCER_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGPRODUCER osgProducer/OsgSceneHandler)
OSG_FIND_LIBRARY(OSGPRODUCER osgProducer)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGPRODUCER DEFAULT_MSG
OSGPRODUCER_LIBRARY OSGPRODUCER_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgShadow
# This module defines
# OSGSHADOW_LIBRARY
# OSGSHADOW_FOUND, if false, do not try to link to osgShadow
# OSGSHADOW_INCLUDE_DIR, where to find the headers
#
# OSGSHADOW_FOUND - Was osgShadow found?
# OSGSHADOW_INCLUDE_DIR - Where to find the headers
# OSGSHADOW_LIBRARIES - The libraries to link for osgShadow (use this)
#
# OSGSHADOW_LIBRARY - The osgShadow library
# OSGSHADOW_LIBRARY_DEBUG - The osgShadow debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgShadow/ShadowTexture>
# Try the user's environment request before anything else.
FIND_PATH(OSGSHADOW_INCLUDE_DIR osgShadow/ShadowTexture
HINTS
$ENV{OSGSHADOW_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
/opt
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OpenThreads_ROOT]
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]
)
FIND_LIBRARY(OSGSHADOW_LIBRARY
NAMES osgShadow
HINTS
$ENV{OSGSHADOW_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES lib64 lib
PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local
/usr
/sw
/opt/local
/opt/csw
/opt
)
SET(OSGSHADOW_FOUND "NO")
IF(OSGSHADOW_LIBRARY AND OSGSHADOW_INCLUDE_DIR)
SET(OSGSHADOW_FOUND "YES")
ENDIF(OSGSHADOW_LIBRARY AND OSGSHADOW_INCLUDE_DIR)
include(Findosg_functions)
OSG_FIND_PATH (OSGSHADOW osgShadow/ShadowTexture)
OSG_FIND_LIBRARY(OSGSHADOW osgShadow)
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OSGSHADOW DEFAULT_MSG
OSGSHADOW_LIBRARY OSGSHADOW_INCLUDE_DIR)
......@@ -11,9 +11,13 @@
#
# Locate osgSim
# This module defines
# OSGSIM_LIBRARY
# OSGSIM_FOUND, if false, do not try to link to osgSim
# OSGSIM_INCLUDE_DIR, where to find the headers
#
# OSGSIM_FOUND - Was osgSim found?
# OSGSIM_INCLUDE_DIR - Where to find the headers
# OSGSIM_LIBRARIES - The libraries to link for osgSim (use this)
#
# OSGSIM_LIBRARY - The osgSim library
# OSGSIM_LIBRARY_DEBUG - The osgSim debug library
#
# $OSGDIR is an environment variable that would
# correspond to the ./configure --prefix=$OSGDIR
......@@ -25,46 +29,10 @@
# #include <osg/PositionAttitudeTransform>
# #include <osgSim/ImpostorSprite>
# Try the user's environment request before anything else.
FIND_PATH(OSGSIM_INCLUDE_DIR osgSim/ImpostorSprite
HINTS
$ENV{OSGSIM_DIR}
$ENV{OSG_DIR}
$ENV{OSGDIR}
PATH_SUFFIXES include
PATHS
~/Library/Frameworks
/Library/Frameworks