about summary refs log tree commit diff
path: root/pkgs/applications
diff options
context:
space:
mode:
authorUri Baghin <uri@canva.com>2019-07-09 16:48:26 +1000
committerUri Baghin <uri@canva.com>2019-09-23 22:07:21 +1000
commit01f0c10ba229f281dcf7caa6e4cbaaade97f0197 (patch)
tree240d437d762e052bee6479f3f998118a21be13fb /pkgs/applications
parent82fe35cd29b848a3dd5f6de50f62b0ed9e4f5866 (diff)
downloadnixlib-01f0c10ba229f281dcf7caa6e4cbaaade97f0197.tar
nixlib-01f0c10ba229f281dcf7caa6e4cbaaade97f0197.tar.gz
nixlib-01f0c10ba229f281dcf7caa6e4cbaaade97f0197.tar.bz2
nixlib-01f0c10ba229f281dcf7caa6e4cbaaade97f0197.tar.lz
nixlib-01f0c10ba229f281dcf7caa6e4cbaaade97f0197.tar.xz
nixlib-01f0c10ba229f281dcf7caa6e4cbaaade97f0197.tar.zst
nixlib-01f0c10ba229f281dcf7caa6e4cbaaade97f0197.zip
jetbrains.idea-community: add darwin support
Diffstat (limited to 'pkgs/applications')
-rw-r--r--pkgs/applications/editors/jetbrains/common.nix6
-rw-r--r--pkgs/applications/editors/jetbrains/default.nix2
2 files changed, 4 insertions, 4 deletions
diff --git a/pkgs/applications/editors/jetbrains/common.nix b/pkgs/applications/editors/jetbrains/common.nix
index f535d7bff47c..bca85c01016a 100644
--- a/pkgs/applications/editors/jetbrains/common.nix
+++ b/pkgs/applications/editors/jetbrains/common.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeDesktopItem, makeWrapper, patchelf, p7zip
+{ stdenv, lib, makeDesktopItem, makeWrapper, patchelf, p7zip
 , coreutils, gnugrep, which, git, unzip, libsecret, libnotify
 }:
 
@@ -28,7 +28,7 @@ with stdenv; lib.makeOverridable mkDerivation rec {
 
   nativeBuildInputs = [ makeWrapper patchelf p7zip unzip ];
 
-  patchPhase = ''
+  patchPhase = lib.optionalString (!stdenv.isDarwin) ''
       get_file_size() {
         local fname="$1"
         echo $(ls -l $fname | cut -d ' ' -f5)
@@ -63,7 +63,7 @@ with stdenv; lib.makeOverridable mkDerivation rec {
     item=${desktopItem}
 
     makeWrapper "$out/$name/bin/${loName}.sh" "$out/bin/${execName}" \
-      --prefix PATH : "$out/libexec/${name}:${stdenv.lib.makeBinPath [ jdk coreutils gnugrep which git ]}" \
+      --prefix PATH : "$out/libexec/${name}:${lib.optionalString (stdenv.isDarwin) "${jdk}/jdk/Contents/Home/bin:"}${stdenv.lib.makeBinPath [ jdk coreutils gnugrep which git ]}" \
       --prefix LD_LIBRARY_PATH : "${stdenv.lib.makeLibraryPath [
         # Some internals want libstdc++.so.6
         stdenv.cc.cc.lib libsecret
diff --git a/pkgs/applications/editors/jetbrains/default.nix b/pkgs/applications/editors/jetbrains/default.nix
index a302be304e57..16a1c01363d8 100644
--- a/pkgs/applications/editors/jetbrains/default.nix
+++ b/pkgs/applications/editors/jetbrains/default.nix
@@ -134,7 +134,7 @@ let
           as IntelliJ.
         '';
         maintainers = with maintainers; [ edwtjo ];
-        platforms = platforms.linux;
+        platforms = platforms.linux ++ platforms.darwin;
       };
     });