Skip to content

Commit

Permalink
nix: issue located
Browse files Browse the repository at this point in the history
Signed-off-by: Alexis Pentori <[email protected]>
  • Loading branch information
apentori committed Feb 19, 2024
1 parent bebdfbe commit 28594c7
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions nix/shell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

let
inherit (pkgs) lib stdenv;

/* No Android SDK for Darwin aarch64. */
isMacM1 = stdenv.isDarwin && stdenv.isAarch64;
/* Lock requires Xcode verison. */
Expand All @@ -12,6 +11,7 @@ let
allowHigher = true;
};
/* Gomobile also needs the Xcode wrapper. */
#FIXME:something is not working with this
gomobileMod = pkgs.gomobile.override {
inherit xcodeWrapper;
withAndroidPkgs = !isMacM1;
Expand All @@ -21,15 +21,15 @@ in pkgs.mkShell {

buildInputs = with pkgs; [
git jq which
go_1_19 golangci-lint go-junit-report gopls go-bindata gomobileMod
go_1_19 golangci-lint go-junit-report gopls go-bindata # gomobileMod
mockgen protobuf3_20 protoc-gen-go
] ++ lib.optional stdenv.isDarwin xcodeWrapper;
] ++ lib.optionals (stdenv.isDarwin) [ xcodeWrapper ];

shellHook = lib.optionalString (!isMacM1) ''
ANDROID_HOME=${pkgs.androidPkgs.androidsdk}/libexec/android-sdk
ANDROID_NDK=$ANDROID_HOME/ndk-bundle
ANDROID_SDK_ROOT=$ANDROID_HOME
ANDROID_NDK_HOME=$ANDROID_NDK
# For some reason `ANDROID_HOME=${pkgs.androidPkgs.androidsdk}/libexec/android-sdk` is not working
shellHook = lib.optionalString (!isMacM1) ''
ANDROID_NDK=$ANDROID_HOME/ndk-bundle
ANDROID_SDK_ROOT=$ANDROID_HOME
ANDROID_NDK_HOME=$ANDROID_NDK
'';
# Sandbox causes Xcode issues on MacOS. Requires sandbox=relaxed.
# https://github.com/status-im/status-mobile/pull/13912
Expand Down

0 comments on commit 28594c7

Please sign in to comment.