2
0
mirror of https://github.com/m-labs/artiq.git synced 2025-02-02 22:00:20 +08:00

Add current directory to the module search paths

Signed-off-by: Egor Savkin <es@m-labs.hk>
This commit is contained in:
Egor Savkin 2024-12-19 10:58:32 +08:00
parent ad1cd6fce1
commit dcf36e4b3b

View File

@ -200,7 +200,7 @@
## Modifies PATH to pass the wrapped python environment (i.e. python3.withPackages(...) to subprocesses.
## Allows subprocesses using python to find all packages you have installed
makeWrapperArgs = [
''--run 'if [ ! -z "$NIX_PYTHONPREFIX" ]; then export PATH=$NIX_PYTHONPREFIX/bin:$PATH;fi' ''
''--run 'if [ ! -z "$NIX_PYTHONPREFIX" ]; then export PYTHONPATH=`pwd`:$PYTHONPATH; export PATH=$NIX_PYTHONPREFIX/bin:$PATH;fi' ''
"--set FONTCONFIG_FILE ${pkgs.fontconfig.out}/etc/fonts/fonts.conf"
];
@ -390,7 +390,7 @@
progname=`basename -s .py $program`
outname=$out/bin/$progname
echo "#!${pkgs.bash}/bin/bash" >> $outname
echo "PYTHONPATH=`pwd`:$PYTHONPATH exec python3 -m artiq.frontend.$progname \"\$@\"" >> $outname
echo "exec python3 -m artiq.frontend.$progname \"\$@\"" >> $outname
chmod 755 $outname
fi
done