diff --git a/pkgs/development/libraries/abseil-cpp/default.nix b/pkgs/development/libraries/abseil-cpp/default.nix index f724c2e0acf1..0813a965524b 100644 --- a/pkgs/development/libraries/abseil-cpp/default.nix +++ b/pkgs/development/libraries/abseil-cpp/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, cmake }: +{ lib, stdenv, fetchFromGitHub, cmake, static ? stdenv.hostPlatform.isStatic }: stdenv.mkDerivation rec { pname = "abseil-cpp"; @@ -13,6 +13,7 @@ stdenv.mkDerivation rec { cmakeFlags = [ "-DCMAKE_CXX_STANDARD=17" + "-DBUILD_SHARED_LIBS=${if static then "OFF" else "ON"}" ]; nativeBuildInputs = [ cmake ]; diff --git a/pkgs/development/libraries/grpc/default.nix b/pkgs/development/libraries/grpc/default.nix index 8883761c5d19..5cdd9886690a 100644 --- a/pkgs/development/libraries/grpc/default.nix +++ b/pkgs/development/libraries/grpc/default.nix @@ -1,5 +1,5 @@ { lib, stdenv, fetchFromGitHub, fetchpatch, cmake, zlib, c-ares, pkg-config, re2, openssl, protobuf -, gflags, libnsl +, gflags, abseil-cpp, libnsl }: stdenv.mkDerivation rec { @@ -21,7 +21,7 @@ stdenv.mkDerivation rec { ]; nativeBuildInputs = [ cmake pkg-config ]; - propagatedBuildInputs = [ c-ares re2 zlib ]; + propagatedBuildInputs = [ c-ares re2 zlib abseil-cpp ]; buildInputs = [ c-ares.cmake-config openssl protobuf gflags ] ++ lib.optionals stdenv.isLinux [ libnsl ]; @@ -32,8 +32,10 @@ stdenv.mkDerivation rec { "-DgRPC_SSL_PROVIDER=package" "-DgRPC_PROTOBUF_PROVIDER=package" "-DgRPC_GFLAGS_PROVIDER=package" + "-DgRPC_ABSL_PROVIDER=package" "-DBUILD_SHARED_LIBS=ON" "-DCMAKE_SKIP_BUILD_RPATH=OFF" + "-DCMAKE_CXX_STANDARD=17" ]; # CMake creates a build directory by default, this conflicts with the diff --git a/pkgs/tools/inputmethods/fcitx5/fcitx5-mozc.nix b/pkgs/tools/inputmethods/fcitx5/fcitx5-mozc.nix index 08f43b87cfe2..d077b0a25c59 100644 --- a/pkgs/tools/inputmethods/fcitx5/fcitx5-mozc.nix +++ b/pkgs/tools/inputmethods/fcitx5/fcitx5-mozc.nix @@ -9,17 +9,6 @@ let rev = "e5b3425575734c323e1d947009dd74709437b684"; sha256 = "0pyrpz9c8nxccwpgyr36w314mi8h132cis8ijvlqmmhqxwsi30hm"; }; - # abseil-cpp in nixpkgs is too old - abseil-cpp_2020923 = abseil-cpp.overrideAttrs (old: rec { - version = "20200923.2"; - src = fetchFromGitHub { - owner = "abseil"; - repo = "abseil-cpp"; - rev = version; - sha256 = "G+wkaC4IPtyc/xCUyVFJOcHppPFU7KkhIHjv6uhVKGU="; - }; - cmakeFlags = [ "-DCMAKE_CXX_STANDARD=17" "-DBUILD_SHARED_LIBS=ON" ]; - }); zipcode_rel = "202011"; jigyosyo = fetchurl { url = "https://osdn.net/projects/ponsfoot-aur/storage/mozc/jigyosyo-${zipcode_rel}.zip"; @@ -44,7 +33,7 @@ in clangStdenv.mkDerivation rec { nativeBuildInputs = [ gyp ninja mesa python pkg-config qt5.wrapQtAppsHook six which unzip ]; - buildInputs = [ protobuf zinnia qt5.qtbase fcitx5 abseil-cpp_2020923 jsoncpp gtest gtk2 ]; + buildInputs = [ protobuf zinnia qt5.qtbase fcitx5 abseil-cpp jsoncpp gtest gtk2 ]; patches = [ # Support linking system abseil-cpp diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index fbd03d2edf3a..d6dc37742067 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -28422,7 +28422,9 @@ in osi = callPackage ../development/libraries/science/math/osi { }; - or-tools = callPackage ../development/libraries/science/math/or-tools { }; + or-tools = callPackage ../development/libraries/science/math/or-tools { + abseil-cpp = abseil-cpp.override { static = true; }; + }; rubiks = callPackage ../development/libraries/science/math/rubiks { };