about summary refs log tree commit diff
diff options
context:
space:
mode:
authorrewine <luhongxu@deepin.org>2024-08-28 13:51:41 +0800
committerrewine <luhongxu@deepin.org>2024-09-04 10:16:54 +0800
commit76c5a31efefa16825c26da6811597ba2edb06257 (patch)
tree03b5bcecf3afa457f58e9c53502e9c9e333ee998
parent60348797ee3931aab1afbc2e165d8a6ca80374a7 (diff)
deepin.dde-api-proxy: init at 1.0.16
-rw-r--r--pkgs/desktops/deepin/core/dde-api-proxy/default.nix50
-rw-r--r--pkgs/desktops/deepin/default.nix1
2 files changed, 51 insertions, 0 deletions
diff --git a/pkgs/desktops/deepin/core/dde-api-proxy/default.nix b/pkgs/desktops/deepin/core/dde-api-proxy/default.nix
new file mode 100644
index 0000000000000..a46ead0f6e7c8
--- /dev/null
+++ b/pkgs/desktops/deepin/core/dde-api-proxy/default.nix
@@ -0,0 +1,50 @@
+{
+  stdenv,
+  lib,
+  fetchFromGitHub,
+  cmake,
+  pkg-config,
+  libsForQt5,
+  dtkcore,
+  coreutils,
+}:
+
+stdenv.mkDerivation rec {
+  pname = "dde-api-proxy";
+  version = "1.0.16";
+
+  src = fetchFromGitHub {
+    owner = "linuxdeepin";
+    repo = "dde-api-proxy";
+    rev = version;
+    hash = "sha256-kWodNftOPLIiQNPHAIC9p3VHFAis8FAI7vLJTqahAtU=";
+  };
+
+  postPatch = ''
+    for file in $(grep -rl "/usr/bin/false"); do
+      substituteInPlace $file --replace-fail "/usr/bin/false" "${coreutils}/bin/false"
+    done
+    for file in $(grep -rl "/usr/lib/dde-api-proxy"); do
+      substituteInPlace $file --replace-fail "/usr/lib/dde-api-proxy" "$out/lib/dde-api-proxy"
+    done
+  '';
+
+  nativeBuildInputs = [
+    cmake
+    pkg-config
+    libsForQt5.wrapQtAppsHook
+  ];
+
+  buildInputs = [
+    dtkcore
+    libsForQt5.qtbase
+  ];
+
+  meta = {
+    description = "Proxy service for dde";
+    homepage = "https://github.com/linuxdeepin/dde-api-proxy";
+    license = lib.licenses.gpl3Plus;
+    platforms = lib.platforms.linux;
+    maintainers = lib.teams.deepin.members;
+  };
+}
diff --git a/pkgs/desktops/deepin/default.nix b/pkgs/desktops/deepin/default.nix
index 4d3ca683845a4..d65299696e041 100644
--- a/pkgs/desktops/deepin/default.nix
+++ b/pkgs/desktops/deepin/default.nix
@@ -62,6 +62,7 @@ let
       dde-shell = callPackage ./core/dde-shell { };
       dde-grand-search = callPackage ./core/dde-grand-search { };
       dde-tray-loader = callPackage ./core/dde-tray-loader { };
+      dde-api-proxy = callPackage ./core/dde-api-proxy { };
 
       #### Dtk Application
       deepin-album = callPackage ./apps/deepin-album { };