Compiling Pale Moon on Fedora >= 30

Support and discussions for the x86/x64 Linux version of Pale Moon.

Moderators: trava90, satrow

bgstack15
Apollo supporter
Apollo supporter
Posts: 46
Joined: 2018-01-22, 23:04

Compiling Pale Moon on Fedora >= 30

Unread post by bgstack15 » 2019-03-27, 19:49

I am trying to build the officially endorsed Pale Moon release on Fedora (not official release, just officially endorsed). I am using a COPR.

For the past several releases, the build always fails on Fedora 30 and Fedora rawhide (rolling release, which gets frozen and becomes the next release). The application builds just fine on Fedora 29 and below, so it's not a code problem.

I think this is a compiler or defaults/config problem, and I could use the forum's help to figure out what exactly is going on.

For reference:
Fedora 29 i386 successful build log
Fedora 30 i386 failed build log

The part that fails, consistently, on Fedora 30 (and gcc9) is

Code: Select all

77:46.73 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCThrower.cpp:9,
77:46.73                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:2:
77:46.73 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/xpcprivate.h:2931:8: note: 'struct xpc::GlobalProperties' declared here
77:46.73  2931 | struct GlobalProperties {
77:46.73       |        ^~~~~~~~~~~~~~~~
77:55.57 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:38:
77:55.57 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp: In member function 'char* XPCWrappedNative::ToString(XPCWrappedNativeTearOff*) const':
77:55.57 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp:2221:41: error: '%s' directive argument is null [-Werror=format-overflow=]
77:55.57  2221 |                 name = JS_sprintf_append(name, fmt,
77:55.57       |                        ~~~~~~~~~~~~~~~~~^~~~~~~~~~~
77:55.58  2222 |                                          array[i]->GetNameString());
77:55.58       |                                          ~~~~~~~~~~~~~~~~~~~~~~~~~~
77:58.38 cc1plus: some warnings being treated as errors
77:58.80 
77:58.80 In the directory  /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src
77:58.80 The following command failed to execute properly:
77:58.81 /usr/bin/g++ -std=gnu++11 -o Unified_cpp_js_xpconnect_src1.o -c -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/stl_wrappers -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/system_wrappers -include /builddir/build/BUILD/UXP-PM28.4.1_Release/config/gcc_hidden.h -DNDEBUG=1 -DTRIMMED=1 -DOS_POSIX=1 -DOS_LINUX=1 -DSTATIC_EXPORTABLE_JS_API -DMOZ_HAS_MOZGLUE -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -I/builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/ipc/ipdl/_ipdlheaders -I/builddir/build/BUILD/UXP-PM28.4.1_Release/ipc/chromium/src -I/builddir/build/BUILD/UXP-PM28.4.1_Release/ipc/glue -I/builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/loader -I/builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/wrappers -I/builddir/build/BUILD/UXP-PM28.4.1_Release/caps -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/base -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/html -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/svg -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/workers -I/builddir/build/BUILD/UXP-PM28.4.1_Release/layout/base -I/builddir/build/BUILD/UXP-PM28.4.1_Release/layout/style -I/builddir/build/BUILD/UXP-PM28.4.1_Release/xpcom/reflect/xptinfo -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nspr -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nss -fPIC -DMOZILLA_CLIENT -include /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/mozilla-config.h -MD -MP -MF .deps/Unified_cpp_js_xpconnect_src1.o.pp -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 -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -msse2 -mfpmath=sse -pthread -pipe -g -O2 -fomit-frame-pointer -Wno-shadow -Werror=format /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp
77:58.81 gmake[5]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/rules.mk:895: Unified_cpp_js_xpconnect_src1.o] Error 1
77:58.81 gmake[4]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/recurse.mk:71: js/xpconnect/src/target] Error 2
77:58.81 gmake[4]: *** Waiting for unfinished jobs....
78:14.82 libdom_media_gmp.a.desc
78:14.97 gmake[3]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/recurse.mk:33: compile] Error 2
78:14.97 gmake[2]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/rules.mk:503: default] Error 2
78:14.97 gmake[1]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/client.mk:414: realbuild] Error 2
78:14.98 gmake: *** [client.mk:170: build] Error 2
78:15.01 356 compiler warnings present.
error: Bad exit status from /var/tmp/rpm-tmp.vWgZn4 (%build)
I experience pretty much the same error when trying to compile Waterfox on Fedora 30 as well, so either it's a Mozilla codebase and gcc9 thing, or I'm a little lost. Any ideas, people who are real devs?

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 23936
Joined: 2011-08-28, 17:27
Location: 58°2'16"N 14°58'31"E
Contact:

