boringssl: refactor, add maintainers (#453894)
This commit is contained in:
@@ -5,11 +5,11 @@
|
|||||||
cmake,
|
cmake,
|
||||||
ninja,
|
ninja,
|
||||||
perl,
|
perl,
|
||||||
buildGoModule,
|
gitUpdater,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
# reference: https://boringssl.googlesource.com/boringssl/+/refs/tags/0.20250818.0/BUILDING.md
|
# reference: https://boringssl.googlesource.com/boringssl/+/refs/tags/0.20250818.0/BUILDING.md
|
||||||
buildGoModule (finalAttrs: {
|
stdenv.mkDerivation (finalAttrs: {
|
||||||
pname = "boringssl";
|
pname = "boringssl";
|
||||||
version = "0.20251002.0";
|
version = "0.20251002.0";
|
||||||
|
|
||||||
@@ -30,18 +30,6 @@ buildGoModule (finalAttrs: {
|
|||||||
perl
|
perl
|
||||||
];
|
];
|
||||||
|
|
||||||
vendorHash = "sha256-IXmnoCYLoiQ/XL2wjksRFv5Kwsje0VNkcupgGxG6rSY=";
|
|
||||||
proxyVendor = true;
|
|
||||||
|
|
||||||
# hack to get both go and cmake configure phase
|
|
||||||
# (if we use postConfigure then cmake will loop runHook postConfigure)
|
|
||||||
preBuild = ''
|
|
||||||
cmakeConfigurePhase
|
|
||||||
''
|
|
||||||
+ lib.optionalString (stdenv.buildPlatform != stdenv.hostPlatform) ''
|
|
||||||
export GOARCH=$(go env GOHOSTARCH)
|
|
||||||
'';
|
|
||||||
|
|
||||||
env.NIX_CFLAGS_COMPILE = toString (
|
env.NIX_CFLAGS_COMPILE = toString (
|
||||||
lib.optionals stdenv.cc.isGNU [
|
lib.optionals stdenv.cc.isGNU [
|
||||||
# Needed with GCC 12 but breaks on darwin (with clang)
|
# Needed with GCC 12 but breaks on darwin (with clang)
|
||||||
@@ -52,42 +40,25 @@ buildGoModule (finalAttrs: {
|
|||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
buildPhase = ''
|
|
||||||
ninjaBuildPhase
|
|
||||||
'';
|
|
||||||
|
|
||||||
# CMAKE_OSX_ARCHITECTURES is set to x86_64 by Nix, but it confuses boringssl on aarch64-linux.
|
|
||||||
cmakeFlags = [
|
|
||||||
"-GNinja"
|
|
||||||
]
|
|
||||||
++ lib.optionals (stdenv.hostPlatform.isLinux) [ "-DCMAKE_OSX_ARCHITECTURES=" ];
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
runHook preInstall
|
|
||||||
|
|
||||||
mkdir -p $bin/bin $dev $out/lib
|
|
||||||
|
|
||||||
install -Dm755 bssl -t $bin/bin
|
|
||||||
install -Dm644 {libcrypto,libdecrepit,libpki,libssl}.a -t $out/lib
|
|
||||||
|
|
||||||
cp -r ../include $dev
|
|
||||||
|
|
||||||
runHook postInstall
|
|
||||||
'';
|
|
||||||
|
|
||||||
outputs = [
|
outputs = [
|
||||||
"out"
|
"out"
|
||||||
"bin"
|
"bin"
|
||||||
"dev"
|
"dev"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
passthru.updateScript = gitUpdater { };
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description = "Free TLS/SSL implementation";
|
description = "Free TLS/SSL implementation";
|
||||||
mainProgram = "bssl";
|
mainProgram = "bssl";
|
||||||
homepage = "https://boringssl.googlesource.com";
|
homepage = "https://boringssl.googlesource.com";
|
||||||
maintainers = [ lib.maintainers.thoughtpolice ];
|
maintainers = with lib.maintainers; [
|
||||||
|
thoughtpolice
|
||||||
|
theoparis
|
||||||
|
niklaskorz
|
||||||
|
];
|
||||||
license = with lib.licenses; [
|
license = with lib.licenses; [
|
||||||
openssl
|
asl20
|
||||||
isc
|
isc
|
||||||
mit
|
mit
|
||||||
bsd3
|
bsd3
|
||||||
|
|||||||
Reference in New Issue
Block a user