changeset 586:4349b591c3ac

cmake: put NLS back
author David Demelier <markand@malikania.fr>
date Sat, 18 Mar 2023 20:05:58 +0100
parents 76ce31b0151f
children c027304ced27
files CMakeLists.txt cmake/FindNLS.cmake cmake/MlkLibrary.cmake cmake/MlkNls.cmake libmlk-core/CMakeLists.txt libmlk-core/mlk/core/action-script.c libmlk-core/mlk/core/action-stack.c libmlk-core/mlk/core/alloc.c libmlk-core/mlk/core/core.c libmlk-core/mlk/core/core_p.h libmlk-core/mlk/core/drawable-stack.c libmlk-core/mlk/core/err.c libmlk-core/mlk/core/game.c libmlk-core/mlk/core/panic.c libmlk-core/mlk/core/sys.c libmlk-core/mlk/core/sys.h libmlk-core/nls/fr.po libmlk-core/nls/libmlk-core.pot libmlk-util/mlk/util/sysconfig.cmake.h
diffstat 19 files changed, 311 insertions(+), 52 deletions(-) [+]
line wrap: on
line diff
--- a/CMakeLists.txt	Sat Mar 18 17:21:05 2023 +0100
+++ b/CMakeLists.txt	Sat Mar 18 20:05:58 2023 +0100
@@ -81,7 +81,8 @@
 find_library(M_LIBRARY m)
 
 if (MLK_WITH_NLS)
-	find_package(Intl)
+	find_package(NLS REQUIRED)
+	find_package(Intl REQUIRED)
 endif ()
 
 add_subdirectory(extern/libsqlite)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/cmake/FindNLS.cmake	Sat Mar 18 20:05:58 2023 +0100
@@ -0,0 +1,49 @@
+# FindNLS
+# -------
+#
+# Find Jansson library, this modules defines:
+#
+# Jansson_INCLUDE_DIRS, where to find jansson.h
+# Jansson_LIBRARIES, where to find library
+# Jansson_FOUND, if it is found
+#
+# The following imported targets will be available:
+#
+# NLS::gettext, if found.
+# NLS::msgfmt, if found.
+# NLS::msgmerge, if found.
+# NLS::xgettext, if found.
+#
+
+find_program(GETTEXT_EXECUTABLE gettext)
+find_program(MSGFMT_EXECUTABLE msgfmt)
+find_program(MSGMERGE_EXECUTABLE msgmerge)
+find_program(XGETTEXT_EXECUTABLE xgettext)
+
+if (GETTEXT_EXECUTABLE)
+	add_executable(NLS::gettext IMPORTED GLOBAL)
+	set_target_properties(NLS::gettext PROPERTIES
+		IMPORTED_LOCATION "${GETTEXT_EXECUTABLE}"
+	)
+endif ()
+
+if (MSGFMT_EXECUTABLE)
+	add_executable(NLS::msgfmt IMPORTED GLOBAL)
+	set_target_properties(NLS::msgfmt PROPERTIES
+		IMPORTED_LOCATION "${MSGFMT_EXECUTABLE}"
+	)
+endif ()
+
+if (MSGMERGE_EXECUTABLE)
+	add_executable(NLS::msgmerge IMPORTED GLOBAL)
+	set_target_properties(NLS::msgmerge PROPERTIES
+		IMPORTED_LOCATION "${MSGMERGE_EXECUTABLE}"
+	)
+endif ()
+
+if (XGETTEXT_EXECUTABLE)
+	add_executable(NLS::xgettext IMPORTED GLOBAL)
+	set_target_properties(NLS::xgettext PROPERTIES
+		IMPORTED_LOCATION "${XGETTEXT_EXECUTABLE}"
+	)
+endif ()
--- a/cmake/MlkLibrary.cmake	Sat Mar 18 17:21:05 2023 +0100
+++ b/cmake/MlkLibrary.cmake	Sat Mar 18 20:05:58 2023 +0100
@@ -81,18 +81,18 @@
 			${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}-config-version.cmake
 			VERSION ${CMAKE_PROJECT_VERSION}
 			COMPATIBILITY SameMajorVersion