Re: Compiling Pale Moon on Fedora >= 30

Unread post by Moonchild » 2019-03-27, 19:51

gcc 9 is not supported at this time.

Also your build log is incomplete and misses the actual error it borks on. So it won't help.
City of Heroes public server: https://www.moonshard.org/ -- Vote for it on cohservers.com

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne
Image

bgstack15
Apollo supporter
Apollo supporter
Posts: 46
Joined: 2018-01-22, 23:04

Re: Compiling Pale Moon on Fedora >= 30

Unread post by bgstack15 » 2019-03-27, 20:35

When you said that the log looks incomplete, do you mean the linked log file, or just my snippet?

Thank you for the quick reply! Do you anticipate supporting gcc9 within the next 6 months? By the end of this calendar year, the only supported Fedora releases will include gcc9 by default and not gcc8.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 23936
Joined: 2011-08-28, 17:27
Location: 58°2'16"N 14°58'31"E
Contact:

Re: Compiling Pale Moon on Fedora >= 30

Unread post by Moonchild » 2019-03-27, 20:39

Your snippet seems incomplete.
I'm guessing your build log as a whole is many MBs large (and rather pointless to post in its entirety) so it would help most if you can actually post the part of the log that starts with the actual fatal error and go from there.

It may be enough anyway. But, the error doesn't make much sense to me.

Code: Select all

            for (uint16_t i = 0; i < count; i++) {
                const char* fmt = (i == 0) ?
                                    "(%s" : (i == count-1) ?
                                        ", %s)" : ", %s";
                name = JS_sprintf_append(name, fmt,
                                         array[i]->GetNameString());
            }
Apparently gcc9 doesn't like fmt being constructed on-the-fly as (%s[, %s][...], %s)?
City of Heroes public server: https://www.moonshard.org/ -- Vote for it on cohservers.com

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne
Image

bgstack15
Apollo supporter
Apollo supporter
Posts: 46
Joined: 2018-01-22, 23:04

Re: Compiling Pale Moon on Fedora >= 30

Unread post by bgstack15 » 2019-03-27, 20:52

Help me understand what you mean. So far what I understand is that the lines showing "cc1plus: some warnings being treated as errors" and "The following command failed to execute properly:" and its following line, are insufficient to help track this down. I guess I can show you every reference to the failed file, and all the closing remarks.

Code: Select all

