depot/third_party/nixpkgs/pkgs/development/interpreters/python/hooks/conda-unpack-hook.sh
Default email 14a1eeff01 Project import generated by Copybara.
GitOrigin-RevId: 6933d068c5d2fcff398e802f7c4e271bbdab6705
2021-05-29 03:34:57 +00:00

18 lines
499 B
Bash

# Setup hook to use in case a conda binary package is fetched
echo "Sourcing conda unpack hook"
condaUnpackPhase(){
echo "Executing condaUnpackPhase"
runHook preUnpack
# use lbzip2 for parallel decompression (bz2 is slow)
lbzip2 -dc -n $NIX_BUILD_CORES $src | tar --exclude='info' -x
# runHook postUnpack # Calls find...?
echo "Finished executing condaUnpackPhase"
}
if [ -z "${unpackPhase-}" ]; then
echo "Using condaUnpackPhase"
unpackPhase=condaUnpackPhase
fi