-                )
-                configure_file(
-                	${CMAKE_CURRENT_SOURCE_DIR}/${LIB_NAME}-config.cmake
-                	${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}-config.cmake
-                	@ONLY
-                )
+		)
+ 		configure_file(
+ 			${CMAKE_CURRENT_SOURCE_DIR}/${LIB_NAME}-config.cmake
+ 			${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}-config.cmake
+ 			@ONLY
+ 		)
 		install(
 			TARGETS ${LIB_NAME}
 			EXPORT ${LIB_NAME}-targets
 			RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
-			LIBRARY DESTINATION ${CMAKE_INSTALL_BINDIR}
-			ARCHIVE DESTINATION ${CMAKE_INSTALL_BINDIR}
+			LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
+			ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
 			INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}
 		)
 		install(
@@ -103,7 +103,7 @@
 		)
 		install(
 			FILES
-	                	${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}-config.cmake
+				${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}-config.cmake
 				${CMAKE_CURRENT_BINARY_DIR}/${LIB_NAME}-config-version.cmake
 			DESTINATION ${MLK_WITH_CMAKEDIR}/${LIB_NAME}
 		)
--- a/cmake/MlkNls.cmake	Sat Mar 18 17:21:05 2023 +0100
+++ b/cmake/MlkNls.cmake	Sat Mar 18 20:05:58 2023 +0100
@@ -41,8 +41,9 @@
 
 		add_custom_command(
 			OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${name}.mo
-			COMMAND ${MSGFMT} -o ${CMAKE_CURRENT_BINARY_DIR}/${name}.mo ${l}
+			COMMAND NLS::msgfmt -o ${CMAKE_CURRENT_BINARY_DIR}/${name}.mo ${l}
 			COMMENT "Generating NLS translation ${name}.mo"
+			DEPENDS ${l}
 		)
 
 		list(APPEND ${_nls_OUTPUTS_VAR} ${CMAKE_CURRENT_BINARY_DIR}/${name}.mo)
@@ -55,14 +56,22 @@
 		# Commands to update .po files.
 		list(
 			APPEND _nls_po_cmds
-			COMMAND ${MSGMERGE} --backup=off -qU ${l} ${CMAKE_CURRENT_SOURCE_DIR}/nls/${_nls_NAME}.pot
+			COMMAND NLS::msgmerge --backup=off -qU ${l} ${CMAKE_CURRENT_SOURCE_DIR}/nls/${_nls_NAME}.pot
 		)
 	endforeach ()
 
 	add_custom_target(
 		po-${_nls_NAME}
 		COMMAND
-			${XGETTEXT} -cj -k_ -kN_ -LC -s -o ${CMAKE_CURRENT_SOURCE_DIR}/nls/${_nls_NAME}.pot ${_nls_SOURCES}
+			NLS::xgettext
+				--package-name "${LIB_NAME}"
+				--package-version "${CMAKE_PROJECT_VERSION}"
+				-cj
+				-k_
+				-kN_
+				-LC
+				-s
+				-o ${CMAKE_CURRENT_SOURCE_DIR}/nls/${_nls_NAME}.pot ${_nls_SOURCES}
 			${_nls_po_cmds}
 		COMMENT "Updating in-source .pot and .po files"
 	)
--- a/libmlk-core/CMakeLists.txt	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/CMakeLists.txt	Sat Mar 18 20:05:58 2023 +0100
@@ -103,6 +103,10 @@
 	list(APPEND LIBRARIES ${M_LIBRARY})
 endif ()
 
