From 7fd0870be16a1fdc970b2a11fe64a5d1af8da288 Mon Sep 17 00:00:00 2001 From: sergiotarxz Date: Fri, 8 Jul 2022 18:17:00 +0200 Subject: [PATCH] Adding config dir to launcher. --- package.pl | 9 ++++++--- src/windows/launcher.c | 1 + 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/package.pl b/package.pl index 7b7969d..d3c5970 100644 --- a/package.pl +++ b/package.pl @@ -12,8 +12,11 @@ print $recuento_inner.''; $recuento_inner->mkpath; my $resources = $recuento_inner->child('resources'); $resources->mkpath; -copy_recursive('/usr/x86_64-w64-mingw32/usr/bin/*.{exe,dll,EXE,DLL}', $recuento_inner); -copy_recursive('/usr/x86_64-w64-mingw32/usr/share/recuento/', $resources); +copy_recursive('/home/sergio/recuento_root/usr/bin/*.{exe,dll,EXE,DLL}', $recuento_inner); +copy_recursive('/usr/lib/gcc/x86_64-w64-mingw32/11.3.0/libgcc_s_seh-1.dll', $recuento_inner); +copy_recursive('/usr/x86_64-w64-mingw32/usr/bin/libwinpthread-1.dll', $recuento_inner); +copy_recursive('/usr/lib/gcc/x86_64-w64-mingw32/11.3.0/libstdc++-6.dll', $recuento_inner); +copy_recursive('/home/sergio/recuento_root/usr/share/recuento/', $resources); move_launcher ($recuento_inner, $destdir); make_config ($destdir); make_share ($destdir); @@ -50,7 +53,7 @@ sub make_config { $etc_gtk->mkpath; $etc_gtk->child('settings.ini')->spew(<<'EOF'); [Settings] -gtk-font-name=LiberationSans 20 +gtk-font-name=Segoe UI 100 EOF } diff --git a/src/windows/launcher.c b/src/windows/launcher.c index d88ac9e..d400ba8 100644 --- a/src/windows/launcher.c +++ b/src/windows/launcher.c @@ -9,6 +9,7 @@ WINAPI WinMain(HINSTANCE hInstance, HINSTANCE, LPSTR pCmdLine, int nCmdShow) char* argument_list[] = { _fullpath(NULL, "recuento\\\\recuento.exe", 3000), NULL }; _putenv_s("DATADIR_RECUENTO", "recuento\\\\resources/"); _putenv_s("GSETTINGS_SCHEMA_DIR", "share\\\\glib-2.0\\\\schemas"); + _putenv_s("XDG_CONFIG_DIRS", "etc"); int return_value = execvp(argument_list[0], argument_list); if (return_value == -1) { printf ("%s\n", strerror(errno));