Skip to content

Commit

Permalink
FIX: Change local state dir, which must be writable, from "/nix/store…
Browse files Browse the repository at this point in the history
…/...glusterfs..." to "/var"
  • Loading branch information
Thomas Strobel committed Dec 18, 2014
1 parent 972868c commit d07154b
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion pkgs/tools/filesystems/glusterfs/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,30 @@ stdenv.mkDerivation
rec {
inherit (s) name version;
inherit buildInputs;

preConfigure = ''
./autogen.sh
'';

configureFlags = [
''--with-mountutildir="$out/sbin"''
''--with-mountutildir="$out/sbin" --localstatedir=/var''
];

makeFlags = "DESTDIR=$(out)";

This comment has been minimized.

Copy link
@nh2

nh2 May 8, 2017

Contributor

Does this make the substituteInPlace calls below unnecessary?

This comment has been minimized.

Copy link
@nh2

This comment has been minimized.

Copy link
@fpletz

fpletz May 10, 2017

Member

Only one way to find out… test and read the Makefiles. 🙂

This comment has been minimized.

Copy link
@nh2

nh2 May 10, 2017

Contributor

I was hoping of another way to find out: Asking the original author, who had probably thought about those substituteInPlace calls, whether they had simply not thought about setting DESTDIR=$(out).


preInstall = ''
substituteInPlace api/examples/Makefile --replace '$(DESTDIR)' $out
substituteInPlace geo-replication/syncdaemon/Makefile --replace '$(DESTDIR)' $out
substituteInPlace geo-replication/syncdaemon/Makefile --replace '$(DESTDIR)' $out
substituteInPlace xlators/features/glupy/examples/Makefile --replace '$(DESTDIR)' $out
substituteInPlace xlators/features/glupy/src/Makefile --replace '$(DESTDIR)' $out
'';

postInstall = ''
cp -r $out/$out/* $out
rm -r $out/nix
'';

src = fetchurl {
inherit (s) url sha256;
};
Expand Down

0 comments on commit d07154b

Please sign in to comment.