From: inv Date: Thu, 23 Dec 2010 10:27:58 +0000 (+0000) Subject: OCC22124 Necessety to obtain current version of OCCT in different automatic scripts X-Git-Tag: V6_7_1~118 X-Git-Url: http://git.dev.opencascade.org/gitweb/?a=commitdiff_plain;h=eeec666cef6036b8f524109b985a0dfeed3fbeed;p=occt-wok.git OCC22124 Necessety to obtain current version of OCCT in different automatic scripts --- diff --git a/src/WOKTclLib/OCCTGetVersion.tcl b/src/WOKTclLib/OCCTGetVersion.tcl index ededb46..bf8021b 100755 --- a/src/WOKTclLib/OCCTGetVersion.tcl +++ b/src/WOKTclLib/OCCTGetVersion.tcl @@ -5,7 +5,6 @@ proc OCCTGetVersion {} { if {$OCCTVersionFile != "" && [file readable $OCCTVersionFile]} { set v_major "" set v_minor "" - set v_patch "" set v_build "" set vfd [open $OCCTVersionFile {RDONLY}] while {[gets $vfd line] >= 0} { @@ -13,18 +12,12 @@ proc OCCTGetVersion {} { set v_major $num } elseif {[regexp {^[ \t]*\#define[ \t]*OCC_VERSION_MINOR[ \t]*([0-9]+)} $line str num]} { set v_minor $num - } elseif {[regexp {^[ \t]*\#define[ \t]*OCC_VERSION_MAINTENANCE[ \t]*([0-9]+)} $line str num]} { - set v_patch $num } elseif {[regexp {^[ \t]*\#define[ \t]*OCC_VERSION_BUILD[ \t]*([0-9]+)} $line str num]} { set v_build $num } } close $vfd - if {$v_build != 0 && $v_build != ""} { - set OCCTVersion $v_major.$v_minor.$v_patch.$v_build - } else { - set OCCTVersion $v_major.$v_minor.$v_patch - } + set OCCTVersion $v_major.$v_minor.$v_build } return $OCCTVersion }