+if (MLK_WITH_NLS)
+	list(APPEND LIBRARIES Intl::Intl)
+endif ()
+
 mlk_library(
 	NAME libmlk-core
 	SOURCES ${HEADERS} ${NLS} ${SOURCES}
--- a/libmlk-core/mlk/core/action-script.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/action-script.c	Sat Mar 18 20:05:58 2023 +0100
@@ -21,6 +21,7 @@
 #include <string.h>
 
 #include "action-script.h"
+#include "core_p.h"
 #include "action.h"
 #include "err.h"
 
@@ -49,7 +50,7 @@
 	assert(a);
 
 	if (s->length >= s->actionsz)
-		return mlk_errf("no space in action script");
+		return mlk_errf(_("no space in action script"));
 
 	s->actions[s->length++] = a;
 
--- a/libmlk-core/mlk/core/action-stack.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/action-stack.c	Sat Mar 18 20:05:58 2023 +0100
@@ -21,6 +21,7 @@
 
 #include "action-stack.h"
 #include "action.h"
+#include "core_p.h"
 #include "err.h"
 
 #define FOREACH(st, iter) \
@@ -48,7 +49,7 @@
 		}
 	}
 
-	return mlk_errf("no space in action stack");
+	return mlk_errf(_("no space in action stack"));
 }
 
 int
--- a/libmlk-core/mlk/core/alloc.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/alloc.c	Sat Mar 18 20:05:58 2023 +0100
@@ -24,10 +24,11 @@
 
 #include <SDL.h>
 
+#include "core_p.h"
 #include "alloc.h"
 #include "panic.h"
 
-#define OOM_MSG "out of memory"
+#define OOM_MSG _("out of memory")
 #define BLKSIZE (offsetof (struct block, data))
 
 struct block {
--- a/libmlk-core/mlk/core/core.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/core.c	Sat Mar 18 20:05:58 2023 +0100
@@ -16,12 +16,15 @@
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  */
 
+#include "sysconfig.h"
+
 #include <assert.h>
 #include <stddef.h>
 #include <stdlib.h>
 #include <time.h>
 
 #include "core.h"
+#include "core_p.h"
 #include "sys.h"
 
 int
@@ -34,6 +37,10 @@
 
 	srand(time(NULL));
 
+#if defined(MLK_WITH_NLS)
+	bindtextdomain("libmlk-core", mlk_sys_dir(MLK_SYS_DIR_LOCALES));
+#endif
+
 	if ((err = mlk_sys_init(organization, name)) < 0)
 		return err;
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/libmlk-core/mlk/core/core_p.h	Sat Mar 18 20:05:58 2023 +0100
@@ -0,0 +1,31 @@
+/*
+ * core_p -- libcore private definitions
+ *
+ * Copyright (c) 2020-2022 David Demelier <markand@malikania.fr>
+ *
+ * Permission to use, copy, modify, and/or distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+#ifndef MLK_CORE_CORE_P_H
+#define MLK_CORE_CORE_P_H
+
+#include "sysconfig.h"
+
+#if defined(MLK_WITH_NLS)
+#       include <libintl.h>
+#       define _(s) dgettext("libmlk-core", s)
+#else
+#       define _(s) s
+#endif
+
+#endif /* !MLK_CORE_CORE_P_H */
--- a/libmlk-core/mlk/core/drawable-stack.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/drawable-stack.c	Sat Mar 18 20:05:58 2023 +0100
@@ -19,6 +19,7 @@
 #include <assert.h>
 #include <string.h>
 
+#include "core_p.h"
 #include "drawable.h"
 #include "drawable-stack.h"
 #include "err.h"
@@ -48,7 +49,7 @@
 		}
 	}
 
-	return mlk_errf("no space in drawable stack");
+	return mlk_errf(_("no space in drawable stack"));
 }
 
 int
--- a/libmlk-core/mlk/core/err.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/err.c	Sat Mar 18 20:05:58 2023 +0100
@@ -21,12 +21,13 @@
 
 #include <mlk/util/util.h>
 
