Files

67 lines
1.5 KiB
Nix
Raw Permalink Normal View History

2025-03-23 19:10:22 -07:00
{ stdenv, fetchgit, pkgs, lib }:
let
fs = lib.fileset;
in
2024-09-04 23:42:32 -07:00
stdenv.mkDerivation {
pname = "yottadb";
version = "1.0.0";
2025-03-23 19:10:22 -07:00
/*src = fetchgit {
2024-09-04 23:42:32 -07:00
url = "https://gitlab.com/YottaDB/DB/YDB.git";
rev = "refs/tags/r2.00";
hash = "sha256-npdULo1GrawrmnlucTXKCs9LU0X/+WD5RICKXVDcX5E=";
deepClone = true;
leaveDotGit = true;
2025-03-23 19:10:22 -07:00
};*/
src = fs.toSource {
root = /home/charles/p3/YDB;
fileset = /home/charles/p3/YDB;
};
2024-09-04 23:42:32 -07:00
buildInputs = with pkgs; [
cmake
pkg-config
2025-03-23 19:10:22 -07:00
icu73
2024-09-04 23:42:32 -07:00
git
2025-03-23 19:10:22 -07:00
zlib
libelf
binutils
libxcrypt
readline
tcsh
curl
file
binutils
ncurses
glibc
libgcc
2024-09-04 23:42:32 -07:00
];
2025-03-23 19:10:22 -07:00
/*
2024-09-04 23:42:32 -07:00
buildPhase = ''
export HOME=$(pwd)
echo $(pwd)
pushd /build/YDB/
2025-03-23 19:10:22 -07:00
git config --global user.email "you@example.com"
git config --global user.name "Your Name"
2024-09-04 23:42:32 -07:00
git checkout -b tmp
2025-03-23 19:10:22 -07:00
touch a_file
git add a_file
git commit -am 'a_file makes index'
2024-09-04 23:42:32 -07:00
popd
make -j12
'';
2025-03-23 19:10:22 -07:00
*/
buildPhase = ''
export HOME=$(pwd)
echo $(pwd)
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/nix/store/wsyiyjdqqjsvrq42h13dl0cmqdbbb26i-icu4c-73.2/lib/
make -j12
'';
2024-09-04 23:42:32 -07:00
installPhase = ''
2025-03-23 19:10:22 -07:00
tmpdir=$(mktemp -d)
make install DESTDIR=$tmpdir
echo "installed to $tmpdir"
cd $tmpdir/nix/store/*/yottadb_r201/
./ydbinstall --utf8 --installdir=$out
2024-09-04 23:42:32 -07:00
'';
}