mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-26 21:33:03 +03:00
Fix relfs build
svn path=/nixpkgs/trunk/; revision=15574
This commit is contained in:
parent
d59710a58c
commit
f616199fb5
@ -12,38 +12,37 @@ args : with args;
|
|||||||
buildInputs = [ocaml fuse postgresql pcre
|
buildInputs = [ocaml fuse postgresql pcre
|
||||||
e2fsprogs gnomevfs pkgconfig GConf];
|
e2fsprogs gnomevfs pkgconfig GConf];
|
||||||
configureFlags = [];
|
configureFlags = [];
|
||||||
|
build = builderDefs.stringsWithDeps.fullDepEntry ("
|
||||||
|
cd deps
|
||||||
|
sed -e 's/^CPP/#&/ ; s/^# CPP=gcc/CPP=gcc/' -i Makefile.camlidl
|
||||||
|
make
|
||||||
|
cd ../src
|
||||||
|
sed -e 's/NULL\\|FALSE/0/g' -i Mimetype_lib.c
|
||||||
|
sed -e 's@/usr/local/@'\$out/'@' -i Makefile
|
||||||
|
sed -e '/install:/a\\\tmkdir -p '\$out'/share' -i Makefile
|
||||||
|
make
|
||||||
|
mkdir -p \$out/bin
|
||||||
|
echo '
|
||||||
|
createuser -A -D \$1
|
||||||
|
dropdb relfs_\$1 ;
|
||||||
|
rm -rf /tmp/relfs-\$1-tmp;
|
||||||
|
mkdir /tmp/relfs-\$1-tmp;
|
||||||
|
USER=\$1 relfs -f -s /tmp/relfs-\$1-tmp &
|
||||||
|
sleep 1 &&
|
||||||
|
kill -15 \${!};
|
||||||
|
rm -rf /tmp/relfs-\$1-tmp ;
|
||||||
|
psql -d relfs_\$1 <<< \"ALTER DATABASE relfs_\$1 OWNER TO \$1;
|
||||||
|
ALTER TABLE obj OWNER TO \$1;
|
||||||
|
ALTER TABLE obj_mimetype OWNER TO \$1;
|
||||||
|
ALTER TABLE membership OWNER TO \$1;\"' > \$out/bin/relfs_grant;
|
||||||
|
chmod a+x \$out/bin/relfs_grant;
|
||||||
|
") ["minInit" "doUnpack" "addInputs"];
|
||||||
};
|
};
|
||||||
in with localDefs;
|
in with localDefs;
|
||||||
let build = FullDepEntry ("
|
|
||||||
cd deps
|
|
||||||
sed -e 's/^CPP/#&/ ; s/^# CPP=gcc/CPP=gcc/' -i Makefile.camlidl
|
|
||||||
make
|
|
||||||
cd ../src
|
|
||||||
sed -e 's/NULL\\|FALSE/0/g' -i Mimetype_lib.c
|
|
||||||
sed -e 's@/usr/local/@'\$out/'@' -i Makefile
|
|
||||||
sed -e '/install:/a\\\tmkdir -p '\$out'/share' -i Makefile
|
|
||||||
make
|
|
||||||
mkdir -p \$out/bin
|
|
||||||
echo '
|
|
||||||
createuser -A -D \$1
|
|
||||||
dropdb relfs_\$1 ;
|
|
||||||
rm -rf /tmp/relfs-\$1-tmp;
|
|
||||||
mkdir /tmp/relfs-\$1-tmp;
|
|
||||||
USER=\$1 relfs -f -s /tmp/relfs-\$1-tmp &
|
|
||||||
sleep 1 &&
|
|
||||||
kill -15 \${!};
|
|
||||||
rm -rf /tmp/relfs-\$1-tmp ;
|
|
||||||
psql -d relfs_\$1 <<< \"ALTER DATABASE relfs_\$1 OWNER TO \$1;
|
|
||||||
ALTER TABLE obj OWNER TO \$1;
|
|
||||||
ALTER TABLE obj_mimetype OWNER TO \$1;
|
|
||||||
ALTER TABLE membership OWNER TO \$1;\"' > \$out/bin/relfs_grant;
|
|
||||||
chmod a+x \$out/bin/relfs_grant;
|
|
||||||
") [minInit doUnpack addInputs];
|
|
||||||
in
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "relfs-"+version;
|
name = "relfs-"+version;
|
||||||
builder = writeScript (name + "-builder")
|
builder = writeScript (name + "-builder")
|
||||||
(textClosure localDefs [build doMakeInstall doForceShare doPropagate]);
|
(textClosure localDefs ["build" "doMakeInstall" "doForceShare" "doPropagate"]);
|
||||||
meta = {
|
meta = {
|
||||||
description = "A relational filesystem on top of FUSE";
|
description = "A relational filesystem on top of FUSE";
|
||||||
inherit src;
|
inherit src;
|
||||||
|
Loading…
Reference in New Issue
Block a user