+#include "core_p.h"
 #include "err.h"
 
 #define ERR_MAX         128
-#define DEFAULT_ERR     "no error"
+#define DEFAULT_ERR     _("no error")
 
-static MLK_THREAD_LOCAL char err[ERR_MAX] = DEFAULT_ERR;
+static MLK_THREAD_LOCAL char err[ERR_MAX];
 
 int
 mlk_errf(const char *fmt, ...)
@@ -53,7 +54,7 @@
 	ret = vsnprintf(err, sizeof (err), fmt, ap);
 
 	if (ret < 0)
-		mlk_util_strlcpy(err, "unknown error", sizeof (err));
+		mlk_util_strlcpy(err, _("unknown error"), sizeof (err));
 	else if (ret == 0)
 		mlk_util_strlcpy(err, DEFAULT_ERR, sizeof (err));
 
@@ -63,5 +64,8 @@
 const char *
 mlk_err(void)
 {
+	if (!err[0])
+		mlk_util_strlcpy(err, DEFAULT_ERR, sizeof (err));
+
 	return err;
 }
--- a/libmlk-core/mlk/core/game.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/game.c	Sat Mar 18 20:05:58 2023 +0100
@@ -20,6 +20,7 @@
 #include <string.h>
 
 #include "clock.h"
+#include "core_p.h"
 #include "err.h"
 #include "event.h"
 #include "game.h"
@@ -53,7 +54,7 @@
 	}
 
 	if (mlk_game.state == &mlk_game.states[mlk_game.statesz - 1])
-		return mlk_errf("no space in game states stack");
+		return mlk_errf(_("no space in game states stack"));
 
 	mlk_state_suspend(*mlk_game.state);
 	mlk_state_start(*(++mlk_game.state) = state);
--- a/libmlk-core/mlk/core/panic.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/panic.c	Sat Mar 18 20:05:58 2023 +0100
@@ -20,13 +20,14 @@
 #include <stdio.h>
 #include <stdlib.h>
 
+#include "core_p.h"
 #include "err.h"
 #include "panic.h"
 
 static void
 terminate(const char *what)
 {
-	fprintf(stderr, "abort: %s\n", what);
+	fprintf(stderr, _("abort: %s\n"), what);
 	abort();
 	exit(1);
 }
@@ -40,7 +41,7 @@
 	 * This should not happen, if it does it means the user did not fully
 	 * satisfied the constraint of mlk_panic_handler.
 	 */
-	fprintf(stderr, "abort: panic handler returned\n");
+	fprintf(stderr, _("abort: panic handler returned\n"));
 	exit(1);
 }
 
--- a/libmlk-core/mlk/core/sys.c	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/sys.c	Sat Mar 18 20:05:58 2023 +0100
@@ -41,6 +41,7 @@
 #include <sndfile.h>
 
 #include "alloc.h"
+#include "core_p.h"
 #include "err.h"
 #include "panic.h"
 #include "sound.h"
@@ -93,6 +94,82 @@
 }
 
 static inline int
