Add a simple shell script to update the local clangd configuration
according to the type of build selected by the user. Include
documentation on where the script might be useful when building
under different configurations.
This change makes all the pre-commit CI scripts runnable under Bash 3.2,
by replacing “mapfile” invocations in them code that first explicitly
creates an array, and then uses a while loop to populate the array.
Otherwise, without this change, the scripts all fail to run under Bash
3.2 — due to lack of support for “mapfile”.
Fixes https://github.com/LadybirdBrowser/ladybird/issues/283
This also drops bash from the list of homebrew dependencies in the build
instructions — because with this change, homebrew bash (v4) is no longer
needed; things will now work with the Apple-provided bash (v3.2)
This change also removes parts of the existing docs that explain how to
create a .clangd file with the project-recommended defaults. (Those
docs are no longer necessary — since this change adds a .clangd file to
the repo, containing those same defaults).
Trying to build VulkanLoader from source is a giant headache of
unnecessary packages. Every modern distro has vulkan packages, let's
depend on those instead of trying to build something for both wayland
and X11.
`nvim-lspconfig` has become more popular recently and is from the
Neovim organization directly. Headers have also been shifted to match
other documentation files.
GPU painter that uses AccelGfx is slower and way less complete compared
to both default Gfx::Painter and Skia painter. It does not make much
sense to keep it, considering Skia painter already uses Metal backend on
macOS by default and there is an option to enable GPU-accelerated
backend on linux.
This allows developers on macOS to open Ladybird.app in Instruments.
Add some documentation for how to use the command as well. It is enabled
automatically when CMAKE_BUILD_TYPE is not Release or RelWithDebInfo.
VP9 continues to function, but this also allows AV1 to be decoded. With
this commit, H.264 is still non-functional, as the decoder requires
some extra initial data from the track definition in the Matroska file.
Rather than removing LibLocale entirely, we will use it as a wrapper
around ICU (which has some C-like interfaces, and uses UTF-16 for its
string types). Using ICU will provide better web compatibility overall,
and will let us implement features we were previously unable to (e.g.
Intl.Collator requires data that is not in the JSON export of the CLDR).
Sometimes, especially on WSL, no fonts are installed, which will fail
`VERIFY(m_default_font)` in Ladybird/FontPlugin.
Note that Liberation Sans does not provide fonts for `cursive` and
`fantasy`, which will fall back to the default, sans-serif, font.
To cover all generic font families Microsoft's "Core fonts for the Web"
are available as `ttf-mscorefonts-installer`, `ttf-ms-fonts`, etc.
Allowing an environment variable to enable/disable the build for clangd
and other toolchains will improve the developer-experience than
reconfiguring and building the toolchain manually.
Now you will have to call the command as following
$ CLANG_ENABLE_CLANGD=ON Toolchain/BuildClang.sh
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.
Turns out clangd supports code formatting using the clang-format
engine. Because we also document another code formatter to install,
when users use both extensions VSCode will ask to choose one or the
other. Therefore, let's just choose clangd for code formatting since
it is needed anyways for code comprehension.
Explain a bit about what pkg is and what it isn't, and clarify that
while Serenity kinda-sorta has the beginnings of a "package manager",
it's not exactly like a typical Linux package manager with binary
software.
This commit un-deprecates DeprecatedString, and repurposes it as a byte
string.
As the null state has already been removed, there are no other
particularly hairy blockers in repurposing this type as a byte string
(what it _really_ is).
This commit is auto-generated:
$ xs=$(ack -l \bDeprecatedString\b\|deprecated_string AK Userland \
Meta Ports Ladybird Tests Kernel)
$ perl -pie 's/\bDeprecatedString\b/ByteString/g;
s/deprecated_string/byte_string/g' $xs
$ clang-format --style=file -i \
$(git diff --name-only | grep \.cpp\|\.h)
$ gn format $(git ls-files '*.gn' '*.gni')
This patch fixes `nix develop` commands not using proper paths, uses
the serenity root directory as an assumption for all commands and
adds variants of nix commands to use a custom entry point, for example
a shell.
If PulseAudio is available, the Qt6 audio plugin will never be used. So
let's remove it from the build.
Note that on macOS, the Qt6 audio plugin will be used if the Qt chrome
is enabled. Otherwise, Audio Unit will be used for the AppKit chrome.
This is the only instance of `*OS's` in the repo that does not use `s`
after the apostrophe.
Generally, the saxon genitive for singular nouns is always written as
`'s` even if they end in `s`.
`-serial mon:stdio` passes through all kinds of key combinations,
`-serial stdio` doesn't. This probably isn't something that we want
while running tests or CI, so switch to the non-passing variant.
aarch64 actually failed to run due to this, since it already had
`-serial stdio` in its arguments, causing a conflict. This is why that
entry is now gone entirely.