proot
proot copied to clipboard
Segmentation Fault with npm init and npm install, inside Proot-Distro
Device: Samsung Galaxy NT-7000 (year 2011) OS: Android Nougat 7.1 (custom ROM modded LineageOS) Architecture : armv7-a (cortex A9), 32 bit
Hi, good developers of Termux! Love termux so much!
Problem description
The problem is exactly like the title. However, nodejs and npm is working inside termux. It's not working in Proot-distro Ubuntu, Debian, and Alpine. It's also not working with distributions from Andronix. Here's when I run npm init
inside Proot-distro ubuntu.
verbose.txt
Steps to reproduce
The following is after and before pkg update && pkg upgrade
enter proot with proot-distro login ubuntu
then inside an empty folder I run npm init -ddd
(-ddd for verbose npm command), results in:
npminit-ddd.txt
Expected behavior
nodejs and npm working inside Proot. Including npm install
and node index
. Need proot because we can only run browser there.
Additional information
Application version:
0.118.0
Packages CPU architecture:
arm
Subscribed repositories:
# sources.list
deb https://packages-cf.termux.org/apt/termux-main/ stable main
# x11-repo (sources.list.d/x11.list)
deb https://packages-cf.termux.org/apt/termux-x11 x11 main
Updatable packages:
All packages up to date
Android version:
7.1.2
Kernel build information:
Linux localhost 3.0.31-Bauner-ged871643 #1 SMP PREEMPT Fri Aug 24 14:21:31 CEST 2018 armv7l Android
Device manufacturer:
samsung
Device model:
GT-N7000
As I read, Samsung NT-7000 has armv-7a architecture. It's indeed very old (with CPU arm cortex A-9, same as iPad 2)... However, I already tested npm and node in MiPad 1 (also armv-7a), Galaxy Note 4 2014 (also 32 bit), and of course all new devices (arm64) worked flawlessly. Thanks for that. I can run selenium, puppeteer, whatsapp-web.js, etc So, I'm guessing the devs can do it too :) It will be awesome if we can make use of a very old device like this.
I looked up and read that it's probably caused by LOADER_ADDRESS 0x10000000, but then I saw it's been fixed [on January 5th.]. But I'm just an enthusiast and I don't understand anything about it.
Oh, and I read about the NEON SIMD in termux wiki, not being supported. But I also I looked up about this device, it supports NEON SIMD. Article: here and here
Unfortunately I couldn't get device to reproduce this on, so I can only provide generic advice to try:
- Update packages inside guest (
pacman -Syu
, Arch doesn't support mixed old/new packages) - Start distro through
PROOT_NO_SECCOMP=1 proot-distro login --isolated --no-sysvipc --no-link2symlink archlinux
(Each option is separate but I don't know which one might be good here)