77:41.45 libdom_worklet.a.desc
77:44.40 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsUtils.h:14,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupports.h:130,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsCycleCollectionTraversalCallback.h:12,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsCycleCollectionNoteChild.h:13,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsCycleCollectionParticipant.h:12,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/mozilla/CycleCollectedJSContext.h:19,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/xpcprivate.h:77,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCThrower.cpp:9,
77:44.40                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:2:
77:44.40 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCVariant.cpp: In member function 'virtual nsresult XPCVariant::QueryInterface(const nsIID&, void**)':
77:44.40 Warning: -Wmultistatement-macros in /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h: macro expands to multiple statements
77:44.40 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:820:5: warning: macro expands to multiple statements [-Wmultistatement-macros]
77:44.40   820 |     foundInterface = 0;                                                       \
77:44.40       |     ^~~~~~~~~~~~~~
77:44.41 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:884:49: note: in expansion of macro 'NS_IMPL_QUERY_TAIL_GUTS'
77:44.41   884 | #define NS_INTERFACE_MAP_END                    NS_IMPL_QUERY_TAIL_GUTS
77:44.41       |                                                 ^~~~~~~~~~~~~~~~~~~~~~~
77:44.41 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCVariant.cpp:26:1: note: in expansion of macro 'NS_INTERFACE_MAP_END'
77:44.41    26 | NS_INTERFACE_MAP_END
77:44.41       | ^~~~~~~~~~~~~~~~~~~~
77:44.41 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/xpcprivate.h:103,
77:44.41                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCThrower.cpp:9,
77:44.41                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:2:
77:44.41 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsIClassInfoImpl.h:138:5: note: some parts of macro expansion are not guarded by this 'else' clause
77:44.41   138 |   } else
77:44.41       |     ^~~~
77:44.41 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCVariant.cpp:25:3: note: in expansion of macro 'NS_IMPL_QUERY_CLASSINFO'
77:44.41    25 |   NS_IMPL_QUERY_CLASSINFO(XPCVariant)
77:44.41       |   ^~~~~~~~~~~~~~~~~~~~~~~
77:45.18 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsUtils.h:14,
77:45.18                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupports.h:130,
77:45.18                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsCycleCollectionTraversalCallback.h:12,
77:45.18                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsCycleCollectionNoteChild.h:13,
77:45.19                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsCycleCollectionParticipant.h:12,
77:45.19                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/mozilla/CycleCollectedJSContext.h:19,
77:45.19                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/xpcprivate.h:77,
77:45.19                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCThrower.cpp:9,
77:45.19                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:2:
77:45.19 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp: In member function 'virtual nsresult XPCWrappedNative::QueryInterface(const nsIID&, void**)':
77:45.19 Warning: -Wmultistatement-macros in /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h: macro expands to multiple statements
77:45.19 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:820:5: warning: macro expands to multiple statements [-Wmultistatement-macros]
77:45.19   820 |     foundInterface = 0;                                                       \
77:45.19       |     ^~~~~~~~~~~~~~
77:45.19 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:884:49: note: in expansion of macro 'NS_IMPL_QUERY_TAIL_GUTS'
77:45.19   884 | #define NS_INTERFACE_MAP_END                    NS_IMPL_QUERY_TAIL_GUTS
77:45.19       |                                                 ^~~~~~~~~~~~~~~~~~~~~~~
77:45.19 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp:817:1: note: in expansion of macro 'NS_INTERFACE_MAP_END'
77:45.19   817 | NS_INTERFACE_MAP_END
77:45.19       | ^~~~~~~~~~~~~~~~~~~~
77:45.19 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:812:3: note: some parts of macro expansion are not guarded by this 'else' clause
77:45.19   812 |   else
77:45.19       |   ^~~~
77:45.19 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:886:3: note: in expansion of macro 'NS_IMPL_QUERY_BODY_AMBIGUOUS'
77:45.19   886 |   NS_IMPL_QUERY_BODY_AMBIGUOUS(_interface, _implClass)
77:45.19       |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
77:45.19 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp:816:3: note: in expansion of macro 'NS_INTERFACE_MAP_ENTRY_AMBIGUOUS'
77:45.19   816 |   NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIXPConnectWrappedNative)
77:45.19       |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
77:45.80 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/nsScriptErrorWithStack.cpp: In member function 'virtual nsresult nsScriptErrorWithStack::QueryInterface(const nsIID&, void**)':
77:45.80 Warning: -Wmultistatement-macros in /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h: macro expands to multiple statements
77:45.80 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:820:5: warning: macro expands to multiple statements [-Wmultistatement-macros]
77:45.80   820 |     foundInterface = 0;                                                       \
77:45.80       |     ^~~~~~~~~~~~~~
77:45.80 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:884:49: note: in expansion of macro 'NS_IMPL_QUERY_TAIL_GUTS'
77:45.80   884 | #define NS_INTERFACE_MAP_END                    NS_IMPL_QUERY_TAIL_GUTS
77:45.80       |                                                 ^~~~~~~~~~~~~~~~~~~~~~~
77:45.80 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/nsScriptErrorWithStack.cpp:61:1: note: in expansion of macro 'NS_INTERFACE_MAP_END'
77:45.80    61 | NS_INTERFACE_MAP_END
77:45.80       | ^~~~~~~~~~~~~~~~~~~~
77:45.80 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:801:3: note: some parts of macro expansion are not guarded by this 'else' clause
77:45.80   801 |   else
77:45.80       |   ^~~~
77:45.80 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nsISupportsImpl.h:878:49: note: in expansion of macro 'NS_IMPL_QUERY_BODY'
77:45.80   878 | #define NS_INTERFACE_MAP_ENTRY(_interface)      NS_IMPL_QUERY_BODY(_interface)
77:45.80       |                                                 ^~~~~~~~~~~~~~~~~~
77:45.80 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/nsScriptErrorWithStack.cpp:60:3: note: in expansion of macro 'NS_INTERFACE_MAP_ENTRY'
77:45.80    60 |   NS_INTERFACE_MAP_ENTRY(nsIScriptError)
77:45.80       |   ^~~~~~~~~~~~~~~~~~~~~~
77:46.72 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/jspubtd.h:17,
77:46.73                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/jsapi.h:27,
77:46.73                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/mozilla/CycleCollectedJSContext.h:16,
77:46.73                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/xpcprivate.h:77,
77:46.73                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCThrower.cpp:9,
77:46.73                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:2:
77:46.73 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/mozilla/PodOperations.h: In instantiation of 'void mozilla::PodZero(T*) [with T = xpc::GlobalProperties]':
77:46.73 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/xpcprivate.h:2933:28:   required from here
77:46.73 Warning: -Wclass-memaccess in /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/mozilla/PodOperations.h: 'void* memset(void*, int, size_t)' clearing an object of non-trivial type 'struct xpc::GlobalProperties'; use assignment or value-initialization instead
77:46.73 /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/mozilla/PodOperations.h:32:9: warning: 'void* memset(void*, int, size_t)' clearing an object of non-trivial type 'struct xpc::GlobalProperties'; use assignment or value-initialization instead [-Wclass-memaccess]
77:46.73    32 |   memset(aT, 0, sizeof(T));
77:46.73       |   ~~~~~~^~~~~~~~~~~~~~~~~~
77:46.73 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCThrower.cpp:9,
77:46.73                  from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:2:
77:46.73 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/xpcprivate.h:2931:8: note: 'struct xpc::GlobalProperties' declared here
77:46.73  2931 | struct GlobalProperties {
77:46.73       |        ^~~~~~~~~~~~~~~~
77:55.57 In file included from /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp:38:
77:55.57 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp: In member function 'char* XPCWrappedNative::ToString(XPCWrappedNativeTearOff*) const':
77:55.57 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp:2221:41: error: '%s' directive argument is null [-Werror=format-overflow=]
77:55.57  2221 |                 name = JS_sprintf_append(name, fmt,
77:55.57       |                        ~~~~~~~~~~~~~~~~~^~~~~~~~~~~
77:55.58  2222 |                                          array[i]->GetNameString());
77:55.58       |                                          ~~~~~~~~~~~~~~~~~~~~~~~~~~
77:58.38 cc1plus: some warnings being treated as errors
77:58.80 
77:58.80 In the directory  /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src
77:58.80 The following command failed to execute properly:
77:58.81 /usr/bin/g++ -std=gnu++11 -o Unified_cpp_js_xpconnect_src1.o -c -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/stl_wrappers -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/system_wrappers -include /builddir/build/BUILD/UXP-PM28.4.1_Release/config/gcc_hidden.h -DNDEBUG=1 -DTRIMMED=1 -DOS_POSIX=1 -DOS_LINUX=1 -DSTATIC_EXPORTABLE_JS_API -DMOZ_HAS_MOZGLUE -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -I/builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/ipc/ipdl/_ipdlheaders -I/builddir/build/BUILD/UXP-PM28.4.1_Release/ipc/chromium/src -I/builddir/build/BUILD/UXP-PM28.4.1_Release/ipc/glue -I/builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/loader -I/builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/wrappers -I/builddir/build/BUILD/UXP-PM28.4.1_Release/caps -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/base -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/html -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/svg -I/builddir/build/BUILD/UXP-PM28.4.1_Release/dom/workers -I/builddir/build/BUILD/UXP-PM28.4.1_Release/layout/base -I/builddir/build/BUILD/UXP-PM28.4.1_Release/layout/style -I/builddir/build/BUILD/UXP-PM28.4.1_Release/xpcom/reflect/xptinfo -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nspr -I/builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/dist/include/nss -fPIC -DMOZILLA_CLIENT -include /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/mozilla-config.h -MD -MP -MF .deps/Unified_cpp_js_xpconnect_src1.o.pp -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 -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -msse2 -mfpmath=sse -pthread -pipe -g -O2 -fomit-frame-pointer -Wno-shadow -Werror=format /builddir/build/BUILD/UXP-PM28.4.1_Release/pmbuild/js/xpconnect/src/Unified_cpp_js_xpconnect_src1.cpp
77:58.81 gmake[5]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/rules.mk:895: Unified_cpp_js_xpconnect_src1.o] Error 1
77:58.81 gmake[4]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/recurse.mk:71: js/xpconnect/src/target] Error 2
77:58.81 gmake[4]: *** Waiting for unfinished jobs....
78:14.82 libdom_media_gmp.a.desc
78:14.97 gmake[3]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/recurse.mk:33: compile] Error 2
78:14.97 gmake[2]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/config/rules.mk:503: default] Error 2
78:14.97 gmake[1]: *** [/builddir/build/BUILD/UXP-PM28.4.1_Release/client.mk:414: realbuild] Error 2
78:14.98 gmake: *** [client.mk:170: build] Error 2
78:15.01 356 compiler warnings present.
78:15.23 Notification center failed: Install the python dbus module to get a notification when the build finishes.
error: Bad exit status from /var/tmp/rpm-tmp.vWgZn4 (%build)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.vWgZn4 (%build)
INFO: chroot_scan: 3 files copied to /var/lib/copr-rpmbuild/results/chroot_scan
INFO: /var/lib/mock/874429-fedora-30-i386-1553700549.339046/root/var/log/dnf.log
/var/lib/mock/874429-fedora-30-i386-1553700549.339046/root/var/log/dnf.librepo.log
/var/lib/mock/874429-fedora-30-i386-1553700549.339046/root/var/log/dnf.rpm.log
ERROR: Exception(/var/lib/copr-rpmbuild/results/palemoon-28.4.1-1.src.rpm) Config(874429-fedora-30-i386) 80 minutes 9 seconds
INFO: Results and/or logs in: /var/lib/copr-rpmbuild/results
INFO: Cleaning up build root ('cleanup_on_failure=True')
Start: clean chroot
INFO: unmounting tmpfs.
Finish: clean chroot
ERROR: Command failed: 
 # /usr/bin/systemd-nspawn -q -M e7bd5f0f1ce44cd0bc919d9dfce20e98 -D /var/lib/mock/874429-fedora-30-i386-1553700549.339046/root -a --capability=cap_ipc_lock --bind=/tmp/mock-resolv.gysgmui2:/etc/resolv.conf --setenv=TERM=vt100 --setenv=SHELL=/bin/bash --setenv=HOME=/builddir --setenv=HOSTNAME=mock --setenv=PATH=/usr/bin:/bin:/usr/sbin:/sbin --setenv=PROMPT_COMMAND=printf "\033]0;<mock-chroot>\007" --setenv=PS1=<mock-chroot> \s-\v\$  --setenv=LANG=en_US.UTF-8 -u mockbuild bash --login -c /usr/bin/rpmbuild -bb --target i686 --nodeps /builddir/build/SPECS/palemoon.spec


