diff options
author | Vladimír Čunát <v@cunat.cz> | 2023-11-16 22:06:22 +0100 |
---|---|---|
committer | Vladimír Čunát <v@cunat.cz> | 2023-11-16 22:06:22 +0100 |
commit | a7a8f8253db3f32cc15baf527d36ef7171425eba (patch) | |
tree | 5de25f1c82e7892f6aec7b3e5ddb718ff0c50df2 /pkgs/data | |
parent | f31242fcfd14e870eb6898fc8849bc4dee883054 (diff) | |
parent | 391aafc3d6b17ed5517795eb8b9c41ed7c6082e3 (diff) |
Merge #263535: staging-next 2023-10-26
Diffstat (limited to 'pkgs/data')
-rw-r--r-- | pkgs/data/misc/shared-mime-info/default.nix | 10 | ||||
-rw-r--r-- | pkgs/data/misc/shared-mime-info/fix-clang-warnings.patch | 31 |
2 files changed, 39 insertions, 2 deletions
diff --git a/pkgs/data/misc/shared-mime-info/default.nix b/pkgs/data/misc/shared-mime-info/default.nix index 197793db6c66f..8de13f2eaf368 100644 --- a/pkgs/data/misc/shared-mime-info/default.nix +++ b/pkgs/data/misc/shared-mime-info/default.nix @@ -14,7 +14,7 @@ stdenv.mkDerivation rec { pname = "shared-mime-info"; - version = "2.2"; + version = "2.3"; outputs = [ "out" "dev" ]; @@ -23,9 +23,15 @@ stdenv.mkDerivation rec { owner = "xdg"; repo = pname; rev = version; - sha256 = "sha256-QrRe/DcjpTMejHXDSOLbjpJywod8qIjP6/leTZ21rhE="; + sha256 = "sha256-cEfknRVtOJykEO9Iqlb0UoiayYtu+ugvmmZqAD5cGnE="; }; + patches = [ + # Submitted upstream at + # https://gitlab.freedesktop.org/xdg/shared-mime-info/-/issues/211 + ./fix-clang-warnings.patch + ]; + nativeBuildInputs = [ meson ninja diff --git a/pkgs/data/misc/shared-mime-info/fix-clang-warnings.patch b/pkgs/data/misc/shared-mime-info/fix-clang-warnings.patch new file mode 100644 index 0000000000000..2d185549c4e6b --- /dev/null +++ b/pkgs/data/misc/shared-mime-info/fix-clang-warnings.patch @@ -0,0 +1,31 @@ +diff --git a/meson.build b/meson.build +index 1780c44..7998a51 100644 +--- a/meson.build ++++ b/meson.build +@@ -49,12 +49,7 @@ endif + ############################################################################### + # Dependencies + +-check_functions = [ +- 'fdatasync', +-] +-foreach function : check_functions +- config.set('HAVE_'+function.to_upper(), cc.has_function(function)) +-endforeach ++config.set('HAVE_FDATASYNC', cc.has_function('fdatasync', prefix: '#include <unistd.h>')) + + + if get_option('build-translations') +diff --git a/src/update-mime-database.cpp b/src/update-mime-database.cpp +index 733ba06..4ca6d06 100644 +--- a/src/update-mime-database.cpp ++++ b/src/update-mime-database.cpp +@@ -2158,7 +2158,7 @@ static void check_in_path_xdg_data(const char *mime_path) + + env = getenv("XDG_DATA_DIRS"); + if (!env) +- env = "/usr/local/share/"PATH_SEPARATOR"/usr/share/"; ++ env = "/usr/local/share/" PATH_SEPARATOR "/usr/share/"; + dirs = g_strsplit(env, PATH_SEPARATOR, 0); + g_return_if_fail(dirs != NULL); + for (n = 0; dirs[n]; n++) |