summaryrefslogtreecommitdiffstats
path: root/Modules/FindOpenGL.cmake
diff options
context:
space:
mode:
authorKitware Robot <kwrobot@kitware.com>2012-08-13 17:50:14 (GMT)
committerBrad King <brad.king@kitware.com>2012-08-13 18:19:16 (GMT)
commit9db3116226cb99fcf54e936c833953abcde9b729 (patch)
treebd755ed9e616bbf1482a894bc7946980d81b7703 /Modules/FindOpenGL.cmake
parent77543bde41b0e52c3959016698b529835945d62d (diff)
downloadCMake-9db3116226cb99fcf54e936c833953abcde9b729.zip
CMake-9db3116226cb99fcf54e936c833953abcde9b729.tar.gz
CMake-9db3116226cb99fcf54e936c833953abcde9b729.tar.bz2
Remove CMake-language block-end command arguments
Ancient versions of CMake required else(), endif(), and similar block termination commands to have arguments matching the command starting the block. This is no longer the preferred style. Run the following shell code: for c in else endif endforeach endfunction endmacro endwhile; do echo 's/\b'"$c"'\(\s*\)(.\+)/'"$c"'\1()/' done >convert.sed && git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' | egrep -z -v '^(Utilities/cm|Source/kwsys/)' | egrep -z -v 'Tests/CMakeTests/While-Endwhile-' | xargs -0 sed -i -f convert.sed && rm convert.sed
Diffstat (limited to 'Modules/FindOpenGL.cmake')
-rw-r--r--Modules/FindOpenGL.cmake38
1 files changed, 19 insertions, 19 deletions
diff --git a/Modules/FindOpenGL.cmake b/Modules/FindOpenGL.cmake
index 1565011..a6f4503 100644
--- a/Modules/FindOpenGL.cmake
+++ b/Modules/FindOpenGL.cmake
@@ -37,19 +37,19 @@ if (WIN32)
find_library(OPENGL_glu_LIBRARY glu32 )
- else (CYGWIN)
+ else ()
if(BORLAND)
set (OPENGL_gl_LIBRARY import32 CACHE STRING "OpenGL library for win32")
set (OPENGL_glu_LIBRARY import32 CACHE STRING "GLU library for win32")
- else(BORLAND)
+ else()
set (OPENGL_gl_LIBRARY opengl32 CACHE STRING "OpenGL library for win32")
set (OPENGL_glu_LIBRARY glu32 CACHE STRING "GLU library for win32")
- endif(BORLAND)
+ endif()
- endif (CYGWIN)
+ endif ()
-else (WIN32)
+else ()
if (APPLE)
@@ -57,16 +57,16 @@ else (WIN32)
find_library(OPENGL_glu_LIBRARY AGL DOC "AGL lib for OSX")
find_path(OPENGL_INCLUDE_DIR OpenGL/gl.h DOC "Include for OpenGL on OSX")
- else(APPLE)
+ else()
# Handle HP-UX cases where we only want to find OpenGL in either hpux64
# or hpux32 depending on if we're doing a 64 bit build.
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
set(HPUX_IA_OPENGL_LIB_PATH /opt/graphics/OpenGL/lib/hpux32/)
- else(CMAKE_SIZEOF_VOID_P EQUAL 4)
+ else()
set(HPUX_IA_OPENGL_LIB_PATH
/opt/graphics/OpenGL/lib/hpux64/
/opt/graphics/OpenGL/lib/pa20_64)
- endif(CMAKE_SIZEOF_VOID_P EQUAL 4)
+ endif()
# The first line below is to make sure that the proper headers
# are used on a Linux machine with the NVidia drivers installed.
@@ -104,13 +104,13 @@ else (WIN32)
if (OPENGL_gl_LIBRARY)
if(NOT X11_FOUND)
include(FindX11)
- endif(NOT X11_FOUND)
+ endif()
if (X11_FOUND)
if (NOT APPLE)
set (OPENGL_LIBRARIES ${X11_LIBRARIES})
- endif (NOT APPLE)
- endif (X11_FOUND)
- endif (OPENGL_gl_LIBRARY)
+ endif ()
+ endif ()
+ endif ()
find_library(OPENGL_glu_LIBRARY
NAMES GLU MesaGLU
@@ -120,29 +120,29 @@ else (WIN32)
/usr/shlib /usr/X11R6/lib
)
- endif(APPLE)
-endif (WIN32)
+ endif()
+endif ()
if(OPENGL_gl_LIBRARY)
if(OPENGL_xmesa_INCLUDE_DIR)
set( OPENGL_XMESA_FOUND "YES" )
- else(OPENGL_xmesa_INCLUDE_DIR)
+ else()
set( OPENGL_XMESA_FOUND "NO" )
- endif(OPENGL_xmesa_INCLUDE_DIR)
+ endif()
set( OPENGL_LIBRARIES ${OPENGL_gl_LIBRARY} ${OPENGL_LIBRARIES})
if(OPENGL_glu_LIBRARY)
set( OPENGL_GLU_FOUND "YES" )
set( OPENGL_LIBRARIES ${OPENGL_glu_LIBRARY} ${OPENGL_LIBRARIES} )
- else(OPENGL_glu_LIBRARY)
+ else()
set( OPENGL_GLU_FOUND "NO" )
- endif(OPENGL_glu_LIBRARY)
+ endif()
# This deprecated setting is for backward compatibility with CMake1.4
set (OPENGL_LIBRARY ${OPENGL_LIBRARIES})
-endif(OPENGL_gl_LIBRARY)
+endif()
# This deprecated setting is for backward compatibility with CMake1.4
set(OPENGL_INCLUDE_PATH ${OPENGL_INCLUDE_DIR})