fd2982de56
Various warnings are emitted when building in Darwin environments, apparently due to the use of Clang as opposed to GCC. We could continue to add more `-Wno-xxx` flags as they arise, either with the existing `stdenv.isDarwin` condition or with the more correct `stdenv.cc.isClang`, but for an older codebase it seems more prodent to stick with the latest standard where it builds cleanly. The newer `-std=c++11` was also attempted, but it still failed to build.
44 lines
985 B
Nix
44 lines
985 B
Nix
{ lib, stdenv, fetchurl, pkg-config, expat, libmysqlclient,
|
|
enableXmlpipe2 ? false,
|
|
enableMysql ? true
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "sphinxsearch";
|
|
version = "2.2.11";
|
|
|
|
src = fetchurl {
|
|
url = "http://sphinxsearch.com/files/sphinx-${version}-release.tar.gz";
|
|
sha256 = "1aa1mh32y019j8s3sjzn4vwi0xn83dwgl685jnbgh51k16gh6qk6";
|
|
};
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
configureFlags = [
|
|
"--program-prefix=sphinxsearch-"
|
|
"--enable-id64"
|
|
] ++ lib.optionals (!enableMysql) [
|
|
"--without-mysql"
|
|
];
|
|
|
|
nativeBuildInputs = [
|
|
pkg-config
|
|
];
|
|
|
|
buildInputs = lib.optionals enableMysql [
|
|
libmysqlclient
|
|
] ++ lib.optionals enableXmlpipe2 [
|
|
expat
|
|
];
|
|
|
|
CXXFLAGS = "-std=c++98";
|
|
|
|
meta = {
|
|
description = "Open source full text search server";
|
|
homepage = "http://sphinxsearch.com";
|
|
license = lib.licenses.gpl2Plus;
|
|
platforms = lib.platforms.all;
|
|
maintainers = with lib.maintainers; [ ederoyd46 valodim ];
|
|
};
|
|
}
|