File: FindInchi.cmake

package info (click to toggle)
rdkit 201403-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 62,288 kB
  • ctags: 15,156
  • sloc: cpp: 125,376; python: 55,674; java: 4,831; ansic: 4,178; xml: 2,499; sql: 1,775; yacc: 1,551; lex: 1,051; makefile: 353; fortran: 183; sh: 148; cs: 93
file content (27 lines) | stat: -rw-r--r-- 1,063 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# - Try to find Inchi lib
# Once done this will define
#
#  INCHI_FOUND - system has inchi lib
#  INCHI_INCLUDE_DIR - the inchi include directory
#  INCHI_LIBRARIES - the inchi library

# Taken from the open babel distribution
#  https://openbabel.svn.sourceforge.net/svnroot/openbabel/openbabel/trunk/cmake/modules/FindInchi.cmake
# Copyright (c) 2010 Marcus D. Hanwell, <marcus@cryos.org>
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.

if(INCHI_INCLUDE_DIR AND INCHI_LIBRARY)
  # in cache already
  set(INCHI_FOUND TRUE)
else()
  find_path(INCHI_INCLUDE_DIR NAMES inchi_api.h PATHS /usr/include/inchi )
  find_library(INCHI_LIBRARY NAMES inchi Inchi)
  include(FindPackageHandleStandardArgs)
  find_package_handle_standard_args(INCHI
	  "Could NOT find InChI in system locations" INCHI_LIBRARY
	  INCHI_INCLUDE_DIR)
  set(INCHI_INCLUDE_DIRS ${INCHI_INCLUDE_DIR} )
  set(INCHI_LIBRARIES ${INCHI_LIBRARY} )
  mark_as_advanced(INCHI_INCLUDE_DIR INCHI_LIBRARY)
endif()