2021-06-28 23:13:55 +00:00
|
|
|
{ stdenv
|
|
|
|
, lib
|
|
|
|
, fetchFromGitLab
|
|
|
|
, meson
|
|
|
|
, ninja
|
2021-02-05 17:12:51 +00:00
|
|
|
, pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
, gettext
|
|
|
|
, itstool
|
|
|
|
, libxml2
|
|
|
|
, glib
|
2021-07-03 03:11:41 +00:00
|
|
|
, shared-mime-info
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2022-08-12 12:06:08 +00:00
|
|
|
pname = "shared-mime-info";
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "2.4";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-09-26 12:46:18 +00:00
|
|
|
outputs = [ "out" "dev" ];
|
|
|
|
|
2021-06-28 23:13:55 +00:00
|
|
|
src = fetchFromGitLab {
|
|
|
|
domain = "gitlab.freedesktop.org";
|
|
|
|
owner = "xdg";
|
2022-08-12 12:06:08 +00:00
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2024-01-02 11:29:13 +00:00
|
|
|
hash = "sha256-5eyMkfSBUOD7p8woIYTgz5C/L8uQMXyr0fhL0l23VMA=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2021-06-28 23:13:55 +00:00
|
|
|
meson
|
|
|
|
ninja
|
2021-02-05 17:12:51 +00:00
|
|
|
pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
gettext
|
2021-07-03 03:11:41 +00:00
|
|
|
libxml2
|
2021-07-21 07:28:18 +00:00
|
|
|
] ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) shared-mime-info;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
libxml2
|
|
|
|
glib
|
|
|
|
];
|
|
|
|
|
2021-07-21 07:28:18 +00:00
|
|
|
strictDeps = true;
|
|
|
|
|
2021-06-28 23:13:55 +00:00
|
|
|
mesonFlags = [
|
|
|
|
"-Dupdate-mimedb=true"
|
|
|
|
];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A database of common MIME types";
|
|
|
|
homepage = "http://freedesktop.org/wiki/Software/shared-mime-info";
|
|
|
|
license = licenses.gpl2Plus;
|
|
|
|
platforms = platforms.unix;
|
2021-06-28 23:13:55 +00:00
|
|
|
maintainers = teams.freedesktop.members ++ [ maintainers.mimame ];
|
2022-04-27 09:35:20 +00:00
|
|
|
mainProgram = "update-mime-database";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|