Skip to content

Commit

Permalink
nix: use nixpkgs unstable for gradle 8.8
Browse files Browse the repository at this point in the history
nix: ldflags are expected to be a list

chore: fix deprecated vendorSha256

nix: bump jdk to 17 & pass java version to gradle

make: set universalApk false in run-android target

nix: fix --replace deprecation warning

  - NixOS/nixpkgs#260776

ios: update pod and gem lockfiles

nix: bump nodejs to 20.12.2

nix: add Xcode 16.0 to allowed versions

chore: upgrade rn-image-crop-picker lib

nix: full path for missing dep in node_modules sh
  • Loading branch information
siddarthkay committed Sep 19, 2024
1 parent 1190fc8 commit 3c5b671
Show file tree
Hide file tree
Showing 12 changed files with 129 additions and 128 deletions.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,7 @@ run-android: export TARGET := android
# Disabled for debug builds to avoid 'maximum call stack exceeded' errors.
# https://github.com/status-im/status-mobile/issues/18493
run-android: export ORG_GRADLE_PROJECT_hermesEnabled := false
run-android: export ORG_GRADLE_PROJECT_universalApk := false
run-android: ##@run Build Android APK and start it on the device
@scripts/run-android.sh

Expand Down
1 change: 1 addition & 0 deletions fastlane/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ GEM

PLATFORMS
arm64-darwin-22
arm64-darwin-23
x86_64-darwin-22

DEPENDENCIES
Expand Down
4 changes: 2 additions & 2 deletions ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1485,7 +1485,7 @@ SPEC CHECKSUMS:
FBLazyVector: 56e0e498dbb513b96c40bac6284729ba4e62672d
FBReactNativeSpec: 146c741a3f40361f6bc13a4ba284678cbedb5881
fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9
glog: 36c15c01d70ed395c6e4f3619f98a23ee415b07a
glog: c5d68082e772fa1c511173d6b30a9de2c05a69a2
hermes-engine: 1d1835b2cc54c381909d94d1b3c8e0a2f1a94a0e
HMSegmentedControl: 34c1f54d822d8308e7b24f5d901ec674dfa31352
Keycard: ac6df4d91525c3c82635ac24d4ddd9a80aca5fc8
Expand Down Expand Up @@ -1578,4 +1578,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 5dd4a5279260d370bcdf016158c825ceb404ee06

