From 2825ed728f7d7f6e6cf2f4d92166684e6f5f24f5 Mon Sep 17 00:00:00 2001 From: Chris Bobbe Date: Mon, 30 Sep 2024 15:17:40 -0700 Subject: [PATCH 1/2] build: Update tools/checkout-keystore for modern `sq` The Sequoia CLI's changelog doesn't seem to mention these changes: https://gitlab.com/sequoia-pgp/sequoia-sq/-/blob/b4158f40dea64655cf7357d3c8f220e8bd1708d9/NEWS The `--recipient-file` rename, anyway, looks like it happened here: https://gitlab.com/sequoia-pgp/sequoia/-/commit/db90178d5b61e3310f979fdaefc66610adf0d33e https://gitlab.com/sequoia-pgp/sequoia/-/issues/933 Shrug; these changes are easy enough to adapt to. ``` $ sq version sq 0.38.0 using sequoia-openpgp 1.21.2 with cryptographic backend Nettle 3.10 (Cv448: true, OCB: true) ``` --- tools/checkout-keystore | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/checkout-keystore b/tools/checkout-keystore index 030af519ff2..4a20c7ea481 100755 --- a/tools/checkout-keystore +++ b/tools/checkout-keystore @@ -57,8 +57,8 @@ filter_sq_stderr() { grep -vE '^(Compressed|Encrypted) ' } -sq decrypt --recipient-key "${recipient_key}" \ - -o "${cleartext}" "${cryptotext}" \ +sq decrypt --recipient-file "${recipient_key}" \ + --output "${cleartext}" "${cryptotext}" \ 2> >(filter_sq_stderr >&2) wait_min=15 From 1db6467a74b8926fd48a82ca89e4ae12f22ee9ef Mon Sep 17 00:00:00 2001 From: Chris Bobbe Date: Mon, 30 Sep 2024 15:51:19 -0700 Subject: [PATCH 2/2] ios build: `yarn build` on node_modules/react-native/react-native-codegen We recently started building RN from Git, in 050957579. This caused an iOS build failure in the shell script '[CP-User] Generate Specs': Error: Cannot find module '/Users/chrisbobbe/dev/zulip-mobile/node_modules/react-native/packages/react-native-codegen/lib/cli/combine/combine-js-to-schema-cli.js' Note the last part: [...]/lib/cli/combine/combine-js-to-schema-cli.js' There is a [...]/src/[...] version of that file, but the /lib/ one is created by `yarn build`, and when I ran that, the app build succeeded. --- tools/postinstall | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/tools/postinstall b/tools/postinstall index 58a1b1d7e67..a6d5186cefa 100755 --- a/tools/postinstall +++ b/tools/postinstall @@ -7,6 +7,17 @@ patch_package() { node_modules/.bin/patch-package } +# Since we take react-native from Git, some packages that ship with it +# and are used in the build need their build scripts run. +build_rn_packages() { + ( + cd node_modules/react-native/packages/react-native-codegen/ + # A copy of the package's `yarn build` script + # with a `--verbose` flag removed. + yarn clean && node scripts/build.js + ) +} + pod_install() { [[ "$OSTYPE" == "darwin"* ]] \ || return 0 @@ -31,6 +42,8 @@ jetify() { patch_package +build_rn_packages + pod_install jetify