pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: seg fault building npm



On 09/11/2018 12:00, Chavdar Ivanov wrote:
Any more ideas about this nodejs fault? Latest firefox builds now
require nodejs to be installed.

Does it need npm? nodejs itself seems to work okay at least for basic operation.
node panics in ecp_nistz256_points_mul, part of the built-in
dependence openssl. The used one is 1.1.0, whereas ours is 1.1.1, I
would presume patched appropriately and tested as part of the main
system (this is under -current as of a couple of days ago).

Sadly no idea as I've not had much chance to look. I'd agree that it is something to do with how nodejs interacts with the openssl code though.

I tried using yarn instead of npm and whilst yarn was able to install itself it blew up doing a https download albeit with a more detailed call. Gut instinct (but no actual evidence) suggests that something isn't being set up right when the interpreter transitions from javascript code to native code. Given how messed up the stack is in my original debug trace suggests it. The yarn failure actually had a full stack trace and was in SSL_write if i remember correctly.

I'm on 8-stable so the native openssl is 1.0.2k. There is a configure argument that tells it to use an external SSL (and it seemed to be happy with the system provided one at configure time). However nodejs then didn't compile as it tried to set up a pointer to a function declared as inline in an openssl header file (although i did think that was legal in C++).

I've got some free time today so I might see if I can come up with a simpler bit of code that can cause breakage.

Mike


Home | Main Index | Thread Index | Old Index