Commit graph

3212 commits

Author SHA1 Message Date
Simon Wanner 2ce61fe6ea LibTextCodec: Add GBK/GB18030 decoder
Includes changes from GB-18030-2022, which are not yet included in the
Encoding Specification, but WebKit, Blink and WPT are already updated.
2024-05-31 07:56:26 +02:00
Andrew Kaster e2d50dc5dd LibWeb: Move window.open TokenizedFeature parsing into its own file 2024-05-30 16:16:33 -04:00
Matthew Olsson 5740f93ef4 ClangPlugins: Check for strong root fields in GC allocated objects
GC-allocated objects should never have JS::SafeFunction/JS::Handle
fields.

For now the plugin only emits warnings here, as there are many cases
of this occurring in the codebase that aren't trivial to fix. It is also
behind a CMake flag since it is a _very_ loud warning.
2024-05-30 09:29:20 -06:00
Matthew Olsson 36d032b208 ClangPlugin: Emit diagnostics for incorrect usage of JS_CELL-like macros 2024-05-30 09:29:20 -06:00
Matthew Olsson 54fffef902 ClangPlugin: Add a PPCallbacks instance to collect JS_CELL-like macros 2024-05-30 09:29:20 -06:00
Matthew Olsson d74838f44d ClangPlugins: Use underscores instead of dashes in plugin names
This allows arguments to be passed to them from the command line
2024-05-30 09:29:20 -06:00
Matthew Olsson c739ae3e02 ClangPlugins: Change name of variable used for test compile options
This makes it more clear what it is used for
2024-05-30 09:29:20 -06:00
Timothy Flynn d9a277c139 Meta: Allow building Ladybird without QtMultimedia if Pulse is found 2024-05-30 11:07:08 -04:00
Timothy Flynn 31cd3124cc Meta: Do not link QtSvg in the GN build
We haven't used QtSvg in some time, we now use TVG files for icons.
2024-05-30 11:07:08 -04:00
Timothy Flynn 1d81cfe168 Meta: Port recent changes to the GN build
1fa7235fec
b9db9013f5
2024-05-30 11:07:08 -04:00
Jamie Mansfield 01bd179eef LibWeb: Implement UserActivation 2024-05-29 09:32:59 -06:00
koenditor 71631c8d21 Meta: Use ``find_package`` for configuring backtraces 2024-05-29 08:25:52 -06:00
Matthew Olsson 3e221fbb2d IDLGenerators: Handle restricted/unrestricted floating point types 2024-05-29 08:18:24 +02:00
Idan Horowitz 80dad2d0b5 Meta: Unbreak default grub configs after Prekernel/Kernel merge
These still assume the main boot image is called Prekernel, which is no
longer the case.
2024-05-27 17:35:42 +02:00
Timothy Flynn eb3b8f8ee4 LibWeb: Implement EventSource for server-sent events
EventSource allows opening a persistent HTTP connection to a server over
which events are continuously streamed.

Unfortunately, our test infrastructure does not allow for automating any
tests of this feature yet. It only works with HTTP connections.
2024-05-26 18:29:24 +02:00
Timothy Flynn 6056428cb5 LibWeb: Support unbuffered fetch requests
Supporting unbuffered fetches is actually part of the fetch spec in its
HTTP-network-fetch algorithm. We had previously implemented this method
in a very ad-hoc manner as a simple wrapper around ResourceLoader. This
is still the case, but we now implement a good amount of these steps
according to spec, using ResourceLoader's unbuffered API. The response
data is forwarded through to the fetch response using streams.

This will eventually let us remove the use of ResourceLoader's buffered
API, as all responses should just be streamed this way. The streams spec
then supplies ways to wait for completion, thus allowing fully buffered
responses. However, we have more work to do to make the other parts of
our fetch implementation (namely, Body::fully_read) use streams before
we can do this.
2024-05-26 18:29:24 +02:00
Timothy Flynn a38144fb2a Meta: Port recent changes to the GN build
5f17d9b34a
2024-05-26 18:29:24 +02:00
MacDue 0135af6e60 Meta: Add basic-shape as a CSS property value type 2024-05-26 07:55:50 +02:00
Timothy Flynn 398c99e981 Meta: Use SHA-256 verification for downloaded CA certificate files 2024-05-24 08:47:26 -04:00
Timothy Flynn 3b2c8d0af2 Meta: Use SHA-256 verification for downloaded TZDB files 2024-05-24 08:47:26 -04:00
Timothy Flynn 4d65a073b5 Meta: Use SHA-256 verification for downloaded CLDR files 2024-05-24 08:47:26 -04:00
Timothy Flynn 4ce7f49f2f Meta: Use SHA-256 verification for downloaded UCD files 2024-05-24 08:47:26 -04:00
Timothy Flynn 2f4e2436e8 Meta: Download files at configure time a bit more atomically
Download files to a temporary location, then only move the downloaded
file to the real location once the download is complete. This prevents
CMake from being confused about partially-downloaded files, e.g. if
someone presses ctrl+c in the middle of a download.

Note the GN build already behaves this way.
2024-05-24 08:47:26 -04:00
Timothy Flynn ec63f442f9 Meta: Add support for verifying downloaded files with their SHA-256 hash 2024-05-24 08:47:26 -04:00
Timothy Flynn 473f840142 Meta: Rename a variable in the invoke_generator() utility
This isn't always a "version file".
2024-05-24 08:47:26 -04:00
Timothy Flynn f3e04085d8 Meta: Port recent changes to the GN build
57714fbb38
76418f3ffa
8d5665ebe1
3aa36caa52
bfa330914d
2024-05-24 08:47:26 -04:00
Sönke Holz dc92bc284f Meta: Add virtio input devices to the RISC-V machine in run.py 2024-05-23 11:16:57 -06:00
Sönke Holz 018a28cf4a Kernel/HID: Add support for virtio input devices 2024-05-23 11:16:57 -06:00
Liav A. c48d540230 Kernel: Move VGATextModeConsole code to the Arch/x86_64/ISABus directory
This code is specific to x86 machines, as virtually no other computer
architecture has any compatibility with old VGA legacy functionality.
2024-05-23 05:07:56 -06:00
Andrew Kaster 7077e4d002 LibIDL+LibWeb: Add support for WebIDL setlike declarations on interfaces 2024-05-23 10:57:34 +02:00
Kirill Nikolaev 99f6528009 Kernel: Implement virtio-blk driver 2024-05-23 00:59:39 -06:00
Daniel Bertalan 060e6f4d21 Meta: Fix detection of default compiler versions
The logic in this script was *intended* to use the system's default
compiler if it was sufficiently new, and only start searching for the
latest installed if the default was not suitable.

However, the `cxx` program does not exist on Unixes, so the version
check always failed. We should be using the standard `c++` program name
instead.

After this change, the `CC` and `CXX` environment variables will have to
be used if someone wants to force a newer compiler version.
2024-05-23 00:56:37 -06:00
Matthew Olsson 6a4938a524 ClangPlugins: Convert all warnings to errors
Now that the lambda capture plugin isn't full of false-positives, we can
make the jump and start halting builds for these errors. It also allows
these plugins to be useful in CI.
2024-05-22 21:55:34 -06:00
Matthew Olsson e0d6afbabe ClangPlugins: Invert the lambda detection escape mechanism
Instead of being opt-out with NOESCAPE, it is now opt-in with ESCAPING.
Opt-out is ideal, but unfortunately this was extremely noisy when
compiling the entire codebase. Escaping functions are rarer than non-
escaping ones, so let's just go with that for now.