Traceback (most recent call last):
  File "/usr/bin/copr-rpmbuild", line 158, in main
    action(args, config)
  File "/usr/bin/copr-rpmbuild", line 295, in build_rpm
    builder.run()
  File "/usr/lib/python3.6/site-packages/copr_rpmbuild/builders/mock.py", line 40, in run
    self.produce_rpm(srpm, configdir, self.resultdir)
  File "/usr/lib/python3.6/site-packages/copr_rpmbuild/builders/mock.py", line 124, in produce_rpm
    raise RuntimeError("Build failed")
RuntimeError: Build failed
I realize that if you want to stop at this point because it was using gcc9, I understand. I would greatly appreciate it though, if you could continue helping me understand compiling more.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 23936
Joined: 2011-08-28, 17:27
Location: 58°2'16"N 14°58'31"E
Contact:

Re: Compiling Pale Moon on Fedora >= 30

Unread post by Moonchild » 2019-03-27, 21:26

The error is:

Code: Select all

77:55.57 /builddir/build/BUILD/UXP-PM28.4.1_Release/js/xpconnect/src/XPCWrappedNative.cpp:2221:41: error: '%s' directive argument is null [-Werror=format-overflow=]
Which makes no sense to me.
The code I quoted is what throws the error during compilation in gcc9 but I see nothing wrong with it. It's a nested ternary creating a format string which is then passed to another function. Sothere is no error there and the compiler shouldn't even be trying to evaluate what the value of %s is.
City of Heroes public server: https://www.moonshard.org/ -- Vote for it on cohservers.com

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne
Image

