diff --git a/pkgs/development/libraries/accelio/cflags.patch b/pkgs/development/libraries/accelio/cflags.patch new file mode 100644 index 000000000000..f13eb3783af0 --- /dev/null +++ b/pkgs/development/libraries/accelio/cflags.patch @@ -0,0 +1,15 @@ +diff --git a/configure.ac b/configure.ac +index 6ce6b6b..180bad2 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -115,9 +115,7 @@ if test "$enable_debug" = "yes"; then + -fno-omit-frame-pointer -O0 -D_REENTRANT -D_GNU_SOURCE" + else + AC_DEFINE([NDEBUG],[],[No-debug Mode]) +- AM_CFLAGS="$AM_CFLAGS -g -ggdb -Wall -Werror -Wpadded -Wdeclaration-after-statement \ +- -Wsign-compare -Wc++-compat \ +- -O3 -D_REENTRANT -D_GNU_SOURCE" ++ AM_CFLAGS="$AM_CFLAGS -O3 -D_REENTRANT -D_GNU_SOURCE" + fi + + AC_CACHE_CHECK(whether ld accepts --version-script, ac_cv_version_script, diff --git a/pkgs/development/libraries/accelio/default.nix b/pkgs/development/libraries/accelio/default.nix new file mode 100644 index 000000000000..b56f2d81389d --- /dev/null +++ b/pkgs/development/libraries/accelio/default.nix @@ -0,0 +1,51 @@ +{ stdenv, fetchFromGitHub, autoreconfHook, libibverbs, librdmacm, libevent + +# Linux only deps +, numactl, kernel ? null +}: + +stdenv.mkDerivation rec { + name = "accelio-${version}${stdenv.lib.optionalString (kernel != null) "-kernel"}"; + version = "1.3"; + + src = fetchFromGitHub { + owner = "accelio"; + repo = "accelio"; + rev = "v${version}"; + sha256 = "05yqzjs12nymhs0pq1ypnfszgbmvfprjqd3gr2iz3vqbkpzi9n2c"; + }; + + patches = [ ./cflags.patch ]; + + postPatch = '' + # Don't build broken examples + sed -i '/AC_CONFIG_SUBDIRS(\[\(examples\|tests\)\/kernel/d' configure.ac + + # Allow the installation of xio kernel headers + sed -i 's,/opt/xio,''${out},g' src/kernel/xio/Makefile.in + ''; + + nativeBuildInputs = [ autoreconfHook ]; + buildInputs = [ libevent ]; + propagatedBuildInputs = [ libibverbs librdmacm ] + ++ stdenv.lib.optional stdenv.isLinux numactl; + + configureFlags = [ + "--enable-rdma" + "--disable-raio-build" + ] ++ stdenv.lib.optionals (kernel != null) [ + "--enable-kernel-module" + "--with-kernel=${kernel.dev}/lib/modules/${kernel.modDirVersion}/source" + "--with-kernel-build=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build" + ]; + + INSTALL_MOD_PATH = "\${out}"; + + meta = with stdenv.lib; { + homepage = http://www.accelio.org/; + description = "a high-performance asynchronous reliable messaging and RPC library optimized for hardware acceleration"; + license = licenses.bsd3; + platforms = with platforms; linux ++ freebsd; + maintainers = with maintainers; [ wkennington ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index bdbc5e64f9c2..9237ce378c57 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -5431,6 +5431,8 @@ let aalib = callPackage ../development/libraries/aalib { }; + accelio = callPackage ../development/libraries/accelio { }; + accountsservice = callPackage ../development/libraries/accountsservice { }; acl = callPackage ../development/libraries/acl { }; @@ -9204,6 +9206,8 @@ let linuxPackagesFor = kernel: self: let callPackage = newScope self; in rec { inherit kernel; + accelio = callPackage ../development/libraries/accelio { }; + acpi_call = callPackage ../os-specific/linux/acpi-call {}; batman_adv = callPackage ../os-specific/linux/batman-adv {};