+absolute(const char *path)
+{
+#if defined(_WIN32)
+	return !PathIsRelativeA(path);
+#else
+	/* Assuming UNIX like. */
+	if (path[0] == '/')
+		return 1;
+
+	return 0;
+#endif
+}
+
+static const char *
+system_directory(const char *whichdir)
+{
+	static MLK_THREAD_LOCAL char ret[PATH_MAX];
+	char *base, *binsect, path[PATH_MAX];
+
+	/*
+	 * Some system does not provide support (shame on you OpenBSD)
+	 * to the executable path. In that case we use PREFIX+<dir>
+	 * instead unless <dir> is already absolute.
+	 */
+
+	/*
+	 * If requested directory is absolute return immediately.
+	 *
+	 * e.g. whichdir == /usr/share  -> return immediately
+	 *      whichdir == bin         -> will be computed
+	 */
+	if (absolute(whichdir))
+		return whichdir;
+
+	/*
+	 * If MLK_BINDIR is absolute then we're unable to compute whichdir which
+	 * now is mandatory relative. In that case return its whole path to the
+	 * prefix.
+	 */
+	if (absolute(MLK_BINDIR) || !(base = SDL_GetBasePath()))
+		snprintf(ret, sizeof (ret), "%s/%s", MLK_PREFIX, whichdir);
+	else {
+		/*
+		 * Decompose the path to the given special directory by
+		 * computing relative directory to it from where the
+		 * binary is located.
+		 *
+		 * Example:
+		 *
+		 *   PREFIX/bin/<executable>
+		 *   PREFIX/share/mysupergame
+		 *
+		 * The path to the data is ../share/mysupergame starting from
+		 * the binary.
+		 *
+		 * Put the base path into the path and remove the value
+		 * of MLK_BINDIR.
+		 *
+		 * Example:
+		 *   from: /usr/local/bin
+		 *   to:   /usr/local
+		 */
+		mlk_util_strlcpy(path, base, sizeof (path));
+		SDL_free(base);
+
+		/* TODO: remove using negative offset. */
+		if ((binsect = strstr(path, MLK_BINDIR)))
+			*binsect = '\0';
+
+		snprintf(ret, sizeof (ret), "%s%s", path, whichdir);
+	}
+
+	return normalize(ret);
+}
+
+static inline int
 mkpath(const char *path)
 {
 #ifdef _WIN32
@@ -199,7 +276,7 @@
 #endif
 
 	if (!(mlk__audio_dev = alcOpenDevice(NULL))) {
-		mlk_errf("unable to open audio device");
+		mlk_errf(_("unable to open audio device"));
 		goto err;
 	}
 	if (!(mlk__audio_ctx = alcCreateContext(mlk__audio_dev, NULL))) {
@@ -222,7 +299,18 @@
 const char *
 mlk_sys_dir(enum mlk_sys_dir kind)
 {
-	return user_directory(kind);
+	assert(kind >= 0 && kind < MLK_SYS_DIR_LAST);
+
+	switch (kind) {
+	case MLK_SYS_DIR_SAVE:
+		return user_directory(kind);
+	case MLK_SYS_DIR_LOCALES:
+		return system_directory(MLK_LOCALEDIR);
+	default:
+		break;
+	}
+
+	return NULL;
 }
 
 int
--- a/libmlk-core/mlk/core/sys.h	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/mlk/core/sys.h	Sat Mar 18 20:05:58 2023 +0100
@@ -34,7 +34,17 @@
 	/**
 	 * Path to the preferred save directory.
 	 */
-	MLK_SYS_DIR_SAVE
+	MLK_SYS_DIR_SAVE,
+
+	/**
+	 * Path to NLS catalogs.
+	 */
+	MLK_SYS_DIR_LOCALES,
+
+	/**
+	 * Unused sentinel value.
+	 */
+	MLK_SYS_DIR_LAST
 };
 
 #if defined(__cplusplus)
--- a/libmlk-core/nls/fr.po	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/nls/fr.po	Sat Mar 18 20:05:58 2023 +0100
@@ -15,33 +15,44 @@
 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 #
-#, fuzzy
-msgid ""
-msgstr ""
-"Project-Id-Version: PACKAGE VERSION\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2021-09-21 22:44+0200\n"
-"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
-"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
-"Language-Team: LANGUAGE <LL@li.org>\n"
-"Language: \n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-
-#: /Users/markand/Dev/molko/libmlk-core/core/panic.c:30
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/panic.c:30
 #, c-format
 msgid "abort: %s\n"
 msgstr "fatal: %s\n"
 
-#: /Users/markand/Dev/molko/libmlk-core/core/panic.c:76
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/panic.c:44
 #, c-format
 msgid "abort: panic handler returned\n"
 msgstr "fatal: la fonction de panique n'aurait pas du continuer\n"
 
-#~ msgid "database not initialized correctly"
-#~ msgstr "database non initialisée"
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/err.c:28
+msgid "no error"
+msgstr "aucune erreur"
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/action-script.c:53
+msgid "no space in action script"
+msgstr "liste d'actions pleine"
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/action-stack.c:52
+msgid "no space in action stack"
+msgstr "liste d'actions pleine"
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/drawable-stack.c:52
+msgid "no space in drawable stack"
+msgstr "liste d'objets dessinables pleine"
 
-#, c-format
-#~ msgid "property '%s' was not found"
-#~ msgstr "propriété '%s' non trouvée"
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/game.c:57
+msgid "no space in game states stack"
+msgstr "liste d'états pleine"
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/alloc.c:31
+msgid "out of memory"
+msgstr "plus de mémoire disponible"
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/sys.c:203
+msgid "unable to open audio device"
+msgstr "impossible d'ouvrir un périphérique audio"
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/err.c:57
+msgid "unknown error"
+msgstr "erreur inconnue"
--- a/libmlk-core/nls/libmlk-core.pot	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-core/nls/libmlk-core.pot	Sat Mar 18 20:05:58 2023 +0100
@@ -1,14 +1,14 @@
 # SOME DESCRIPTIVE TITLE.
 # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
-# This file is distributed under the same license as the PACKAGE package.
+# This file is distributed under the same license as the libmlk-core package.
 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
 #
 #, fuzzy
 msgid ""
 msgstr ""
-"Project-Id-Version: PACKAGE VERSION\n"
+"Project-Id-Version: libmlk-core 0.1.0\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2021-09-21 22:47+0200\n"
+"POT-Creation-Date: 2023-03-18 19:26+0100\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -17,12 +17,44 @@
 "Content-Type: text/plain; charset=CHARSET\n"
 "Content-Transfer-Encoding: 8bit\n"
 
-#: /Users/markand/Dev/molko/libmlk-core/core/panic.c:30
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/panic.c:30
 #, c-format
 msgid "abort: %s\n"
 msgstr ""
 
-#: /Users/markand/Dev/molko/libmlk-core/core/panic.c:76
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/panic.c:44
 #, c-format
 msgid "abort: panic handler returned\n"
 msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/err.c:28
+msgid "no error"
+msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/action-script.c:53
+msgid "no space in action script"
+msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/action-stack.c:52
+msgid "no space in action stack"
+msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/drawable-stack.c:52
+msgid "no space in drawable stack"
+msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/game.c:57
+msgid "no space in game states stack"
+msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/alloc.c:31
+msgid "out of memory"
+msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/sys.c:203
+msgid "unable to open audio device"
+msgstr ""
+
+#: /Users/markand/Dev/mlk/molko/libmlk-core/mlk/core/err.c:57
+msgid "unknown error"
+msgstr ""
--- a/libmlk-util/mlk/util/sysconfig.cmake.h	Sat Mar 18 17:21:05 2023 +0100
+++ b/libmlk-util/mlk/util/sysconfig.cmake.h	Sat Mar 18 20:05:58 2023 +0100
@@ -19,6 +19,13 @@
 #ifndef MLK_UTIL_SYSCONFIG_H
 #define MLK_UTIL_SYSCONFIG_H
 
+#define MLK_PREFIX      "@CMAKE_INSTALL_PREFIX@"
+#define MLK_BINDIR      "@CMAKE_INSTALL_BINDIR@"
+#define MLK_LIBDIR      "@CMAKE_INSTALL_LIBDIR@"
+#define MLK_LOCALEDIR   "@CMAKE_INSTALL_LOCALEDIR@"
+
+#cmakedefine MLK_WITH_NLS
+
 #cmakedefine MLK_HAVE_PATH_MAX
 
 #cmakedefine MLK_HAVE_DIRENT_H