Walter Dnes
Astronaut
Astronaut
Posts: 604
Joined: 2015-07-30, 20:29
Location: Vaughan, ON, Canada

Re: Compiling Pale Moon on Fedora >= 30

Unread post by Walter Dnes » 2019-03-27, 22:12

From your log...

Code: Select all

 0:04.62 checking the target C compiler version... 9.0.1
 0:04.63 checking the target C compiler works... yes
 0:04.63 checking for the target C++ compiler... /usr/bin/g++
 0:04.67 checking whether the target C++ compiler can be used... yes
 0:04.67 checking the target C++ compiler version... 9.0.1
Note the references to "9.0.1". According to https://gcc.gnu.org/ the GCC 9.0 branch is "under development"; English translanslation... it's beta code. This fits in with a "bleeding edge" Fedora. I believe that Pale Moon supports up to the GCC 8 branch.

Another, tangential item. You've got...

Code: Select all

 0:04.18   --enable-optimize=-O2
I recommend...

Code: Select all

 0:04.18   --enable-optimize=-O2 -msse2 -mfpmath=sse
According to https://gcc.gnu.org/onlinedocs/gcc-8.3. ... 86-Options
-mfpmath=unit

Generate floating-point arithmetic for selected unit unit. The choices for unit are:

‘387’

