Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

run-tim error: deno: /lib/aarch64-linux-gnu/libm.so.6: version `GLIBC_2.35' not found (required by deno) #23775

Closed
bkerin opened this issue May 11, 2024 · 2 comments · Fixed by #23791

Comments

@bkerin
Copy link

bkerin commented May 11, 2024

Version: Deno 1.43.3

I'm totally new to deno and tbh also sort of new to post-perl web so sorry if this is too obvious but on my slightly old Raspberry Pi I just got this:

# deno run -A main.ts 
deno: /lib/aarch64-linux-gnu/libm.so.6: version `GLIBC_2.35' not found (required by deno)

I had just installed with the presumably standard incantation from the home page (curl -fsSL https://deno.land/install.sh | sh) which worked without complaint.

The Pi is not too old:

# cat /proc/version
Linux version 6.1.21-v8+ (dom@buildbot) (aarch64-linux-gnu-gcc-8 (Ubuntu/Linaro 8.4.0-3ubuntu1) 8.4.0, GNU ld (GNU Binutils for Ubuntu) 2.34) #1642 SMP PREEMPT Mon Apr  3 17:24:16 BST 2023

I have a large crufty accumulation of environment settings in ~/.bashrc and I haven't tried to isolate away from them yet. But I don't know of any that should be making a difference and on a newer Pi this doesn't happen:

# cat /proc/version
Linux version 6.6.20+rpt-rpi-v8 (debian-kernel@lists.debian.org) (gcc-12 (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40) #1 SMP PREEMPT Debian 1:6.6.20-1+rpt1 (2024-03-07)
# deno run -A main.ts
error: Uncaught (in promise) ReferenceError: add is not defined
  console.log("Add 2 + 3 =", add(2, 3));
          ^
    at file:///root/main.ts:3:11
@komondor
Copy link

komondor commented May 13, 2024

Hi,

It looks like the binary was compiled with GLIBC 2.35, which is available in Debian 12 but not in Debian 11 , which uses GLIBC 2.31. This can cause compatibility issues.

I have the same issue using Debian 11 and Deno latest version. I cannot upgrade to Debian 12 now.

Try installing a previous version. This one works for me

curl -fsSL https://deno.land/x/install/install.sh | sh -s v1.42.4

@bkerin
Copy link
Author

bkerin commented May 14, 2024

Ok so just not in the target for latest version, thanks.

I tried "dist-upgrade" but for some reason it stayed on same kernel and apparently same version of glibc, because the problem persisted.

Is this something that the install recipe at the top of the web page could check for? It would be nice to have it detected then rather than at run-time, and would look less like a bug. autoconf can do it afterall :)

mmastrac added a commit that referenced this issue May 15, 2024
…uild (#23791)

Fixes the sysroot to make it more reliable on aarch64. The sysroot we
download as part of the build process now includes a small script to set
up the linker flags required to build in that sysroot.

Fixes #23775 

Before:

```
matt@raspberrypi:~ $ ~/.deno/bin/deno 
/home/matt/.deno/bin/deno: /lib/aarch64-linux-gnu/libm.so.6: version `GLIBC_2.35' not found (required by /home/matt/.deno/bin/deno)
```

After:

```
matt@raspberrypi:/tmp $ ./deno
Deno 1.43.3
exit using ctrl+d, ctrl+c, or close()
REPL is running with all permissions allowed.
To specify permissions, run `deno repl` with allow flags.
```
bartlomieju pushed a commit that referenced this issue May 16, 2024
…uild (#23791)

Fixes the sysroot to make it more reliable on aarch64. The sysroot we
download as part of the build process now includes a small script to set
up the linker flags required to build in that sysroot.

Fixes #23775 

Before:

```
matt@raspberrypi:~ $ ~/.deno/bin/deno 
/home/matt/.deno/bin/deno: /lib/aarch64-linux-gnu/libm.so.6: version `GLIBC_2.35' not found (required by /home/matt/.deno/bin/deno)
```

After:

```
matt@raspberrypi:/tmp $ ./deno
Deno 1.43.3
exit using ctrl+d, ctrl+c, or close()
REPL is running with all permissions allowed.
To specify permissions, run `deno repl` with allow flags.
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants