Ladybird: Update Android build to work with current LibWebView/LibCore

Also update to the latest gradle plugin versions and other dependencies
as recommended by Android Studio Jellyfish.
This commit is contained in:
Andrew Kaster 2024-05-04 06:08:53 -06:00 committed by Andrew Kaster
parent b562c9759d
commit 68ec099b66
Notes: sideshowbarker 2024-07-17 03:59:29 +09:00
25 changed files with 89 additions and 94 deletions

View file

@ -23,13 +23,13 @@
// FIXME: Share b/w RequestServer and WebSocket
ErrorOr<ByteString> find_certificates(StringView serenity_resource_root)
{
auto cert_path = ByteString::formatted("{}/ladybird/cacert.pem", serenity_resource_root);
auto cert_path = ByteString::formatted("{}/res/ladybird/cacert.pem", serenity_resource_root);
if (!FileSystem::exists(cert_path))
return Error::from_string_view("Don't know how to load certs!"sv);
return cert_path;
}
ErrorOr<int> service_main(int ipc_socket, int fd_passing_socket)
ErrorOr<int> service_main(int ipc_socket)
{
// Ensure the certificates are read out here.
DefaultRootCACertificates::set_default_certificate_paths(Vector { TRY(find_certificates(s_serenity_resource_root)) });
@ -43,7 +43,6 @@ ErrorOr<int> service_main(int ipc_socket, int fd_passing_socket)
auto socket = TRY(Core::LocalSocket::adopt_fd(ipc_socket));
auto client = TRY(RequestServer::ConnectionFromClient::try_create(move(socket)));
client->set_fd_passing_socket(TRY(Core::LocalSocket::adopt_fd(fd_passing_socket)));
return event_loop.exec();
}