samba4: add wrapPythonPrograms (#132373)
This commit is contained in:
parent
78090fd990
commit
61dd23eeaf
|
@ -1,7 +1,6 @@
|
||||||
{ lib, stdenv
|
{ lib, stdenv
|
||||||
, buildPackages
|
, buildPackages
|
||||||
, fetchurl
|
, fetchurl
|
||||||
, python3
|
|
||||||
, wafHook
|
, wafHook
|
||||||
, pkg-config
|
, pkg-config
|
||||||
, bison
|
, bison
|
||||||
|
@ -64,7 +63,7 @@ stdenv.mkDerivation rec {
|
||||||
];
|
];
|
||||||
|
|
||||||
nativeBuildInputs = [
|
nativeBuildInputs = [
|
||||||
python3
|
python3Packages.python
|
||||||
wafHook
|
wafHook
|
||||||
pkg-config
|
pkg-config
|
||||||
bison
|
bison
|
||||||
|
@ -83,7 +82,8 @@ stdenv.mkDerivation rec {
|
||||||
];
|
];
|
||||||
|
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
python3
|
python3Packages.python
|
||||||
|
python3Packages.wrapPython
|
||||||
readline
|
readline
|
||||||
popt
|
popt
|
||||||
dbus
|
dbus
|
||||||
|
@ -146,6 +146,8 @@ stdenv.mkDerivation rec {
|
||||||
# module, which works correctly in all cases.
|
# module, which works correctly in all cases.
|
||||||
PYTHON_CONFIG = "/invalid";
|
PYTHON_CONFIG = "/invalid";
|
||||||
|
|
||||||
|
pythonPath = [ python3Packages.dnspython tdb ];
|
||||||
|
|
||||||
preBuild = ''
|
preBuild = ''
|
||||||
export MAKEFLAGS="-j $NIX_BUILD_CORES"
|
export MAKEFLAGS="-j $NIX_BUILD_CORES"
|
||||||
'';
|
'';
|
||||||
|
@ -167,7 +169,10 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
# Samba does its own shebang patching, but uses build Python
|
# Samba does its own shebang patching, but uses build Python
|
||||||
find "$out/bin" -type f -executable -exec \
|
find "$out/bin" -type f -executable -exec \
|
||||||
sed -i '1 s^#!${python3.pythonForBuild}/bin/python.*^#!${python3.interpreter}^' {} \;
|
sed -i '1 s^#!${python3Packages.python.pythonForBuild}/bin/python.*^#!${python3Packages.python.interpreter}^' {} \;
|
||||||
|
|
||||||
|
# Fix PYTHONPATH for some tools
|
||||||
|
wrapPythonPrograms
|
||||||
'';
|
'';
|
||||||
|
|
||||||
passthru = {
|
passthru = {
|
||||||
|
|
Loading…
Reference in a new issue