Build instuctions? Topic is solved

Board for discussions around the Basilisk web browser.

Moderator: Basilisk-Dev

wapsi

Build instuctions?

Unread post by wapsi » 2021-03-19, 11:46

Is there somewhere build instructions for Basilisk like there is one for PaleMoon: https://developer.palemoon.org/build/linux/ ?

I tried to follow the PaleMoon's build instructions on Linux but I got an error:

Code: Select all

# ./mach build
 0:00.46 /usr/bin/gmake -f client.mk -s configure
 0:01.51 cd /root/basilisk/20210319_2/obj-x86_64-pc-linux-gnu
 0:01.51 /root/basilisk/20210319_2/configure
 0:01.67 Reexecuting in the virtualenv
 0:01.90 ERROR: Cannot find project application/xulrunner
 0:01.93 *** Fix above errors and then restart with\
 0:01.93                "/usr/bin/gmake -f client.mk build"
 0:01.93 gmake: *** [client.mk:370: configure] Error 1
And I'm wondering if there are some preparations that must be done differently than with PaleMoon (which builds just fine on this same machine).

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35475
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Build instuctions?

Unread post by Moonchild » 2021-03-19, 11:59

You need to make sure to have a proper mozconfig that indicates the application to build.

e.g. for Linux:

Code: Select all

mk_add_options AUTOCLOBBER=1
mk_add_options MOZ_MAKE_FLAGS="-j8"
mk_add_options MOZ_OBJDIR=../obj-bas-x64-release

# Clear this if not a 64bit build
_BUILD_64=1

# Set GTK Version to 2 or 3
_GTK_VERSION=3

# Standard build options for Basilisk
ac_add_options --enable-application=basilisk  <-- ** this line **
ac_add_options --enable-optimize="-O2 -w -msse2 -mfpmath=sse"
ac_add_options --enable-default-toolkit=cairo-gtk$_GTK_VERSION
ac_add_options --enable-jemalloc
ac_add_options --enable-strip
# ac_add_options --enable-updater
ac_add_options --enable-av1
ac_add_options --enable-eme
ac_add_options --enable-webrtc
ac_add_options --enable-gamepad
ac_add_options --disable-tests
ac_add_options --disable-debug

ac_add_options --with-pthreads

#  official branding.
# ac_add_options --enable-official-branding
# ac_add_options --enable-update-channel=release
# ac_add_options --enable-official-vendor
# export MOZILLA_OFFICIAL=1

# Processor architecure specific build options
if [ -n "$_BUILD_64" ]; then
  ac_add_options --x-libraries=/usr/lib64
else
  ac_add_options --x-libraries=/usr/lib
fi

# Set up the basilisk extension app version
export BASILISK_VERSION=1

# Disable telemetry reporting
export MOZ_TELEMETRY_REPORTING= 
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

wapsi

Re: Build instuctions?

Unread post by wapsi » 2021-03-20, 10:34

Thanks! Now I the compilation succeeded.

BTW: Do you have any idea why I get weird JavaScript related error(s) with my own compiled PaleMoon or Basilisk but if I use the official builds I don't get those? For example one site I'm trying to access is working with the official builds but with my custom build I get the following JS error in the Console (the whole page load will fail):

Code: Select all

[Index] Script load error detected:  %7B%7D  
	window.handleCompiledJSError
Perhaps there are some JavaSript engine parameters or something similar I should set for the compilation? Are you able to provide the mozconfig you're using with the official builds?

Another example, the login form of https://mail.office365.com/ does not load with my custom build but loads just fine with the official build. Here is the error from my custom build:

Code: Select all

Error: Unable to process binding "template: function(){return { nodes:[$data],data:$parent} }"
Message: Unable to process binding "pageViewComponent: function(){return { name:'login-paginated-username-view',params:{
                        serverData:svr,serverError:initialError,isInitialView:isInitialState,displayName:sharedData.displayName,otherIdpRedirectUrl:sharedData.otherIdpRedirectUrl,prefillNames:$loginPage.prefillNames,flowToken:sharedData.flowToken,availableSignupCreds:sharedData.availableSignupCreds},event:{
                        redirect:$loginPage.view_onRedirect,setPendingRequest:$loginPage.view_onSetPendingRequest,registerDialog:$loginPage.view_onRegisterDialog,unregisterDialog:$loginPage.view_onUnregisterDialog,showDialog:$loginPage.view_onShowDialog,updateAvailableCredsWithoutUsername:$loginPage.view_onUpdateAvailableCreds,agreementClick:$loginPage.footer_agreementClick}} }"
Message: Unable to process binding "ifnot: function(){return prefillNames().length > 1 }"
Message: Unable to process binding "component: function(){return { name:'placeholder-textbox-field',publicMethods:usernameTextbox.placeholderTextboxMethods,params:{
                serverData:svr,hintText:tenantBranding.UserIdLabel || str['CT_PWD_STR_Email_Example'],hintCss:'placeholder'+(!svr.fAllowPhoneSignIn ?' ltr_override':'')},event:{
                updateFocus:usernameTextbox.textbox_onUpdateFocus}} }"
Message: Unable to process binding "withProperties: function(){return {'$placeholderText':placeholderText} }"
Message: Unable to process binding "template: function(){return { nodes:$componentTemplateNodes,data:$parent} }"
Message: Unable to process binding "textInput: function(){return usernameTextbox.value }"
Message: Browser doesn't support addEventListener or attachEvent  
ConvergedLogin_PCore_4rDcu3CeBBnX_W5sFR0hMw2.js:18:4976
Strict-Transport-Security: The site specified a header that could not be parsed successfully.[Learn More] 
prefetch.aspx
Use of attributes’ nodeValue attribute is deprecated. Use value instead.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35475
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Build instuctions?

Unread post by Moonchild » 2021-03-20, 18:04

wapsi wrote:
2021-03-20, 10:34
Are you able to provide the mozconfig you're using with the official builds?
What do you think I dropped in?... :)
I commented out the official branding bits and reduced the number of parallel compile tasks to 8 (since I gather you wouldn't have as many cores at your disposal as the build machine) but otherwise it is the build config used for release versions.

As for your errors... Since you're on Linux there's a lot of potential variables like gcc version, linker, specific OS, and also how much RAM you have (e.g. if the compile needs swapping, then it may cause weird errors like this) and if your number of compilation tasks is OK for your hardware or not.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

New Tobin Paradigm

Re: Build instuctions?

Unread post by New Tobin Paradigm » 2021-03-20, 19:02

Let me remind you the bits about being on your own when it comes to compiling the code applies to Basilisk as well.

wapsi

Re: Build instuctions?

Unread post by wapsi » 2021-03-22, 15:04

New Tobin Paradigm wrote:
2021-03-20, 19:02
Let me remind you the bits about being on your own when it comes to compiling the code applies to Basilisk as well.
Yeah, I totally agree with you :)

Actually the JavaScript issues I had were gone if I used the release gz packages of the Basilisk and UXP and not the git versions. Thanks!

Locked