Pale Moon on OpenBSD

Talk about code development, features, specific bugzilla bugs, enhancements, patches, and other highly technical things.
Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific referenced Bugzilla bugs, mercurial, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Most "bug reports" do not belong in this board and should initially be posted in Community Support or other relevant support boards.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
Post Reply
hunghung
Banned user
Banned user
Posts: 24
Joined: 2020-07-19, 17:45

Pale Moon on OpenBSD

Post by hunghung » 2020-07-24, 15:40

I know posting this I'm risking of losing my account, but, I just post my experience. Building software is one of my hobby, and I enjoyed it. PM is the first software I tried to build with my new OpenBSD system.

This is the .mozconfig I used:

Code: Select all

ac_add_options --enable-application=palemoon
ac_add_options --enable-optimize="-O2 -w"
ac_add_options --enable-default-toolkit=cairo-gtk3
ac_add_options --disable-jemalloc
ac_add_options --enable-strip
ac_add_options --enable-devtools
ac_add_options --disable-eme
ac_add_options --disable-webrtc
ac_add_options --disable-gamepad
ac_add_options --disable-tests
ac_add_options --disable-debug
ac_add_options --disable-necko-wifi
ac_add_options --disable-updater
ac_add_options --with-pthreads

# Please see https://www.palemoon.org/redist.shtml for restrictions when using the official branding.
ac_add_options --disable-official-branding
export MOZILLA_OFFICIAL=0

mk_add_options MOZ_MAKE_FLAGS="-j4"
Don't know why jemalloc is not supported on OpenBSD. I installed all of the dependencies of PM and gcc/g++ 8.3 from OpenBSD's binary packages.

I used this command to build PM: CC="egcc" CXX="eg++" ./mach build

The compilation is straight forward even though I can't complete it. The error is there:

Code: Select all

28:31.11 
28:31.11 cc1plus: out of memory allocating 93600 bytes after a total of 0 bytes
28:31.78 libmozsqlite3.so.1.0
28:31.86 
28:31.86 In the directory  /usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dom/bindings
28:31.86 The following command failed to execute properly:
28:31.86 /usr/local/bin/eg++ -std=gnu++11 -o UnifiedBindings19.o -c -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dist/stl_wrappers -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dist/system_wrappers -include /usr/local/palemoon/platform/config/gcc_hidden.h -DNDEBUG=1 -DTRIMMED=1 -DOS_POSIX=1 -DOS_BSD=1 -DOS_OPENBSD=1 -DHAVE_SIDEBAR -DSTATIC_EXPORTABLE_JS_API -DMOZ_HAS_MOZGLUE -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -I/usr/local/palemoon/platform/dom/bindings -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dom/bindings -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dist/include/mozilla/dom -I/usr/local/palemoon/platform/dom/base -I/usr/local/palemoon/platform/dom/battery -I/usr/local/palemoon/platform/dom/canvas -I/usr/local/palemoon/platform/dom/geolocation -I/usr/local/palemoon/platform/dom/html -I/usr/local/palemoon/platform/dom/indexedDB -I/usr/local/palemoon/platform/dom/media/webaudio -I/usr/local/palemoon/platform/dom/svg -I/usr/local/palemoon/platform/dom/workers -I/usr/local/palemoon/platform/dom/xbl -I/usr/local/palemoon/platform/dom/xml -I/usr/local/palemoon/platform/dom/xslt/base -I/usr/local/palemoon/platform/dom/xslt/xpath -I/usr/local/palemoon/platform/dom/xul -I/usr/local/palemoon/platform/js/xpconnect/src -I/usr/local/palemoon/platform/js/xpconnect/wrappers -I/usr/local/palemoon/platform/layout/generic -I/usr/local/palemoon/platform/layout/style -I/usr/local/palemoon/platform/layout/xul/tree -I/usr/local/palemoon/platform/media/mtransport -I/usr/local/palemoon/platform/media/webrtc -I/usr/local/palemoon/platform/media/webrtc/signaling/src/common/time_profiling -I/usr/local/palemoon/platform/media/webrtc/signaling/src/peerconnection -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/ipc/ipdl/_ipdlheaders -I/usr/local/palemoon/platform/ipc/chromium/src -I/usr/local/palemoon/platform/ipc/glue -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dist/include -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dist/include/nspr -I/usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dist/include/nss -fPIC -DMOZILLA_CLIENT -include /usr/local/palemoon/obj-amd64-unknown-openbsd6.7/mozilla-config.h -MD -MP -MF .deps/UnifiedBindings19.o.pp -I/usr/X11R6/include -Wall -Wc++11-compat -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpointer-arith -Wsign-compare -Wtype-limits -Wunreachable-code -Wwrite-strings -Wno-invalid-offsetof -Wc++14-compat -Wc++1z-compat -Wimplicit-fallthrough -Wno-error=maybe-uninitialized -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=multistatement-macros -flifetime-dse=1 -fno-exceptions -fno-strict-aliasing -fno-rtti -fno-exceptions -fno-math-errno -msse2 -mfpmath=sse -pthread -pipe -g -O2 -w -fomit-frame-pointer -Wno-error=shadow /usr/local/palemoon/obj-amd64-unknown-openbsd6.7/dom/bindings/UnifiedBindings19.cpp
28:31.86 gmake[5]: *** [/usr/local/palemoon/platform/config/rules.mk:886: UnifiedBindings19.o] Error 1
28:31.86 gmake[5]: *** Waiting for unfinished jobs....
28:35.62 libxpfe_components_directory.a.desc
28:37.50 libxpcom_reflect_xptcall_md_unix.a.desc
28:39.08 libdom_abort.a.desc
28:44.40 libparser_xml.a.desc
28:46.94 gmake[4]: *** [/usr/local/palemoon/platform/config/recurse.mk:71: dom/bindings/target] Error 2
28:46.94 gmake[4]: *** Waiting for unfinished jobs....
28:50.60 libdom_quota.a.desc
28:55.39 libxpcom_base.a.desc
28:55.61 gmake[3]: *** [/usr/local/palemoon/platform/config/recurse.mk:33: compile] Error 2
28:55.61 gmake[2]: *** [/usr/local/palemoon/platform/config/rules.mk:494: default] Error 2
28:55.61 gmake[1]: *** [/usr/local/palemoon/client.mk:406: realbuild] Error 2
28:55.61 gmake: *** [client.mk:164: build] Error 2
28:55.62 0 compiler warnings present.
It seemed I don't have enough memory to build PM. I have 8G and it's still not enough. I surprised that with this 8G of RAM I could build PM just fine on Linux but failed on OpenBSD, a system people said more lightweight than Linux.

