rmottola / Arctic-Fox

Web Browser for Mac OS X 10.6+, Linux (PowerPC, x86, amd64, ARM, MIPS), NetBSD, OpenBSD, and Windows XP.
Other
311 stars 36 forks source link

Crash on OpenBSD -current (7.2) #115

Closed vl-ms closed 1 year ago

vl-ms commented 2 years ago

Hello. The browser built succesfully with the following .mozconfig.

# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

export CC="clang"
export CXX="clang++"
export LDFLAGS="-Wl,-zwxneeded"
export TAR=gtar

mk_add_options MOZ_MAKE_FLAGS="-s -j1"

ac_add_options --disable-crashreporter
ac_add_options --disable-tests
ac_add_options --disable-debug
ac_add_options --disable-updater
ac_add_options --disable-mozril-geoloc
ac_add_options --disable-webrtc
ac_add_options --disable-safe-browsing
ac_add_options --disable-parental-controls
ac_add_options --enable-release
ac_add_options --disable-necko-wifi
ac_add_options --disable-eme
ac_add_options --disable-gamepad
ac_add_options --disable-dbus
ac_add_options --disable-gio
ac_add_options --disable-pulseaudio
ac_add_options --enable-strip
ac_add_options --enable-install-strip
ac_add_options --enable-application=browser
ac_add_options --with-branding=browser/branding/arcticfox
ac_add_options --enable-optimize="-g0 -O0 -march=native"

but it crashes with the following message:

$ ./mach run                                                                                                                                                                                                 
 0:00.37 /home/unix/soft/Arctic-Fox/obj-amd64-unknown-openbsd7.2/dist/bin/arcticfox -no-remote -profile /home/unix/soft/Arctic-Fox/obj-amd64-unknown-openbsd7.2/tmp/scratch_user                                     
out of memory                                                                                                                                                                                                        
Assertion failure: [unhandlable oom] OOM in createJitRuntime, at /home/unix/soft/Arctic-Fox/js/src/jscntxt.cpp:1221

As was suggested in build tips, I set the optimization level to O0, but it doesn't help. I have 12 GBs of RAM and 4 cores/8 threads (though OpenBSD disables hyperthreading). Maybe, there is a kernel memory limit that I should increase?

rmottola commented 1 year ago

I am have ArcticFox running on OpenBSD 7.0 and 7.1. On 7.1 amd64 with I need to keep the Optimization level at 01 or lower, or the build is unstable (but starts). I think this is due to certain optimizations that need to be disabled for gcc 6 or later and that I found no way to disable on clang.

I think you are hitting memory protection on your system, "-Wl,-zwxneeded". Do you have wxallowed for the filesystem you are trying to run AF from?

vl-ms commented 1 year ago

indeed, I added wxallowed to fstab and now the browser just works. Thank you!