forked from mirrors/nixpkgs
protobuf3: clean up cross compile
This commit is contained in:
parent
12ededf3d8
commit
1f9188b708
|
@ -1,7 +1,6 @@
|
|||
{ callPackage, useExternalProtoc, buildProtobuf, ... }:
|
||||
{ callPackage, ... }:
|
||||
|
||||
callPackage ./generic-v3.nix {
|
||||
version = "3.1.0";
|
||||
sha256 = "0qlvpsmqgh9nw0k4zrxlxf75pafi3p0ahz99v6761b903y8qyv4i";
|
||||
inherit useExternalProtoc buildProtobuf;
|
||||
}
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
{ callPackage, lib, useExternalProtoc, buildProtobuf, ... }:
|
||||
{ callPackage, lib, ... }:
|
||||
|
||||
lib.overrideDerivation (callPackage ./generic-v3.nix {
|
||||
version = "3.4.1";
|
||||
sha256 = "1lzxmbqlnmi34kymnf399azv86gmdbrf71xiad6wc24bzpkzqybb";
|
||||
inherit useExternalProtoc buildProtobuf;
|
||||
}) (attrs: { NIX_CFLAGS_COMPILE = "-Wno-error"; })
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
{ callPackage, lib, useExternalProtoc, buildProtobuf, ... }:
|
||||
{ callPackage, lib, ... }:
|
||||
|
||||
lib.overrideDerivation (callPackage ./generic-v3.nix {
|
||||
version = "3.5.1.1";
|
||||
sha256 = "1h4xydr5j2zg1888ncn8a1jvqq8fgpgckrmjg6lqzy9jpkvqvfdk";
|
||||
inherit useExternalProtoc buildProtobuf;
|
||||
}) (attrs: { NIX_CFLAGS_COMPILE = "-Wno-error"; })
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
{ callPackage, useExternalProtoc, buildProtobuf, ... }:
|
||||
{ callPackage, ... }:
|
||||
|
||||
callPackage ./generic-v3.nix {
|
||||
version = "3.6.1";
|
||||
sha256 = "1bg40miylzpy2wgbd7l7zjgmk43l12q38fq0zkn0vzy1lsj457sq";
|
||||
inherit useExternalProtoc buildProtobuf;
|
||||
}
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
{ stdenv
|
||||
, fetchFromGitHub
|
||||
, autoreconfHook, zlib, gmock, which, buildPackages
|
||||
, useExternalProtoc
|
||||
, buildProtobuf ? null
|
||||
, version, sha256
|
||||
, ...
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
let
|
||||
mkProtobufDerivation = buildProtobuf: stdenv: stdenv.mkDerivation rec {
|
||||
name = "protobuf-${version}";
|
||||
|
||||
# make sure you test also -A pythonPackages.protobuf
|
||||
|
@ -31,10 +30,10 @@ stdenv.mkDerivation rec {
|
|||
'';
|
||||
|
||||
nativeBuildInputs = [ autoreconfHook buildPackages.which buildPackages.stdenv.cc ]
|
||||
++ stdenv.lib.optional useExternalProtoc [ buildProtobuf ];
|
||||
++ (if buildProtobuf == null then [] else [ buildProtobuf ]);
|
||||
|
||||
buildInputs = [ zlib ];
|
||||
configureFlags = stdenv.lib.optional useExternalProtoc [ "--with-protoc=${buildProtobuf}/bin/protoc" ];
|
||||
configureFlags = if buildProtobuf == null then [] else [ "--with-protoc=${buildProtobuf}/bin/protoc" ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
|
@ -59,4 +58,7 @@ stdenv.mkDerivation rec {
|
|||
};
|
||||
|
||||
passthru.version = version;
|
||||
}
|
||||
};
|
||||
in mkProtobufDerivation(if (stdenv.buildPlatform != stdenv.hostPlatform)
|
||||
then (mkProtobufDerivation null buildPackages.stdenv)
|
||||
else null) stdenv
|
||||
|
|
|
@ -11726,30 +11726,10 @@ with pkgs;
|
|||
|
||||
protobuf = protobuf3_6;
|
||||
|
||||
protobuf3_6 = callPackage ../development/libraries/protobuf/3.6.nix {
|
||||
useExternalProtoc = (stdenv.hostPlatform != stdenv.buildPlatform);
|
||||
buildProtobuf = if (stdenv.hostPlatform != stdenv.buildPlatform)
|
||||
then buildPackages.protobuf3_6
|
||||
else null;
|
||||
};
|
||||
protobuf3_5 = callPackage ../development/libraries/protobuf/3.5.nix {
|
||||
useExternalProtoc = (stdenv.hostPlatform != stdenv.buildPlatform);
|
||||
buildProtobuf = if (stdenv.hostPlatform != stdenv.buildPlatform)
|
||||
then buildPackages.protobuf3_5
|
||||
else null;
|
||||
};
|
||||
protobuf3_4 = callPackage ../development/libraries/protobuf/3.4.nix {
|
||||
useExternalProtoc = (stdenv.hostPlatform != stdenv.buildPlatform);
|
||||
buildProtobuf = if (stdenv.hostPlatform != stdenv.buildPlatform)
|
||||
then buildPackages.protobuf3_4
|
||||
else null;
|
||||
};
|
||||
protobuf3_1 = callPackage ../development/libraries/protobuf/3.1.nix {
|
||||
useExternalProtoc = (stdenv.hostPlatform != stdenv.buildPlatform);
|
||||
buildProtobuf = if (stdenv.hostPlatform != stdenv.buildPlatform)
|
||||
then buildPackages.protobuf3_1
|
||||
else null;
|
||||
};
|
||||
protobuf3_6 = callPackage ../development/libraries/protobuf/3.6.nix { };
|
||||
protobuf3_5 = callPackage ../development/libraries/protobuf/3.5.nix { };
|
||||
protobuf3_4 = callPackage ../development/libraries/protobuf/3.4.nix { };
|
||||
protobuf3_1 = callPackage ../development/libraries/protobuf/3.1.nix { };
|
||||
protobuf2_5 = callPackage ../development/libraries/protobuf/2.5.nix { };
|
||||
|
||||
protobufc = callPackage ../development/libraries/protobufc/1.3.nix { };
|
||||
|
|
Loading…
Reference in a new issue