Use the standard 387 floating-point coprocessor present on the majority of chips and emulated otherwise. Code compiled with this option runs almost everywhere. The temporary results are computed in 80-bit precision instead of the precision specified by the type, resulting in slightly different results compared to most of other chips. See -ffloat-store for more detailed description.

This is the default choice for non-Darwin x86-32 targets.
You appear to be building a 32-bit Pale Moon. The default would be to use the slower 387 instructions, unless there is some code in Pale Moon source over-riding that.
There's a right way
There's a wrong way
And then there's my way

bgstack15
Apollo supporter
Apollo supporter
Posts: 46
Joined: 2018-01-22, 23:04

Re: Compiling Pale Moon on Fedora >= 30

Unread post by bgstack15 » 2019-03-27, 22:22

Haha, I realize Fedora seems bleeding edge, but I guess I would call it "leading edge." It seems to lag behind OpenSUSE (based on other projects' work and linked libc items) and definitely behind Arch. So while Fedora likes to forge ahead in some areas, it is actually a regular release type. Fedora rawhide is rolling release, and Pale Moon (and Waterfox) has failed to build in rawhide for a few months. I was hoping it was a gcc thing they would fix in Fedora, but apparently not, because Fedora 30 (which now that I checked, is still in a dev state and not release state) is now separate from rawhide in the copr settings.

I shared here the i386 builds from the copr. I do have x86_64 builds, and I can link them here for you if you wish:
Fedora 29 x86_64 builder-live.log
Fedora 30 x86_64 builder-live.log

Thanks for the good info! I will adjust the rpm spec to include the changed settings for 32-bit builds.

User avatar
New Tobin Paradigm
Off-Topic Sheriff
Off-Topic Sheriff
Posts: 5577
Joined: 2012-10-09, 19:37
Location: Sector 001

Re: Compiling Pale Moon on Fedora >= 30

Unread post by New Tobin Paradigm » 2019-03-28, 07:03

BTW as a point.. You're gonna have to compile Pale Moon with GTK3 on Fedora 29+ because Redhat has busted GTK2 pretty badly. So go ahead and do that. Two, I dunno about the errors you are posting but if you can get copr to stick to gcc 7 it might be a better bet for the time being as gcc8 is still experimental in UXP and gcc 9 hasn't even been considered yet.

Also, clobber once in a while and just drop 32bit. Seriously, Fedora is too leading edge to be dealing with x86 anymore.

And NEVER listen to Dnes on anything you want to have official branding on. I cannot stress this enough dude.
Image
- So then, "mono" means one, and "rail" means rail! -
And that concludes our intensive three-week course.
http://binaryoutcast.com/ | http://thereisonlyxul.org/

bgstack15
Apollo supporter
Apollo supporter
Posts: 46
Joined: 2018-01-22, 23:04

Re: Compiling Pale Moon on Fedora >= 30

Unread post by bgstack15 » 2019-03-28, 13:11

Thanks, @New Tobin Paradigm. I had already started to consider my options for an older gcc on Fedora 30. I didn't realize gcc8 was still experimental for compiling this application. I have had adequate success with it so far. The Developer Wiki page just states "GCC version 4.9 or higher."

Help me understand: "Clobber once in a while." If you refer to clobbering the build contents when rebuilding, then that is a non-issue here. The copr spins up worker nodes (probably systemd-containerd whatever-have-you) that are fresh for each build. If that's not what you mean, please elaborate so I can do better!

Regarding 32-bit: Fedora still supports x86 as an alternative architecture, and provides it as an option for the worker nodes for the copr. I understand that dropping x86 is happening to a lot of projects, and I can give it up if I have to, but so far I haven't had any issues with Pale Moon and i386. The compiling problem that occurs for which I started the thread happens in x86_64 architecture also, and I just happened to link to the 32-bit build logs for reference here.
Also, does your warning mean that I should not add Walter Dnes's compile flags to my officially-endorsed 32-bit builds, or that it just is not a good idea? I fully expect your particular style of response but for some reason the previous way you stated it was not explicit about the statements in question. Assuming that Dnes is not an official spokesperson of the project, he can't be wrong 100% of the time.

About GTK3: I have very limited understanding of the gtk2 vs gtk3 debacle. I code some python to gtk3 (I have a strange fascination for StatusIcon which was "deprecated" with no replacement) but don't really have a problem with gtk2. Here's what I have come up with to compile against gtk3. Please tell me if this is how I would do it:

Code: Select all

# in the mozconfig
ac_add_options --enable-default-toolkit=cairo-gtk3

User avatar
trava90
Contributing developer
Contributing developer
Posts: 1559
Joined: 2013-05-20, 18:19
Location: Earth
Contact:

Re: Compiling Pale Moon on Fedora >= 30

Unread post by trava90 » 2019-03-28, 13:27

bgstack15 wrote:Do you anticipate supporting gcc9 within the next 6 months?
Eventually yes. Within 6 months? Maybe. Regardless no work will be done on supporting gcc9 until it gets its first stable release (e.g. GCC 9.1).
bgstack15 wrote:Also, does your warning mean that I should not add Walter Dnes's compile flags to my officially-endorsed 32-bit builds
That is exactly what is meant. Please do not alter any of the compiler flags/mozconfig options on officially endorsed builds unless those alterations come from myself. With the mozconfig I previously provided you the build system handles all the other options and compiler flags that are needed depending on OS and architecture.

User avatar
New Tobin Paradigm
Off-Topic Sheriff
Off-Topic Sheriff
Posts: 5577
Joined: 2012-10-09, 19:37
Location: Sector 001

Re: Compiling Pale Moon on Fedora >= 30

Unread post by New Tobin Paradigm » 2019-03-28, 13:35

Regardless, do switch to gtk3 for stability reasons for Fedora 29+ because they have really screwed up with gtk2 and may never fix it.

Unless Travis or Moonchild disapproves the gtk version for 3rd party system packages should at this point be considered a system specific target configuration point and be set to what ever version is predominate on that target system.

Of course most users would prefer gtk2 but that is gonna become harder to keep around in targeted system packages if the distro fails to keep it around or busts it badly like in Fedora.

Do note before some people that get huffy this is for targeted system packages and not the generic binary and does not mean gtk2 support will ever be nixed on our side. BUT the point of targeted system packages should be to build and configure to run the best on that specific system within the official build guidelines.

I don't want to disagree with Travis cause it ain't no such power play or anything but I also am a contact when it comes to build config. Just I am the pita one ;)
Last edited by New Tobin Paradigm on 2019-03-28, 13:51, edited 3 times in total.
Image
- So then, "mono" means one, and "rail" means rail! -
And that concludes our intensive three-week course.
http://binaryoutcast.com/ | http://thereisonlyxul.org/

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 23936
Joined: 2011-08-28, 17:27
Location: 58°2'16"N 14°58'31"E
Contact:

