replit/prybar

prybar-tcl references libc 2.33 which is not compatible with tcltls which depends on libc >= 2.34

Opened this issue · 1 comments

I'm trying to run a tcl file like the following:

package require http 2
package require tls 1.7
http::register https 443 [list ::tls::socket -autoservername true]
set resp [http::geturl "http://worldtimeapi.org/api/timezone/Pacific/Honolulu"]
set body [set ${resp}(body)]
puts "$body"

Given an environment with the tcltls package installed as with the following replit.nix file:

{ pkgs }: {
    deps = [
        pkgs.tcl
        pkgs.tcltls
    ];
}

When I run this with prybar-tcl I get the following error:

error: couldn't load file "/nix/store/a1q9flmxzkvaz53caly6iamgw13fwqy6-tcltls-1.7.22/lib/tcltls1.7.22/tcltls.so": /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libc.so.6: version `GLIBC_2.34' not found (required by /nix/store/4mxnw95jcm5a27qk60z7yc0gvxp42b9a-openssl-3.0.7/lib/libcrypto.so.3)

However, if I run it with tclsh it works fine. This seems to be do to a glibc version mismatch between prybar-tcl and tcltls

# ldd "$(which prybar-tcl)"
    linux-vdso.so.1 (0x00007ffcab26f000)
    libtcl8.6.so => /nix/store/r1ap0ykibs74irs0rg6jsvbqn5s39l9z-tcl-8.6.11/lib/libtcl8.6.so (0x00007fb479204000)
    libpthread.so.0 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libpthread.so.0 (0x00007fb4791e4000)
    libc.so.6 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libc.so.6 (0x00007fb47901f000)
    libdl.so.2 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libdl.so.2 (0x00007fb47901a000)
    libm.so.6 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libm.so.6 (0x00007fb478ed7000)
    /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/ld-linux-x86-64.so.2 => /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib64/ld-linux-x86-64.so.2 (0x00007fb4793d6000)

vs.

# ldd tcltls.so
 linux-vdso.so.1 (0x00007fffdb718000)
    libssl.so.1.1 => /nix/store/fzb7khbic8vpcr3m69v6y8qp6jqspdgw-openssl-1.1.1s/lib/libssl.so.1.1 (0x00007f7ab74b1000)
    libcrypto.so.1.1 => /nix/store/fzb7khbic8vpcr3m69v6y8qp6jqspdgw-openssl-1.1.1s/lib/libcrypto.so.1.1 (0x00007f7ab71bf000)
    libc.so.6 => /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib/libc.so.6 (0x00007f7ab6fb6000)
    libdl.so.2 => /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib/libdl.so.2 (0x00007f7ab6fb1000)
    libpthread.so.0 => /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib/libpthread.so.0 (0x00007f7ab6faa000)
    /nix/store/4nlgxhb09sdr51nc9hdm8az5b08vzkgx-glibc-2.35-163/lib64/ld-linux-x86-64.so.2 (0x00007f7ab7559000)