}
# fetch environment variables (e.g. set by custom.sh or custom.bat) and set them as tcl variables with the same name
-set THE_ENV_VARIABLES {HAVE_FREEIMAGE HAVE_FFMPEG HAVE_TBB HAVE_GLES2 HAVE_D3D HAVE_VTK HAVE_GL2PS HAVE_ZLIB HAVE_LIBLZMA HAVE_OPENCL CHECK_QT4 CHECK_JDK MACOSX_USE_GLX}
+set THE_ENV_VARIABLES {HAVE_FREEIMAGE HAVE_FFMPEG HAVE_TBB HAVE_GLES2 HAVE_D3D HAVE_VTK HAVE_GL2PS HAVE_ZLIB HAVE_LIBLZMA HAVE_OPENCL CHECK_QT4 CHECK_JDK MACOSX_USE_GLX HAVE_RelWithDebInfo}
foreach anEnvIter $THE_ENV_VARIABLES {
set ${anEnvIter} "false"
if { [info exists ::env(${anEnvIter})] } {
set HAVE_GLES2 ""
} else {
set MACOSX_USE_GLX ""
- if { "$tcl_platform(platform)" != "windows" } {
- set HAVE_D3D ""
- }
+}
+if { "$tcl_platform(platform)" != "windows" } {
+ set HAVE_D3D ""
+ set HAVE_RelWithDebInfo ""
}
foreach anEnvIter {ARCH VCVER VCVARS PRODUCTS_PATH} {
if { [info exists ::env(${anEnvIter})] } {
if { [file exists "$aPath"] } {
return "$aPath"
}
+
+ if { "$::tcl_platform(os)" == "Linux" } {
+ if { "$::ARCH" == "64" } {
+ set aPath "/usr/include/x86_64-linux-gnu/${theHeader}"
+ if { [file exists "$aPath"] } {
+ return "$aPath"
+ }
+ } else {
+ set aPath "/usr/include/i386-linux-gnu/${theHeader}"
+ if { [file exists "$aPath"] } {
+ return "$aPath"
+ }
+ }
+ }
+
return ""
}
return ""
}
+ # keep only two first digits in "vc141"
+ if { ! [regexp {^vc[0-9][0-9]} $theCmpl aCmpl] } {
+ set aCmpl $theCmpl
+ }
+
set aShortList {}
foreach aPath $theList {
- if { [string first "$theCmpl" "$aPath"] != "-1" } {
+ if { [string first "$aCmpl" "$aPath"] != "-1" } {
lappend aShortList "$aPath"
}
}
upvar $theErrBin32 anErrBin32
upvar $theErrBin64 anErrBin64
+ # keep only two first digits in "vc141"
+ if { ! [regexp {^vc[0-9][0-9]} ${::VCVER} aVcLib] } {
+ set aVcLib ${::VCVER}
+ }
+
set isFound "true"
set aTbbHPath [wokdep:SearchHeader "tbb/scalable_allocator.h"]
if { "$aTbbHPath" == "" } {
set aTbbLibPath [wokdep:SearchLib "tbb" "$anArchIter"]
if { "$aTbbLibPath" == "" } {
- set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{tbb}*] "$::VCVER" "$anArchIter" ]
- set aTbbLibPath [wokdep:SearchLib "tbb" "$anArchIter" "$aPath/lib/$aSubDir/${::VCVER}"]
+ set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{tbb}*] $aVcLib "$anArchIter" ]
+ set aTbbLibPath [wokdep:SearchLib "tbb" "$anArchIter" "$aPath/lib/$aSubDir/$aVcLib"]
if { "$aTbbLibPath" == "" } {
# Set the path to the TBB library for Linux
if { "$::tcl_platform(platform)" != "windows" } {
lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib/$aSubDir"
}
} else {
- lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib/$aSubDir/${::VCVER}"
+ lappend ::CSF_OPT_LIB$anArchIter "$aPath/lib/$aSubDir/$aVcLib"
}
if { "$aTbbLibPath" == "" } {
lappend anErrLib$anArchIter "Error: '${::SYS_LIB_PREFIX}tbb.${::SYS_LIB_SUFFIX}' not found (Intel TBB)"
if { "$::tcl_platform(platform)" == "windows" } {
set aTbbDllPath [wokdep:SearchBin "tbb.dll" "$anArchIter"]
if { "$aTbbDllPath" == "" } {
- set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{tbb}*] "$::VCVER" "$anArchIter" ]
- set aTbbDllPath [wokdep:SearchBin "tbb.dll" "$anArchIter" "$aPath/bin/$aSubDir/${::VCVER}"]
+ set aPath [wokdep:Preferred [glob -nocomplain -directory "$::PRODUCTS_PATH" -type d *{tbb}*] $aVcLib "$anArchIter" ]
+ set aTbbDllPath [wokdep:SearchBin "tbb.dll" "$anArchIter" "$aPath/bin/$aSubDir/$aVcLib"]
if { "$aTbbDllPath" != "" } {
- lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin/$aSubDir/${::VCVER}"
+ lappend ::CSF_OPT_BIN$anArchIter "$aPath/bin/$aSubDir/$aVcLib"
} else {
lappend anErrBin$anArchIter "Error: 'tbb.dll' not found (Intel TBB)"
if { "$::ARCH" == "$anArchIter"} { set isFound "false" }