If I could build PM on OpenBSD, I'm willing to provide my build as a third party build of PM.

User avatar
Admin
Site Admin
Site Admin
Posts: 320
Joined: 2012-05-17, 19:06

Re: Pale Moon on OpenBSD

Post by Admin » 2020-07-24, 16:11

Try reducing your parallel build processes (-j4). It will take memory per build thread. Try -j2 or -j1
Did you know that moral outrage triggers the pleasure centers of the brain? It's unlikely you can actually get addicted to outrage, but there is plausible evidence that you can become strongly predisposed to it.
Source: https://www.bbc.co.uk/programmes/p002w557/episodes/downloads - "The cooperative species" and "Behaving better online"

hunghung
Banned user
Banned user
Posts: 24
Joined: 2020-07-19, 17:45

Re: Pale Moon on OpenBSD

Post by hunghung » 2020-07-24, 17:16

Admin wrote:
2020-07-24, 16:11
Try reducing your parallel build processes (-j4). It will take memory per build thread. Try -j2 or -j1
I will try and report when I'm done.

User avatar
New Tobin Paradigm
Knows the dark side
Knows the dark side
Posts: 7861
Joined: 2012-10-09, 19:37
Location: Space, maybe..

Re: Pale Moon on OpenBSD

Post by New Tobin Paradigm » 2020-07-24, 17:51

As I told you in your SunOS thread.. Building yourself entitles you to no support including support building the codebase. I would suggest you stop now, you obviously do not possess the knowledge, talent, nor the system power to do it successfully.
Image
- Mars will never be free until the sands run red with Earther blood! -

Image

hunghung
Banned user
Banned user
Posts: 24
Joined: 2020-07-19, 17:45

Re: Pale Moon on OpenBSD

Post by hunghung » 2020-07-25, 12:04

Admin wrote:
2020-07-24, 16:11
Try reducing your parallel build processes (-j4). It will take memory per build thread. Try -j2 or -j1
Hi Admin. I tried with -j2 and it still failed with the same error. It seemed the problem is with the source file's encoding, not because of lacking of memory on my system. Check it here:

https://stackoverflow.com/questions/291 ... 0800-bytes

BTW, clang could compile the whole thing successfully but the final binary failed to run. As I know, almost all of the BSDs switched to clang for a while now. Only NetBSD left using GCC but I think they are going to migrate to Clang in the future, too. PM currently only supports build with clang on MacOS, so I would better give up now, sometime in the future if PM devs add the supports for building with clang on non-MacOS systems, I could try again.

hunghung
Banned user
Banned user
Posts: 24
Joined: 2020-07-19, 17:45

Re: Pale Moon on OpenBSD

Post by hunghung » 2020-07-25, 12:06

New Tobin Paradigm wrote:
2020-07-24, 17:51
As I told you in your SunOS thread.. Building yourself entitles you to no support including support building the codebase. I would suggest you stop now, you obviously do not possess the knowledge, talent, nor the system power to do it successfully.
I didn't see your post. Sorry :)

Post Reply