forked from mirrors/nixpkgs
daemontools: fix build
This commit is contained in:
parent
bef0b67a84
commit
d7f6367471
|
@ -2,40 +2,42 @@
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "daemontools-0.76";
|
name = "daemontools-0.76";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "https://cr.yp.to/daemontools/${name}.tar.gz";
|
url = "https://cr.yp.to/daemontools/${name}.tar.gz";
|
||||||
sha256 = "07scvw88faxkscxi91031pjkpccql6wspk4yrlnsbrrb5c0kamd5";
|
sha256 = "07scvw88faxkscxi91031pjkpccql6wspk4yrlnsbrrb5c0kamd5";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
patches = [ ./fix-nix-usernamespace-build.patch ];
|
||||||
|
|
||||||
configurePhase = ''
|
configurePhase = ''
|
||||||
cd ${name}
|
cd ${name}
|
||||||
|
|
||||||
sed -ie '1 s_$_ -include ${glibc.dev}/include/errno.h_' src/conf-cc
|
sed -ie '1 s_$_ -include ${glibc.dev}/include/errno.h_' src/conf-cc
|
||||||
|
|
||||||
substituteInPlace src/Makefile \
|
substituteInPlace src/Makefile \
|
||||||
--replace '/bin/sh' '${bash}/bin/bash -oxtrace'
|
--replace '/bin/sh' '${bash}/bin/bash -oxtrace'
|
||||||
|
|
||||||
sed -ie "s_^PATH=.*_PATH=$src/${name}/compile:''${PATH}_" src/rts.tests
|
sed -ie "s_^PATH=.*_PATH=$src/${name}/compile:''${PATH}_" src/rts.tests
|
||||||
|
|
||||||
cat ${glibc.dev}/include/errno.h
|
cat ${glibc.dev}/include/errno.h
|
||||||
'';
|
'';
|
||||||
|
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
package/compile
|
package/compile
|
||||||
'';
|
'';
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
for cmd in $(cat package/commands); do
|
for cmd in $(cat package/commands); do
|
||||||
install -Dm755 "command/$cmd" "$out/bin/$cmd"
|
install -Dm755 "command/$cmd" "$out/bin/$cmd"
|
||||||
done
|
done
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
license = stdenv.lib.licenses.publicDomain;
|
license = stdenv.lib.licenses.publicDomain;
|
||||||
homepage = https://cr.yp.to/daemontools.html;
|
homepage = https://cr.yp.to/daemontools.html;
|
||||||
description = "A collection of tools for managing UNIX services.";
|
description = "A collection of tools for managing UNIX services.";
|
||||||
|
|
||||||
maintainers = with stdenv.lib.maintainers; [ kevincox ];
|
maintainers = with stdenv.lib.maintainers; [ kevincox ];
|
||||||
platforms = stdenv.lib.platforms.unix;
|
platforms = stdenv.lib.platforms.unix;
|
||||||
};
|
};
|
||||||
|
|
|
@ -0,0 +1,10 @@
|
||||||
|
--- admin.org/daemontools-0.76/src/chkshsgr.c 2001-07-12 17:49:49.000000000 +0100
|
||||||
|
+++ admin/daemontools-0.76/src/chkshsgr.c 2017-05-31 23:54:56.662174028 +0100
|
||||||
|
@@ -4,6 +4,7 @@
|
||||||
|
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
+ return 0;
|
||||||
|
short x[4];
|
||||||
|
|
||||||
|
x[0] = x[1] = 0;
|
Loading…
Reference in a new issue