Re: Compiling Pale Moon on Fedora >= 30

Unread post by Moonchild » 2019-03-28, 13:41

New Tobin Paradigm wrote:for Fedora 29+ because they have really screwed up with gtk2 and may never fix it.
Strike "may" and replace with "will", I think.
City of Heroes public server: https://www.moonshard.org/ -- Vote for it on cohservers.com

"If you want to build a better world for yourself, you have to be willing to build one for everybody." -- Coyote Osborne
Image

User avatar
New Tobin Paradigm
Off-Topic Sheriff
Off-Topic Sheriff
Posts: 5577
Joined: 2012-10-09, 19:37
Location: Sector 001

Re: Compiling Pale Moon on Fedora >= 30

Unread post by New Tobin Paradigm » 2019-03-28, 13:57

AS FOR x86 I didn't realize that Fedora still offered direct and primary 32bit support still.. If that is the case then yeah do keep on cause I may be mistaken in that they were dropping it. That was the news I had heard last.

GCC8 though if that works then use it if not fall back to 7 as it is well supported and tested on our end. 9 will have to wait for it to not be a buggy prerelease first as Travis says.

The wiki may say 4.9+ but really it is 4.9, <5.3 old abi, >5.3 new abi, gcc6 is buggy, and gcc7 is well supported now with gcc8 being somewhere between experimental and supported but seems to work in most cases.

4.9 and 7.x is the best supported out of the list though.
Last edited by New Tobin Paradigm on 2019-03-28, 14:06, edited 1 time in total.
Image
- So then, "mono" means one, and "rail" means rail! -
And that concludes our intensive three-week course.
http://binaryoutcast.com/ | http://thereisonlyxul.org/

bgstack15
Apollo supporter
Apollo supporter
Posts: 46
Joined: 2018-01-22, 23:04

Re: Compiling Pale Moon on Fedora >= 30

Unread post by bgstack15 » 2019-03-28, 14:05

Well, I was surprised to learn when researching for this thread, that x86 is only an alternative architecture for the Fedora project. It went from primary arch to alternative, for Fedora 26 in 2017 July.

