Skip to content

Commit

Permalink
Make cache still build iOS stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
Ryan Trinkle committed Nov 8, 2017
1 parent 141552b commit e07c85b
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion cache.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ with import ./. {};
let inherit (nixpkgs.lib) optionals;
inputs = builtins.concatLists [
(builtins.attrValues sources)
(map (system: import ./shell.nix { inherit system; }) cacheTargetSystems)
(map (system: (import ./. { inherit system; iosSupportForce = true; }).tryReflexShell) cacheTargetSystems)
];
getOtherDeps = reflexPlatform: [
reflexPlatform.stage2Script
Expand Down
12 changes: 7 additions & 5 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,13 @@
, useReflexOptimizer ? false
, useTextJSString ? true
, iosSdkVersion ? "10.2"
, iosSdkLocation ? "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS${iosSdkVersion}.sdk"
, iosSupportForce ? false
, iosSupport ? if system == "x86_64-darwin" && (iosSupportForce || builtins.pathExists iosSdkLocation)
then true
else builtins.trace "Warning: No iOS sdk found at ${iosSdkLocation}; iOS support disabled. To enable, either install a version of Xcode that provides that SDK or override the value of iosSdkVersion to match your installed version." false
}:
let iosSdkLocation = "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS${iosSdkVersion}.sdk";
iosSupport = if nixpkgs.stdenv.isDarwin && builtins.pathExists iosSdkLocation
then true
else builtins.trace "Warning: No iOS sdk found at ${iosSdkLocation}; iOS support disabled. To enable, either install a version of Xcode that provides that SDK or override the value of iosSdkVersion to match your installed version." false;
globalOverlay = self: super: {
let globalOverlay = self: super: {
all-cabal-hashes = super.all-cabal-hashes.override {
src-spec = {
owner = "commercialhaskell";
Expand Down Expand Up @@ -677,4 +678,5 @@ in let this = rec {
lib = haskellLib;
inherit cabal2nixResult sources;
project = args: import ./project this (args { pkgs = nixpkgs; });
tryReflexShell = pinBuildInputs ("shell-" + system) tryReflexPackages [];
}; in this
3 changes: 1 addition & 2 deletions shell.nix
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
{ system ? builtins.currentSystem }:
let this = import ./. { inherit system; };
in this.pinBuildInputs ("shell-" + system) this.tryReflexPackages []
(import ./. { inherit system; }).tryReflexShell

0 comments on commit e07c85b

Please sign in to comment.