beegfs: build beeond

+34 -2
+34 -2
pkgs/os-specific/linux/beegfs/default.nix
··· 1 1 { stdenv, fetchurl, pkgconfig, unzip, which 2 2 , libuuid, attr, xfsprogs, cppunit, rdma-core 3 3 , zlib, openssl, sqlite, jre, openjdk, ant 4 + , openssh, perl, gfortran 4 5 } : 5 6 6 7 let 7 8 version = "6.17"; 8 9 9 10 subdirs = [ 11 + "beeond_thirdparty/build" 12 + "beeond_thirdparty_gpl/build" 10 13 "beegfs_thirdparty/build" 11 14 "beegfs_opentk_lib/build" 12 15 "beegfs_common/build" ··· 30 33 sha256 = "10xs7gzdmlg23k6zn1b7jij3lljn7rr1j6h476hq4lbg981qk3n3"; 31 34 }; 32 35 33 - nativeBuildInputs = [ which unzip pkgconfig cppunit openjdk ant]; 34 - buildInputs = [ libuuid attr xfsprogs zlib openssl sqlite jre rdma-core ]; 36 + nativeBuildInputs = [ which unzip pkgconfig cppunit openjdk ant perl ]; 37 + 38 + buildInputs = [ 39 + libuuid 40 + attr 41 + xfsprogs 42 + zlib 43 + openssl 44 + sqlite 45 + jre 46 + rdma-core 47 + openssh 48 + gfortran ]; 49 + 50 + hardeningDisable = [ "format" ]; # required for building beeond 35 51 36 52 postPatch = '' 37 53 patchShebangs ./ 38 54 find -type f -name Makefile -exec sed -i "s:/bin/bash:${stdenv.shell}:" \{} \; 39 55 find -type f -name Makefile -exec sed -i "s:/bin/true:true:" \{} \; 40 56 find -type f -name "*.mk" -exec sed -i "s:/bin/true:true:" \{} \; 57 + 58 + # unpack manually and patch variable name 59 + sed -i '/tar -C $(SOURCE_PATH) -xzf $(PCOPY_TAR)/d' beeond_thirdparty/build/Makefile 60 + cd beeond_thirdparty/source 61 + tar xf pcopy-0.96.tar.gz 62 + sed -i 's/\([^_]\)rank/\1grank/' pcopy-0.96/src/pcp.cpp 63 + cd ../.. 41 64 ''; 42 65 43 66 buildPhase = '' ··· 93 116 94 117 cp beegfs_client_devel/build/dist/usr/share/doc/beegfs-client-devel/examples/* $docDir 95 118 cp -r beegfs_client_devel/include/* $includeDir 119 + 120 + cp beeond_thirdparty_gpl/build/parallel $out/bin 121 + cp beeond_thirdparty/build/pcopy/p* $out/bin 122 + cp beeond_thirdparty/build/pcopy/s* $out/bin 123 + cp -r beeond/scripts/* $out 124 + cp beeond/source/* $out/bin 96 125 ''; 97 126 98 127 postFixup = '' ··· 100 129 --replace " java " " ${jre}/bin/java " \ 101 130 --replace "/opt/beegfs/beegfs-admon-gui/beegfs-admon-gui.jar" \ 102 131 "$libDirPkg/beegfs-admon-gui.jar" 132 + 133 + substituteInPlace $out/bin/beeond \ 134 + --replace /opt/beegfs/sbin "$out/bin" 103 135 ''; 104 136 105 137 doCheck = true;