mirror of
https://github.com/PixarAnimationStudios/OpenSubdiv
synced 2024-11-08 13:30:04 +00:00
fix the OSD version printout in top CMakeList (now based off the #define in opensubdiv/version.h)
This commit is contained in:
parent
368b8e3271
commit
0a0ff9f9e9
@ -59,6 +59,16 @@ project(OpenSubdiv)
|
||||
|
||||
cmake_minimum_required(VERSION 2.8)
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
# Obtain OpenSubdiv API version from version.h file
|
||||
if(EXISTS "${CMAKE_SOURCE_DIR}/opensubdiv/version.h")
|
||||
file(STRINGS "${CMAKE_SOURCE_DIR}/opensubdiv/version.h"
|
||||
OpenSubdiv_VERSION REGEX "^#define OPENSUBDIV_VERSION .*$")
|
||||
string(REPLACE "#define OPENSUBDIV_VERSION " "" OpenSubdiv_VERSION ${OpenSubdiv_VERSION})
|
||||
endif()
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
message(STATUS "Compiling ${CMAKE_PROJECT_NAME} version ${OpenSubdiv_VERSION}")
|
||||
message(STATUS "Using cmake version ${CMAKE_VERSION}")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user