We're now getting errors on CI due to gcc-13 being missing. We can
probably be smarter about what packages we install, depending on the
workflow being run. But let's first unblock CI.
The error we get is a bit strange and inconsistent. Some CI runners seem
to already have gcc-13 installed. Others don't and can't find the gcc-13
package without the test Ubuntu toolchain PPA.
Now both /bin/zcat and /bin/gunzip are symlinks to /bin/gzip, and we
essentially running it in decompression mode through these symlinks.
This ensures we don't maintain 2 versions of code to decompress Gzipped
data anymore, and handle the use case of gzipped-streaming input only
once in the codebase.
Static analysis is great, but these workflows have not worked in a long
time, and no one was looking at the results. Our PVS Studio license and
our Sonar Cloud token have expired. Remove the workflows (at least for
now) so we don't waste CI runners and cache space. If someone is
motivated to revive these, they can revert this commit.
On the macOS 14 runners on GitHub actions, attempting to play audio (by
way of AudioOutputUnitStart) will open a pop-up asking for microphone
permission. This prevents any calling test to hang until they error out
with MACH_SEND_TIMED_OUT. This works around the issue by explicitly
enabling microphone access to all applications.
Just calling it "cmake" doesn't really describe what it is for, and a
future commit will add a lagom.yml. So let's call this serenity.yml to
make it clear that it tests SerenityOS itself.
This also renames the workflow, and updates some matrix orderings, to be
easier to distinguish between this job and the upcoming lagom.yml,
Unfortunately a composite action cannot have a `post:` step like
JavaScript actions are allowed to have, so we need to explicitly call
the post/save actions ourselves from the workflow file when we want to
save Toolchain/QEMU/ccache caches.
Co-Authored-By: Timothy Flynn <trflynn89@pm.me>
If there is a cache miss while downloading the ccache from GitHub/Azure,
the .ccache directory won't exist when we try to update the modification
time of its contents. Configure the ccache size first, which will create
the .ccache directory if it doesn't exist.
The JIT compiler was an interesting experiment, but ultimately the
security & complexity cost of doing arbitrary code generation at runtime
is far too high.
In subsequent commits, the bytecode format will change drastically, and
instead of rewriting the JIT to fit the new bytecode, this patch simply
removes the JIT instead.
Other engines, JavaScriptCore in particular, have already proven that
it's possible to handle the vast majority of contemporary web content
with an interpreter. They are currently ~5x faster than us on benchmarks
when running without a JIT. We need to catch up to them before
considering performance techniques with a heavy security cost.
The newer version installs a specific version of octokit, since the
latest version no longer supports the ruby installation in github
actions vms. This should resolve the CI issues.
These tests almost always fail, and all we do is try to boot. Disable it
for now until it can pass more reliably. Note we still compile aarch64,
so the build shouldn't break unnoticed.
This change introduces a new 2D graphics library that uses OpenGL to
perform painting operations. For now, it has extremely limited
functionality and supports only rectangle painting, but we have to
start somewhere.
Since this library is intended to be used by LibWeb, where the
WebContent process does not have an associated window, painting occurs
in an offscreen buffer created using EGL.
For now it is only possible to compile this library on linux.
Offscreen context creation on SerenityOS and MacOS will have to be
implemented separately in the future.
Co-Authored-By: Andreas Kling <awesomekling@gmail.com>
This version contains my patch that adds support for the proprietary
VideoCore mailbox message for reading the kernel command line, so
patches aren't needed anymore.
This is taking over 4 minutes to run on CI, and checks only a dozen
manpages, which is of limited benefit.
Leaving the manpage-generation code in place for now.
The test runner script sets the `halt_on_error=1` `UBSAN_OPTIONS` flag
already, this just makes it a compile-time decision. This should
alleviate some of the slowness of running on-target tests without
hardware acceleration.
The linusg/libjs-website repository, which houses the sources for
libjs.dev, has recently been archived. Because of this, we can no longer
update the test262 results page or the Wasm repl :^(. Let's remove these
GitHub Actions workflows to make CI green again.
We'll eventually need something similar once the situation with the
website is sorted out, but having this in git history is enough for
that.
Only the top 4 entries from this file actually show up on the GitHub
interface, so instead of cutting some people off, let's just not have
the list.
There are already sponsorship links in README.md anyway :^)
For some reason, the tests are flaky for the aarch64 architecture when
running on a CI runner. This causes a lot of unnecessary red crosses for
PRs and since the test outcome doesn't seem to be too trustworthy, we
are better off not running these tests for now.
These passes have not been shown to actually optimize any JS, and tests
have become very flaky with optimizations enabled. Until some measurable
benefit is shown, remove the optimization passes to reduce overhead of
maintaining bytecode operations and to reduce CI churn. The framework
for optimizations will live on in git history, and can be restored once
proven useful.
This includes a few new options to the .clang-format configuration file
to A) adhere to option changes within clang-format 16 (namely the option
AlignTrailingComments), and B) enforce existing style guide rules with
new clang-format rules.
On macOS, CMake incorrectly tries to add and/or remove rpaths from files
that it has already processed when it performs installation. Setting the
rpaths during the build process ensures that they are only set once, and
as a bonus, makes installation slightly more performant.
Fixes#10055.
The AArch64 port is still unstable, and in some cases, we may encounter
a kernel panic or Shell crash that prevents `test-results.log` from
being written to disk. The CI job would fail when we tried to print out
the contents of this non-existent file. We have been ignoring its
contents anyway, so let's not read it at all.
This should help us avoid accidentally breaking the build for AArch64.
Currently, some tests are expected to fail, so CI runs will be
considered successful even if the kernel panics or if there are test
failures.
For now, we have to build Qemu with a custom patch from source in order
for SystemServer to detect self-test mode.
Instead of manually compressing/decompressing a toolchain tarball if
`TRY_USE_LOCAL_TOOLCHAIN` is set, let's use the cache action's automatic
built-in compression (which is zstd, I believe).
This version now natively supports read-only caches (`cache/restore@v3`)
so we no longer need to pin the version to a commit in actions/cache#489
which is an unmerged PR.
The update is mostly mechanical:
- Steps with `CACHE_SKIP_SAVE` not set can use the plain `cache@v3`
action.
- Steps with `CACHE_SKIP_SAVE` set to a constant `true` are changed to
`cache/restore@v3`.
- Steps with saving disabled when running on a pull request are changed
to a pair of `cache/restore@v3` and `cache/save@v3`. This setup is
used for the large (100s of MB) ccache and Toolchain caches. As caches
saved in pull requests can only be utilized from within the same PR,
uploading these would only waste time and our storage quote.
Therefore, we skip the `save` steps if running on a PR.
Co-authored-by: Cameron Youell <cameronyouell@gmail.com>
This commit adds a GitHub Workflow to prebuild the dev container file
present at .devcontainer/devcontainer.json. This prebuilt image is
pushed to GitHub Container Registry (ghcr).
An additional devcontainer.json is added consuming that image.
This dev container can be selected in editors that process dev
containers (ie GitHub Codespaces), to speed up time to editor.
The macOS 13 runner has Xcode 14.3. which is required to compile JS
after d6b786b3fe (though we do have to
explicitly select Xcode 14.3, as 14.2 is the default).
"image" was an alias for "qemu-image".
I want to add an `image` userland utility, which clashes with that
shortname.
So remove the existing "image" target. It was just an alias for
"qemu-image".
If you use serenity.sh to build, nothing changes. This only affects you
if you run ninja manually -- you now have to say `ninja qemu-image` to
build the disk image.
The scope of these entries is not proportional to Brian's capacity for
code review at the moment, so let's stop marking him as "code owner" on
almost every PR. :^)
Make sure that we set SERENITY_SOURCE_DIR in ctest, and make sure to
pass the test root to the CI job.
More overhaul of test-js 'test root' finding is needed however.
This reverts commit b0606d90f0.
This seems to prevent libegl-mesa0 from being installed (which for some
reason isn't failing the Azure jobs - the failure seen later is that
ccache is not installed).
The current config on GitHub Actions does not use ccache, so it takes
quite a while to build. Instead, let's just run these tests on Azure
where we already build Ladybird and have ccache enabled. This also lets
us sanitize LibWeb on both Linux and macOS.
The script changes here are to A) handle differences between Azure and
GitHub Actions and B) to support running on macOS.
This is to allow using more recent C++20 features in upcoming commits.
Version 3.1.6 is what is installed on Ubuntu 22.10 and works with the
C++20 features we want.
Dependabot cannot be configured to significantly change the way it
formats its commit message, and it currently includes a "Signed-Off-By"
tag which is not allowed by our linter.
This updates our CI commit linter to exclude bots from the checks.
Generic PR actions include opening a PR, submit review comments, adding
new commits, etc. This prevents the reviewer and PR submitter from
having to manually bounce the labels back and forth in the general
case. The reviewer also may not have permission to set labels, meaning
the reviewer won't be able to update the labels accordingly themselves.
This does not handle more subjective labels such as pr-is-blocked and
pr-unclear. Unfortunately, there does not seem to be a GitHub Actions
trigger for when a PR has merge conflicts, so the pr-has-conflicts
label cannot be automatically applied.
Co-authored-by: kleines Filmröllchen <filmroellchen@serenityos.org>
They currently reside under Build/<arch>, meaning that they would be
redownloaded for each architecture/toolchain build combo. Move them to a
location that can be re-used for all builds.
Not a huge deal because this at least would still differ from the UCD
cache due to the locale_data.cmake. But this will use the same cache key
as other CI jobs.
The two major changes noticeable on the SerenityOS codebase are:
- Much improved support for const placement, clang-format-14 ignored
our east-const configuration in various places
- Different formatting for requires clauses, now breaking them onto
their own line, which helps with readability a bit
Current versions of CLion also ship LLVM 15, so the built-in formatting
now matches CI formatting again :^)
These are used by esvu, and it is sad that we don't have macOS binaries
availble for consumption by esvu users. Add a matrix job to handle this
separately from the test262 results.
So far we've gotten away with using GCC 11 for Lagom and to compile the
toolchain, but via #15795 we discovered a compiler bug that has been
fixed in the latest version but would error the build with CI's GCC 11.
Time for an upgrade :^)
We already use ubuntu-22.04 images in most places, so this is pretty
straightforward. The only exception is Idan's self-hosted runner, which
uses Ubuntu Focal. LibJS should build fine with GCC 11, still.
To prepare for placing all CLDR generated data in a new library,
LibLocale, this moves the code generators for the CLDR data to the
LibLocale subfolder.