]> OCCT Git - occt.git/commitdiff
Draw - Update DrawDefault script to handle missing directory cases #542
authorPasukhin Dmitry <dpasukhi@opencascade.com>
Sat, 17 May 2025 12:00:50 +0000 (13:00 +0100)
committerGitHub <noreply@github.com>
Sat, 17 May 2025 12:00:50 +0000 (13:00 +0100)
Fixed "Warning: could not find DRAW directory"

resources/DrawResources/DrawDefault

index 71b121a5476e9d4fd994f34aec1cc8a402f4bff7..8f2a4b89c142cd60b6d3375e088571b0dc37d5a4 100755 (executable)
@@ -28,6 +28,9 @@ if { [info exists env(DRAWHOME) ] } {
 } else {
   if { [info exists env(CASROOT) ] } {
     set dir [file join $env(CASROOT) src DrawResources]
+    if { ! [file isdirectory $dir] } {
+      set dir [file join $env(CASROOT) resources DrawResources]
+    }
   } else {
     puts "Warning: CASROOT is not defined, some features may not load correctly"
     set dir [file dirname [info script]]