COCOAPODS: 1.13.0
COCOAPODS: 1.15.2
220 changes: 110 additions & 110 deletions ios/StatusIm.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions nix/mobile/jsbundle/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ stdenv.mkDerivation {
lib.mkFilter {
root = path;
ignoreVCS = false;
include = [
include = [
"VERSION" "BUILD_NUMBER" "scripts/version/.*"
"src/.*" "shadow-cljs.edn"
# I want to avoid including the whole .git directory
Expand Down Expand Up @@ -57,7 +57,7 @@ stdenv.mkDerivation {
let anchor = ''{:source-paths ["src" "test/cljs"]'';
in ''
substituteInPlace shadow-cljs.edn \
--replace '${anchor}' \
--replace-quiet '${anchor}' \
'${anchor}
:maven {:local-repo "${deps.clojure}"}'
'';
Expand Down
8 changes: 4 additions & 4 deletions nix/overlay.nix
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,11 @@ in {
};

# Package version adjustments
gradle = super.gradle_8;
nodejs = super.nodejs-18_x;
gradle = super.gradle_8.override { java = super.openjdk17_headless; };
nodejs = super.nodejs_20;
ruby = super.ruby_3_1;
yarn = super.yarn.override { nodejs = super.nodejs-18_x; };
openjdk = super.openjdk11_headless;
yarn = super.yarn.override { nodejs = super.nodejs_20; };
openjdk = super.openjdk17_headless;
xcodeWrapper = callPackage ./pkgs/xcodeenv/compose-xcodewrapper.nix { } {
versions = ["15.1" "15.2" "15.3" "15.4"];
};
Expand Down
7 changes: 3 additions & 4 deletions nix/pkgs.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,10 @@ let
# For testing local version of nixpkgs
#nixpkgsSrc = (import <nixpkgs> { }).lib.cleanSource "/home/jakubgs/work/nixpkgs";

# We follow release 23-11 of nixpkgs
# https://github.com/NixOS/nixpkgs/releases/tag/23.11
# We use a commit from the unstable channel of nixpkgs for gradle 8.8
nixpkgsSrc = builtins.fetchTarball {
url = "https://github.com/NixOS/nixpkgs/archive/224fd9a362487ab2894dac0df161c84ab1d8880b.tar.gz";
sha256 = "sha256:1syvl39pi1h8lf5gkd9h7ksn5hp34cj7pa3abr59217kv0bdklhy";
url = "https://github.com/NixOS/nixpkgs/archive/48d567fc7b299de90f70a48e4263e31f690ba03e.tar.gz";
sha256 = "sha256:0zynbk52khdfhg4qfv26h3r5156xff5p0cga2cin7b07i7lqminh";
};

# Status specific configuration defaults
Expand Down
2 changes: 1 addition & 1 deletion nix/pkgs/go-maven-resolver/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ buildGoModule rec {
pname = "go-maven-resolver";
version = "v1.1.2";

vendorSha256 = "1p9pl33zpbw8zc85301mnp692lkr46ppm1q99wnqwynzi7x8hnkn";
vendorHash = "sha256-dlqI+onfeo4tTwmHeq8heVKRzLU1gFEQ+4iv+8egN90=";

src = fetchFromGitHub rec {
name = "${repo}-${version}-source";
Expand Down
2 changes: 1 addition & 1 deletion nix/pkgs/patch-maven-srcs/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ writeScript "patch-maven-srcs" (''
function patchMavenSource() {
grep "$source" $1 > /dev/null && \
substituteInPlace $1 --replace "$2" "$3" 2>/dev/null
substituteInPlace $1 --replace-quiet "$2" "$3" 2>/dev/null
}
gradleFile="$1"
Expand Down
2 changes: 1 addition & 1 deletion nix/pkgs/patched-go/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

go.overrideDerivation (oldAttrs: {
postPatch = (oldAttrs.postPatch or "") + ''
substituteInPlace "src/cmd/go/internal/work/action.go" --replace \
substituteInPlace "src/cmd/go/internal/work/action.go" --replace-quiet \
'tmp, err := ioutil.TempDir(os.Getenv("GOTMPDIR"), "go-build")' \
'var err error
tmp := os.Getenv("NIX_GOWORKDIR")
Expand Down
2 changes: 1 addition & 1 deletion nix/scripts/node_modules.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ findFilesNewerThan() {
\ # related code https://github.com/lugg/react-native-config/blob/v1.5.0/react-native-config.podspec#L52 \
-not -path "*/node_modules/react-native-config/ios/ReactNativeConfig/GeneratedDotEnv.m" \
\ # generated at runtime by react-native from v0.73.x onwards \
-not -path "*/node_modules/react-native/React/Fabric/*" \
-not -path "*/node_modules/react-native/React/Fabric/RCTThirdPartyFabricComponentsProvider.mm" \
-print
}

Expand Down
4 changes: 2 additions & 2 deletions nix/status-go/mobile/build.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
, outputFileName ? "status-go-${source.shortRev}-${platform}.aar" }:

let
inherit (lib) concatStringsSep optionalString optional;
inherit (lib) concatStringsSep optionalString optional splitString;
isIOS = platform == "ios";
isAndroid = platform == "android";
enforceXCodeAvailable = callPackage ./enforceXCodeAvailable.nix { };
Expand All @@ -31,7 +31,7 @@ in buildGoPackage {
++ optional isAndroid openjdk
++ optional isIOS xcodeWrapper;

ldflags = concatStringsSep " " goBuildLdFlags;
ldflags = goBuildLdFlags;

ANDROID_HOME = optionalString isAndroid androidPkgs.sdk;

Expand Down

0 comments on commit 3c5b671

Please sign in to comment.