summary refs log tree commit diff
path: root/pkgs/development/python-modules
diff options
context:
space:
mode:
authorAllen Nelson <anelson@narrativescience.com>2015-05-24 10:19:13 -0500
committerAllen Nelson <anelson@narrativescience.com>2015-05-24 10:21:33 -0500
commit6bb2e47abf8317364c86d84808a04a72e40ff1f0 (patch)
tree10b6c115797abfed6472974477a1932c1168d08e /pkgs/development/python-modules
parentbf1a16bbeac462ee46674e4d340a7f1edffddb0a (diff)
downloadnixlib-6bb2e47abf8317364c86d84808a04a72e40ff1f0.tar
nixlib-6bb2e47abf8317364c86d84808a04a72e40ff1f0.tar.gz
nixlib-6bb2e47abf8317364c86d84808a04a72e40ff1f0.tar.bz2
nixlib-6bb2e47abf8317364c86d84808a04a72e40ff1f0.tar.lz
nixlib-6bb2e47abf8317364c86d84808a04a72e40ff1f0.tar.xz
nixlib-6bb2e47abf8317364c86d84808a04a72e40ff1f0.tar.zst
nixlib-6bb2e47abf8317364c86d84808a04a72e40ff1f0.zip
using makeWrapperArgs instead of setEnvVars
Diffstat (limited to 'pkgs/development/python-modules')
-rw-r--r--pkgs/development/python-modules/generic/default.nix6
-rw-r--r--pkgs/development/python-modules/generic/wrap.sh9
2 files changed, 7 insertions, 8 deletions
diff --git a/pkgs/development/python-modules/generic/default.nix b/pkgs/development/python-modules/generic/default.nix
index 9856682ba89b..378f047939f2 100644
--- a/pkgs/development/python-modules/generic/default.nix
+++ b/pkgs/development/python-modules/generic/default.nix
@@ -47,9 +47,9 @@
 # Execute after shell hook
 , postShellHook ? ""
 
-# Environment variables to set in wrapper scripts, in addition to
-# PYTHONPATH and PATH.
-, setEnvVars ? []
+# Additional arguments to pass to the makeWrapper function, which wraps
+# generated binaries.
+, makeWrapperArgs ? []
 
 , ... } @ attrs:
 
diff --git a/pkgs/development/python-modules/generic/wrap.sh b/pkgs/development/python-modules/generic/wrap.sh
index f9a65c6a33f3..33b9a06f6080 100644
--- a/pkgs/development/python-modules/generic/wrap.sh
+++ b/pkgs/development/python-modules/generic/wrap.sh
@@ -45,11 +45,10 @@ wrapPythonProgramsIn() {
                                  --prefix PYTHONPATH ':' $program_PYTHONPATH \
                                  --prefix PATH ':' $program_PATH"
 
-                # Add any additional environment variables to propagate.
-                for env_var in $setEnvVars; do
-                    # Look up the value of this variable
-                    local value=$(eval "echo \$$env_var")
-                    wrap_args="$wrap_args --set $env_var $value"
+                # Add any additional arguments provided by makeWrapperArgs
+                # argument to buildPythonPackage.
+                for arg in $makeWrapperArgs; do
+                    wrap_args="$wrap_args $arg"
                 done
                 wrapProgram $wrap_args
             fi