mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 07:54:58 +00:00
LibSQL+Ladybird: Accept a list of paths for spawning SQLServer in Lagom
Use the new get_paths_for_helper_process method in Ladybird to query Qt for the runtime path of the current executable as well as the build directory paths.
This commit is contained in:
parent
3e6d790cf0
commit
ae9dc95b1f
4 changed files with 23 additions and 15 deletions
|
@ -7,6 +7,7 @@
|
|||
|
||||
#include <AK/DeprecatedString.h>
|
||||
#include <AK/Format.h>
|
||||
#include <AK/String.h>
|
||||
#include <AK/StringBuilder.h>
|
||||
#include <LibCore/ArgsParser.h>
|
||||
#include <LibCore/File.h>
|
||||
|
@ -361,8 +362,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
#if defined(AK_OS_SERENITY)
|
||||
auto sql_client = TRY(SQL::SQLClient::try_create());
|
||||
#else
|
||||
VERIFY(sql_server_path != nullptr);
|
||||
auto sql_client = TRY(SQL::SQLClient::launch_server_and_create_client(sql_server_path));
|
||||
VERIFY(!sql_server_path.is_empty());
|
||||
auto sql_client = TRY(SQL::SQLClient::launch_server_and_create_client({ TRY(String::from_utf8(sql_server_path)) }));
|
||||
#endif
|
||||
|
||||
SQLRepl repl(loop, database_name, move(sql_client));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue