|
41 | 41 | imports = [
|
42 | 42 | inputs.git-hooks.flakeModule
|
43 | 43 | ./local-remote-execution/flake-module.nix
|
| 44 | + ./tools/darwin/flake-module.nix |
44 | 45 | ];
|
45 | 46 | perSystem = {
|
46 | 47 | config,
|
|
69 | 70 | stable-rust-native = pkgs.rust-bin.stable.${stable-rust-version};
|
70 | 71 |
|
71 | 72 | maybeDarwinDeps = pkgs.lib.optionals pkgs.stdenv.isDarwin [
|
| 73 | + pkgs.darwin.apple_sdk.frameworks.CoreFoundation |
72 | 74 | pkgs.darwin.apple_sdk.frameworks.Security
|
73 | 75 | pkgs.libiconv
|
74 | 76 | ];
|
|
474 | 476 | pkgs.deno
|
475 | 477 | ];
|
476 | 478 |
|
477 |
| - shellHook = '' |
478 |
| - # Generate the .pre-commit-config.yaml symlink when entering the |
479 |
| - # development shell. |
480 |
| - ${config.pre-commit.installationScript} |
481 |
| -
|
482 |
| - # Generate lre.bazelrc which configures LRE toolchains when running |
483 |
| - # in the nix environment. |
484 |
| - ${config.local-remote-execution.installationScript} |
485 |
| -
|
486 |
| - # The Bazel and Cargo builds in nix require a Clang toolchain. |
487 |
| - # TODO(aaronmondal): The Bazel build currently uses the |
488 |
| - # irreproducible host C++ toolchain. Provide |
489 |
| - # this toolchain via nix for bitwise identical |
490 |
| - # binaries across machines. |
491 |
| - export CC=clang |
492 |
| - export PULUMI_K8S_AWAIT_ALL=true |
493 |
| - export PLAYWRIGHT_BROWSERS_PATH=${pkgs.playwright-driver.browsers} |
494 |
| - export PLAYWRIGHT_NODEJS_PATH=${pkgs.nodePackages_latest.nodejs} |
495 |
| - export PATH=$HOME/.deno/bin:$PATH |
496 |
| - deno types > web/platform/utils/deno.d.ts |
497 |
| - ''; |
| 479 | + shellHook = |
| 480 | + '' |
| 481 | + # Generate the .pre-commit-config.yaml symlink when entering the |
| 482 | + # development shell. |
| 483 | + ${config.pre-commit.installationScript} |
| 484 | +
|
| 485 | + # Generate lre.bazelrc which configures LRE toolchains when running |
| 486 | + # in the nix environment. |
| 487 | + ${config.local-remote-execution.installationScript} |
| 488 | +
|
| 489 | + # The Bazel and Cargo builds in nix require a Clang toolchain. |
| 490 | + # TODO(aaronmondal): The Bazel build currently uses the |
| 491 | + # irreproducible host C++ toolchain. Provide |
| 492 | + # this toolchain via nix for bitwise identical |
| 493 | + # binaries across machines. |
| 494 | + export CC=clang |
| 495 | + export PULUMI_K8S_AWAIT_ALL=true |
| 496 | + export PLAYWRIGHT_BROWSERS_PATH=${pkgs.playwright-driver.browsers} |
| 497 | + export PLAYWRIGHT_NODEJS_PATH=${pkgs.nodePackages_latest.nodejs} |
| 498 | + export PATH=$HOME/.deno/bin:$PATH |
| 499 | + deno types > web/platform/utils/deno.d.ts |
| 500 | + '' |
| 501 | + + (pkgs.lib.optionalString pkgs.stdenv.isDarwin '' |
| 502 | + # On Darwin generate darwin.bazelrc which configures |
| 503 | + # darwin libs & frameworks when running in the nix environment. |
| 504 | + ${config.darwin.installationScript} |
| 505 | + ''); |
498 | 506 | };
|
499 | 507 | };
|
500 | 508 | }
|
501 | 509 | // {
|
502 |
| - flakeModule = ./local-remote-execution/flake-module.nix; |
| 510 | + flakeModule = { |
| 511 | + default = ./local-remote-execution/flake-module.nix; |
| 512 | + darwin = ./tools/darwin/flake-module.nix; |
| 513 | + }; |
503 | 514 | };
|
504 | 515 | }
|
0 commit comments