When I get more time, I will investigate gcc7 on all releases. It sounds kind of backwards to use an older compiler on the newer releases of Fedora, but it is still a valid use case nonetheless and somebody somewhere else must be doing it too.

User avatar
New Tobin Paradigm
Off-Topic Sheriff
Off-Topic Sheriff
Posts: 5577
Joined: 2012-10-09, 19:37
Location: Sector 001

Re: Compiling Pale Moon on Fedora >= 30

Unread post by New Tobin Paradigm » 2019-03-28, 14:10

The reason 8 is considered half supported is because there just haven't been enough cases to fully sign off on it. It will comple it has been accounted for with updates and changes and seems ok but it lacks practical and longer term testing 4.9 or 7.x and to a lesser extent 5.x has with UXP.

Feel free to lead the charge on gcc8 but do be absolutely sure it is stable and ye have a fallback position with 7.

That is why there is the RedHat devtoolsets anyway. Also, watch out for python2 going away in Fedora in the future as well.. That will happen at some point.

As for Dnes, it's better if you pat him on the head and walk away and ask one of us instead. Will save time and effort in the long run.
Image
- So then, "mono" means one, and "rail" means rail! -
And that concludes our intensive three-week course.
http://binaryoutcast.com/ | http://thereisonlyxul.org/

vannilla
Astronaut
Astronaut
Posts: 522
Joined: 2018-05-05, 13:29

Re: Compiling Pale Moon on Fedora >= 30

Unread post by vannilla » 2019-03-28, 21:16

Off-topic:
For what is worth, I've been compiling Pale Moon with GCC 8 and I haven't seen any noticeable difference. But of course it's nothing definitive, just sharing my experience.
As for GTK 2, it's officially unmantained, and if a distro really decides to drop Python 2, then we can assume it's going to also drop GTK 2 at some point in time. Of course it can be many years from now, but it's really a matter of when, rather than if.

User avatar
stevepusser
Lunatic
Lunatic
Posts: 498
Joined: 2015-08-01, 18:33
Location: California

Re: Compiling Pale Moon on Fedora >= 30

Unread post by stevepusser » 2019-03-28, 23:34

Since Pale Moon automatically uses multithreaded builds, your actual build error may be further up in the log. I find if you open it in a good text editor (or used a good terminal app) you can search from the bottom for "Error" (case sensitive) and find it pretty quickly.

If Fedora 30 still has an older gcc available, you can set that in the environment so that the build will use those.

bgstack15
Apollo supporter
Apollo supporter
Posts: 46
Joined: 2018-01-22, 23:04

Re: Compiling Pale Moon on Fedora >= 30

Unread post by bgstack15 » 2019-04-30, 15:14

Gcc 9 is still not "released" yet, but here's the notation about the changes for -Wformat-overflow: https://gcc.gnu.org/gcc-9/changes.html#c-family.

User avatar
gmturner
New to the forum
New to the forum
Posts: 1
Joined: 2019-05-08, 18:36

Re: Compiling Pale Moon on Fedora >= 30

Unread post by gmturner » 2019-05-08, 19:51

In gcc-9.1.0 release, this is still happening. It does indeed seem to be a bug in gcc 9's __attribute__ ((format)) sanity checks. Or else something in this code must confuse an optimizer, somehow causing GIGO in the __attribute__((format)) checking.

For a work-around, the following patch, which AFAICT should really, really be a noop, allows compilation to succeed:

Code: Select all

diff -urpN palemoon-28.5.0.orig/js/xpconnect/src/XPCWrappedNative.cpp palemoon-28.5.0/js/xpconnect/src/XPCWrappedNative.cpp
--- palemoon-28.5.0.orig/js/xpconnect/src/XPCWrappedNative.cpp	2019-05-08 12:15:54.907966322 -0700
+++ palemoon-28.5.0/js/xpconnect/src/XPCWrappedNative.cpp	2019-05-08 12:16:49.654748316 -0700
@@ -2215,10 +2215,9 @@ XPCWrappedNative::ToString(XPCWrappedNat
             name = JS_sprintf_append(name, "%s", array[1]->GetNameString());
         } else {
             for (uint16_t i = 0; i < count; i++) {
-                const char* fmt = (i == 0) ?
-                                    "(%s" : (i == count-1) ?
-                                        ", %s)" : ", %s";
-                name = JS_sprintf_append(name, fmt,
+                name = JS_sprintf_append(name, (i == 0) ?
+                                         "(%s" : (i == count-1) ?
+                                         ", %s)" : ", %s",
                                          array[i]->GetNameString());
             }
         }

Post Reply