BrowserWorks / Waterfox-Classic

The Waterfox Classic repository, for legacy systems and customisation.
https://classic.waterfox.net
Mozilla Public License 2.0
175 stars 34 forks source link

How do I build this? #216

Open K4sum1 opened 4 months ago

K4sum1 commented 4 months ago

Making this a separate issue because I don't want to fill up a unrelated issue.

So far I've installed Mozillabuild 3.4, but not sure what else to do. ./mach bootstrap doesn't work so I just tried to ./mach build. Gave an error about not having Visual Studio 2017, so I installed it, and now I have ERROR: Cannot find the target C compiler, and I'm not sure how to fix it. It mentions mingw32, so I tried grabbing that, but I have no idea what to pick in the installer, if I even found the right installer. What do I do?

Also pinging @hawkeye116477 since he seems to have the most knowledge about this.

hawkeye116477 commented 4 months ago

Just check here => https://github.com/WaterfoxCo/Waterfox-Classic/blob/classic/.github/workflows/build.yml#L60 how it's done on GitHub Actions. Besides those you may also need Windows 10 SDK. However maybe you will need to try some lower versions of depends.

K4sum1 commented 4 months ago

I tried installing those, but I get the same error.

hawkeye116477 commented 4 months ago

Only installing isn't enough, you may need to set environment variables and start mozilla-build shell, almost everything same as in linked URL.

K4sum1 commented 4 months ago

I checked the environment variables, and they matched outside of mine being installed in different paths. I even rebooted since environment variables sometimes require that.

hawkeye116477 commented 4 months ago

So check if you can execute clang or clang-cl inside mozilla-build shell. If not, then maybe try editing batch file to set variables just like it's done on GH Actions, otherwise I've no idea, I was building it long time ago and don't remember.

K4sum1 commented 4 months ago

So I have clang in my path, I can run it with normal CMD. However I always get command not found in MozillaBuild.

hawkeye116477 commented 4 months ago

So as I said, you need to edit that mozilla-build batch file, find line with SET "PATH= and replace (add path to every thing which it can't find).

K4sum1 commented 4 months ago

After dealing with a few other issues and manually upgrading watchman, now I get this.

` 1:38.22 DEBUG: configure(2205,1): error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int [-Wimplicit-int]

1:38.22 DEBUG: 2205 | main(){return(0);}

1:38.22 DEBUG: | ^

1:38.23 DEBUG: | int

1:38.23 DEBUG: 1 error generated.

1:38.23 DEBUG: configure: failed program was:

1:38.23 DEBUG:

1:38.23 DEBUG: #line 2203 "configure"

1:38.23 DEBUG: #include "confdefs.h"

1:38.23 DEBUG:

1:38.23 DEBUG: main(){return(0);}

1:38.23 DEBUG: configure: error: installation or configuration problem: C compiler cannot create executables.

1:38.24 ERROR: old-configure failed`

hawkeye116477 commented 4 months ago

You need to try some older version of LLVM/Clang and maybe some other depends will also need different version if you'll still see errors. I don't remember which versions of these tools are good for Classic.

walmar commented 3 months ago

1) The issue topic seems to me to be a repetition that would be better avoided.

#issuecomment-831834241 - [Classic] Where's the build documentation? - Issue #43 - WaterfoxCo/Waterfox-Classic - GitHub

2) > I don't remember which versions of these tools are good for Classic.

#issuecomment-1319924456 - Windows action failing - Issue #173 - WaterfoxCo/Waterfox-Classic - GitHub

Eventually you can try with last good working llvm/clang version (14.0.6, scoop install [app]@[version]).

3) If the existing information is not enough to solve the issue, I think it's okay to additionally ask @MrAlex94, @buttercookie42, @aeiouaeiouaeiouaeiouaeiouaeiou or @dbsoft for the Waterfox Classic build environment recommendation to @K4sum1 and possibly others.

Kind of off-topic Personally, I would be especially grateful if someone could implement the following missing features. * Class Fields * [#issuecomment-1854367897 - GitHub - Missing redesigned code file view on Waterfox Classic (non-e10s) - Issue #94 - martok/palefill - GitHub](https://github.com/martok/palefill/issues/94#issuecomment-1854367897) * :is() CSS pseudo-class * [Merge pull request 'Implement :is() and :where() CSS pseudo-classes' (#2110) from FranklinDM/UXP-contrib:work_css-is-where into master · 9d9d93381e - UXP - Pale Moon repositories](https://repo.palemoon.org/MoonchildProductions/UXP/commit/9d9d93381e03157413f0a18fc544afafad4fff70) * Web Components * [#1361 - Implement Google WebComponents - UXP - Pale Moon repositories](https://repo.palemoon.org/MoonchildProductions/UXP/issues/1361) As such features don't seem to be properly provided by an extension like Polly+.
K4sum1 commented 3 months ago

Hmm, I might try getting everything I need to build Mypal68, and once or if I get that working, I try seeing if I can also build Waterfox Classic. If I still can't I'll try this, I'll look into those.

Squall-Leonhart commented 1 month ago

Just check here => https://github.com/WaterfoxCo/Waterfox-Classic/blob/classic/.github/workflows/build.yml#L60 how it's done on GitHub Actions. Besides those you may also need Windows 10 SDK. However maybe you will need to try some lower versions of depends.

workflows are outdated and don't work properly.

Squall-Leonhart commented 1 month ago

After dealing with a few other issues and manually upgrading watchman, now I get this.

` 1:38.22 DEBUG: configure(2205,1): error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int [-Wimplicit-int]

1:38.22 DEBUG: 2205 | main(){return(0);}

1:38.22 DEBUG: | ^

1:38.23 DEBUG: | int

1:38.23 DEBUG: 1 error generated.

1:38.23 DEBUG: configure: failed program was:

1:38.23 DEBUG:

1:38.23 DEBUG: #line 2203 "configure"

1:38.23 DEBUG: #include "confdefs.h"

1:38.23 DEBUG:

1:38.23 DEBUG: main(){return(0);}

1:38.23 DEBUG: configure: error: installation or configuration problem: C compiler cannot create executables.

1:38.24 ERROR: old-configure failed`

You can use current clang if you can find where you need to add cflag -Wno-error=implicit-function-declaration

walmar commented 1 month ago

In general, Firefox-based browsers usually include an about:buildconfig page with information about build configuration. This is linked on the about:support page.