about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/text/poedit/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/tools/text/poedit/default.nix')
-rw-r--r--nixpkgs/pkgs/tools/text/poedit/default.nix48
1 files changed, 48 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/tools/text/poedit/default.nix b/nixpkgs/pkgs/tools/text/poedit/default.nix
new file mode 100644
index 000000000000..c53f521fddc4
--- /dev/null
+++ b/nixpkgs/pkgs/tools/text/poedit/default.nix
@@ -0,0 +1,48 @@
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, gettext, pkg-config, wxGTK31-gtk3,
+  boost, icu, lucenepp, asciidoc, libxslt, xmlto, gtk3, gtkspell3, pugixml,
+  nlohmann_json, hicolor-icon-theme, wrapGAppsHook }:
+
+stdenv.mkDerivation rec {
+  pname = "poedit";
+  version = "3.0";
+
+  src = fetchFromGitHub {
+    owner = "vslavik";
+    repo = "poedit";
+    rev = "v${version}-oss";
+    sha256 = "0bxhyxsa641ip6wab9ms9g4w6mb1bv46y5h5b436spl5c70rcn4z";
+  };
+
+  nativeBuildInputs = [ autoconf automake asciidoc wrapGAppsHook
+    libxslt xmlto boost libtool pkg-config ];
+
+  buildInputs = [ lucenepp nlohmann_json wxGTK31-gtk3 icu pugixml gtk3 gtkspell3 hicolor-icon-theme ];
+
+  propagatedBuildInputs = [ gettext ];
+
+  preConfigure = "
+    patchShebangs bootstrap
+    ./bootstrap
+  ";
+
+  configureFlags = [
+    "--without-cld2"
+    "--without-cpprest"
+    "--with-boost-libdir=${boost.out}/lib"
+    "CPPFLAGS=-I${nlohmann_json}/include/nlohmann/"
+  ];
+
+  preFixup = ''
+    gappsWrapperArgs+=(--prefix PATH : "${lib.makeBinPath [ gettext ]}")
+  '';
+
+  enableParallelBuilding = true;
+
+  meta = with lib; {
+    description = "Cross-platform gettext catalogs (.po files) editor";
+    homepage = "https://www.poedit.net/";
+    license = licenses.mit;
+    platforms = platforms.unix;
+    maintainers = with maintainers; [ dasj19 ];
+  };
+}