This also allows us to gradually add heuristics for detecting missing
ESCAPING annotations and emitting them as errors. It also nicely matches
the spelling that Swift uses (@escaping), which is where this idea
originally came from.
2024-05-22 21:55:34 -06:00
Tim Ledbetter d2b3007248 IDLGenerators: Use spec-compliant algorithm to parse integer values 2024-05-23 04:15:46 +02:00
Tim Ledbetter c0e504fbdd LibWeb: Add some missing [FIXME] IDL attributes 2024-05-21 19:29:04 +02:00
Tim Ledbetter 1bc0fcca8d IDLGenerators: Support [Reflect] on long and unsigned long attributes 2024-05-21 19:28:43 +02:00
Nico Weber ed2658d72c LibGfx/WebP: Move some to-be-shared code to WebPSharedLossless.h
No behavior change. No measurable performance different either.

(I tried `hyperfine 'Build/lagom/bin/image --no-output foo.webp'`
for a few input images before and after this change, and I didn't
see a difference. I also tried if moving both
Gfx::CanonicalCode::read_symbol() and
Compress::CanonicalCode::read_symbol() inline, and that didn't
help either.)
2024-05-20 13:17:34 -04:00
Tim Ledbetter 4d02bfc722 IDLGenerators: Add FIXME attribute support for non-readonly properties 2024-05-19 17:35:25 +02:00
Shannon Booth 7c69b4737b LibWeb: Add a 'FIXME' extended attribute for stubbed IDL attrs and fn's
This allows readonly attributes and functions to have a 'FIXME' extended
attribute added to the IDL definition to stub out the function. This
makes debugging web compatibility issues on live sites much easier as a
FIXME message is logged whenever one of these functions or attributes
are called.

Support still needs to be extended to non-readonly attributes (and some
other special cases), but this should allow us to set a big percentage
of the commented out attributes/functions in IDL files to instead use
this extended attribute.
2024-05-19 16:24:11 +02:00
Shannon Booth 8d5665ebe1 LibWeb: Add stub for IDBFactory 2024-05-19 16:24:11 +02:00
Shannon Booth b3c8974718 LibWeb: Factor out IDL generator using namespace hack into a function
So that when we need add a new namespace in LibWeb we only have a single
place that needs to be changed.
2024-05-19 07:21:08 +02:00
Timothy Flynn b4af851c74 Meta: Update gcc version requirement to 13+
The project can no longer be compiled with gcc-12.
2024-05-17 15:40:07 -06:00
Timothy Flynn 688599af57 Meta: Update check for clang's major version
We require clang-17 as of 76df5ae030, but
this check was not updated.
2024-05-17 15:40:07 -06:00
Nico Weber b6bbff5f3f LibGfx/WebPWriter: Move VP8L compression to WebPWriterLossless.{h,cpp}
* Matches how the loader is organized
* `compress_VP8L_image_data()` will grow longer when we add actual
  compression
* Maybe someone wants to write a lossy compressor one day

No behavior change.
2024-05-16 08:06:50 +02:00
Tim Ledbetter 63246577d2 LibWeb: Use correct type for MessageEventInit.ports
This didn't work previously because the IDL generator used the
incorrect type for some types of sequences within dictionaries.
2024-05-16 08:04:01 +02:00
Timothy Flynn 13fa42d2e5 Meta: Port recent changes to the GN build
2a56df8ecd
5da9af435e
2024-05-15 15:20:29 -06:00
Liav A. e1d435d0b0 Kernel/x86_64: Rename PCI HostBridge => PIIX4HostBridge
This code is actually for the old PIIX4 PCI host bridge, which requires
to use legacy x86 IO instructions.
2024-05-14 15:42:29 -06:00
Liav A. 0bab9a9313 Kernel: Move VirtIO RNG implementation to the Security/Random directory 2024-05-14 15:42:29 -06:00
Liav A. bbb749ab47 Kernel: Move VirtIO console code to the Devices/Serial/VirtIO directory 2024-05-14 15:42:29 -06:00