2012-02-18 00:45:49 +08:00
|
|
|
# Locate libgta
|
|
|
|
# This module defines
|
|
|
|
# GTA_FOUND, if false, do not try to link to libgta
|
|
|
|
# GTA_INCLUDE_DIRS, where to find the headers
|
|
|
|
# GTA_LIBRARIES
|
|
|
|
#
|
|
|
|
# $GTA_DIR is an environment variable that would
|
|
|
|
# correspond to the ./configure --prefix=$GTA_DIR
|
|
|
|
# used in building libgta.
|
|
|
|
|
|
|
|
INCLUDE(FindPkgConfig OPTIONAL)
|
|
|
|
|
|
|
|
IF(PKG_CONFIG_FOUND)
|
|
|
|
|
|
|
|
INCLUDE(FindPkgConfig)
|
|
|
|
|
|
|
|
PKG_CHECK_MODULES(GTA gta)
|
|
|
|
|
|
|
|
ENDIF(PKG_CONFIG_FOUND)
|
2017-02-24 23:09:13 +08:00
|
|
|
|
|
|
|
IF(NOT GTA_FOUND)
|
|
|
|
FIND_PATH(GTA_INCLUDE_DIRS gta/gta.hpp
|
|
|
|
$ENV{GTA_DIR}/include
|
|
|
|
$ENV{GTA_DIR}
|
|
|
|
~/Library/Frameworks
|
|
|
|
/Library/Frameworks
|
|
|
|
/usr/local/include
|
|
|
|
/usr/include
|
|
|
|
/sw/include # Fink
|
|
|
|
/opt/local/include # DarwinPorts
|
|
|
|
/opt/csw/include # Blastwave
|
|
|
|
/opt/include
|
|
|
|
/usr/freeware/include
|
|
|
|
)
|
|
|
|
|
2018-10-10 07:06:28 +08:00
|
|
|
FIND_LIBRARY(GTA_LIBRARIES
|
2017-02-24 23:09:13 +08:00
|
|
|
NAMES gta libgta
|
|
|
|
PATHS
|
|
|
|
$ENV{GTA_DIR}/lib
|
|
|
|
$ENV{GTA_DIR}
|
|
|
|
~/Library/Frameworks
|
|
|
|
/Library/Frameworks
|
|
|
|
/usr/local/lib
|
|
|
|
/usr/lib
|
|
|
|
/sw/lib
|
|
|
|
/opt/local/lib
|
|
|
|
/opt/csw/lib
|
|
|
|
/opt/lib
|
|
|
|
/usr/freeware/lib64
|
|
|
|
)
|
|
|
|
|
|
|
|
SET(GTA_FOUND "NO")
|
2018-10-10 07:06:28 +08:00
|
|
|
IF(GTA_LIBRARIES AND GTA_INCLUDE_DIRS)
|
2017-02-24 23:09:13 +08:00
|
|
|
SET(GTA_FOUND "YES")
|
2018-10-10 07:06:28 +08:00
|
|
|
ENDIF(GTA_LIBRARIES AND GTA_INCLUDE_DIRS)
|
2017-02-24 23:09:13 +08:00
|
|
|
|
|
|
|
ENDIF(NOT GTA_FOUND)
|