Salome HOME
Split PyConsole in order to be used easily outside GUI of SALOME.
[modules/gui.git] / adm_local / cmake_files / FindSalomeOpenGL.cmake
index 49028bdb730d637db9267c97e3ffa03b332ac8e7..1e5a751a5b3f81931cae94971cd4107ca49b1e87 100644 (file)
@@ -1,9 +1,9 @@
-# Copyright (C) 2013  CEA/DEN, EDF R&D, OPEN CASCADE
+# Copyright (C) 2013-2015  CEA/DEN, EDF R&D, OPEN CASCADE
 #
 # This library is free software; you can redistribute it and/or
 # modify it under the terms of the GNU Lesser General Public
 # License as published by the Free Software Foundation; either
-# version 2.1 of the License.
+# version 2.1 of the License, or (at your option) any later version.
 #
 # This library is distributed in the hope that it will be useful,
 # but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -19,7 +19,7 @@
 # Author: Adrien Bruneton
 #
 
-# OpenGL detection dor Salome
+# OpenGL detection for Salome
 #
 #  !! Please read the generic detection procedure in SalomeMacros.cmake !!
 #
@@ -31,5 +31,8 @@ ENDIF()
 SALOME_FIND_PACKAGE_AND_DETECT_CONFLICTS(OpenGL OPENGL_INCLUDE_DIR 1)
 #MARK_AS_ADVANCED()
 
-SALOME_ACCUMULATE_HEADERS(OPENGL_INCLUDE_DIR)
+IF(OPENGL_FOUND) 
+  SALOME_ACCUMULATE_HEADERS(OPENGL_INCLUDE_DIR)
+  SALOME_ACCUMULATE_ENVIRONMENT(LD_LIBRARY_PATH ${OPENGL_LIBRARIES})
+ENDIF()