summary refs log tree commit diff
path: root/pkgs/os-specific/darwin/xcode
diff options
context:
space:
mode:
authorMatthew Bauer <mjbauer95@gmail.com>2019-11-25 23:50:21 -0500
committerMatthew Bauer <mjbauer95@gmail.com>2020-01-03 15:19:34 -0500
commit3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a (patch)
treef9180c620874934276b16c733edd26851b75bccd /pkgs/os-specific/darwin/xcode
parent28c37155d7606db382afb2210b611525a3dca5d5 (diff)
downloadnixpkgs-3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a.tar
nixpkgs-3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a.tar.gz
nixpkgs-3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a.tar.bz2
nixpkgs-3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a.tar.lz
nixpkgs-3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a.tar.xz
nixpkgs-3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a.tar.zst
nixpkgs-3432b1baa8612d1dfcb750e4bc8f27b171b8ee1a.zip
xcode: don’t use libstdc++ on iOS
Apple no longer ships with it, so best to avoid forcing it into use.
Diffstat (limited to 'pkgs/os-specific/darwin/xcode')
-rw-r--r--pkgs/os-specific/darwin/xcode/sdk-pkgs.nix3
1 files changed, 2 insertions, 1 deletions
diff --git a/pkgs/os-specific/darwin/xcode/sdk-pkgs.nix b/pkgs/os-specific/darwin/xcode/sdk-pkgs.nix
index d25edff4956..e8302a82555 100644
--- a/pkgs/os-specific/darwin/xcode/sdk-pkgs.nix
+++ b/pkgs/os-specific/darwin/xcode/sdk-pkgs.nix
@@ -7,6 +7,7 @@
 , wrapCCWith
 , buildIosSdk, targetIosSdkPkgs
 , xcode
+, lib
 }:
 
 let
@@ -48,7 +49,7 @@ rec {
       tr '\n' ' ' < $out/nix-support/cc-cflags > cc-cflags.tmp
       mv cc-cflags.tmp $out/nix-support/cc-cflags
       echo "-target ${targetPlatform.config} -arch ${iosPlatformArch targetPlatform}" >> $out/nix-support/cc-cflags
-      echo "-isystem ${sdk}/usr/include -isystem ${sdk}/usr/include/c++/4.2.1/ -stdlib=libstdc++" >> $out/nix-support/cc-cflags
+      echo "-isystem ${sdk}/usr/include${lib.optionalString (lib.versionAtLeast "10" sdk.version) " -isystem ${sdk}/usr/include/c++/4.2.1/ -stdlib=libstdc++"}" >> $out/nix-support/cc-cflags
     '' + stdenv.lib.optionalString (sdk.platform == "iPhoneSimulator") ''
       echo "-mios-simulator-version-min=${minSdkVersion}" >> $out/nix-support/cc-cflags
     '' + stdenv.lib.optionalString (sdk.platform == "iPhoneOS") ''