Move runHook preConfigure so it can patch deps

This commit is contained in:
Joe DeVivo
2021-12-25 17:40:02 -07:00
committed by Stéphan Kochen
parent e631ca97c8
commit cface0f015
2 changed files with 11 additions and 3 deletions
+1 -1
View File
File diff suppressed because one or more lines are too long
+10 -2
View File
@@ -100,8 +100,6 @@ let
yarn_enable_nixify = "false";
configurePhase = ''
runHook preConfigure
# Copy over the Yarn cache.
rm -fr '${cacheFolder}'
mkdir -p '${cacheFolder}'
@@ -112,6 +110,16 @@ let
# Yarn may need a writable home directory.
export yarn_global_folder="$TMP"
# Some node-gyp calls may call out to npm, which could fail due to an
# read-only home dir.
export HOME="$TMP"
# running preConfigure after the cache is populated allows for
# preConfigure to contain substituteInPlace for dependencies as well as the
# main project. This is necessary for native bindings that maybe have
# hardcoded values.
runHook preConfigure
@@ISOLATED_INTEGRATION@@
# Run normal Yarn install to complete dependency installation.