0026460: Implicit cast to TopoDS_Shape compilation error due to ambiguous conversion
[occt.git] / adm / genconfdeps.tcl
index 3470530..2263a29 100644 (file)
@@ -1,6 +1,6 @@
 #!/usr/bin/tclsh
 
-set ARCH "32"
+set ARCH "64"
 
 if { "$tcl_platform(platform)" == "unix" } {
   set SYS_PATH_SPLITTER ":"
@@ -39,6 +39,9 @@ set CSF_OPT_LIB64 [list]
 set CSF_OPT_BIN32 [list]
 set CSF_OPT_BIN64 [list]
 
+if { "$tcl_platform(pointerSize)" == "4" } {
+  set ARCH "32"
+}
 if { [info exists ::env(ARCH)] } {
   set ARCH "$::env(ARCH)"
 }
@@ -139,7 +142,8 @@ proc wokdep:SearchLib {theLib theBitness {theSearchPath ""}} {
     }
   }
 
-  if { "$::tcl_platform(platform)" == "linux" } {
+
+  if { "$::tcl_platform(os)" == "Linux" } {
     if { "$theBitness" == "64" } {
       set aPath "/usr/lib/x86_64-linux-gnu/lib${theLib}.so"
       if { [file exists "$aPath"] } {
@@ -312,15 +316,10 @@ proc wokdep:SearchFreeType {theErrInc theErrLib32 theErrLib64 theErrBin32 theErr
   set isFound "true"
   set aFtBuildPath [wokdep:SearchHeader "ft2build.h"]
 
-  # new layout of headers in Freetype 2.5.x
-  if { "$aFtBuildPath" == "" } {
-    set aFtBuildPath [wokdep:SearchHeader "freetype2/ft2build.h"]
-  }
-
   if { "$aFtBuildPath" == "" } {
     # TODO - use `freetype-config --cflags` instead
     set aSysFreeType "/usr/include/freetype2"
-    if { [file exists "$aSysFreeType/ftbuild.h"] } {
+    if { [file exists "$aSysFreeType/ft2build.h"] } {
       lappend ::CSF_OPT_INC "$aSysFreeType"
     } elseif { [file exists "$aSysFreeType/freetype2/ft2build.h"] } {
       lappend ::CSF_OPT_INC "$aSysFreeType/freetype2"
@@ -955,8 +954,9 @@ proc wokdep:SaveCustom {} {
     puts $aFile "#!/bin/bash"
     puts $aFile "# This environment file was generated by wok_depsgui.tcl script at [clock format [clock seconds] -format "%Y.%m.%d %H:%M"]"
 
-    #puts $aFile ""
-    #puts $aFile "export ARCH=$::ARCH"
+    puts $aFile ""
+    puts $aFile "export ARCH=$::ARCH"
+    puts $aFile "export SHORTCUT_HEADERS=$::SHORTCUT_HEADERS"
 
     puts $aFile ""
     puts $aFile "export PRODUCTS_PATH=\"$::PRODUCTS_PATH\""