if {[catch {package require Tcl 8.0}]} return
global tcl_platform env
if {[string range $tcl_platform(os) 0 6] == "Windows"} {
    package ifneeded sdds 4.0 "set tmpPath \"\$env(PATH)\" ; set env(PATH) \"$dir;\$env(PATH)\" ; [list load [file join $dir tclSDDS.dll]] ; set env(PATH) \"\$tmpPath\""
} elseif {$tcl_platform(os) == "Linux"} {
    if {[file exists [file join $dir Linux/libtclSDDS.so]]} {
        package ifneeded sdds 4.0 "[list load [file join $dir Linux/libtclSDDS.so]]"
    } else {
        package ifneeded sdds 4.0 "[list load [file join $dir libtclSDDS.so]]"
    }
} elseif {$tcl_platform(os) == "Darwin"} {
    if {[file exists [file join $dir Darwin/libtclSDDS.dylib]]} {
        package ifneeded sdds 4.0 "[list load [file join $dir Darwin/libtclSDDS.dylib]]"
    } else {
        package ifneeded sdds 4.0 "[list load [file join $dir libtclSDDS.dylib]]"
    }
} else {
    package ifneeded sdds 4.0 "[list load [file join $dir libtclSDDS.so]]"
}
