From 79aebd3e05e08d5207aea674e4441cfbc3201a1e Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Sat, 9 Jul 2022 01:02:07 +0200 Subject: [PATCH] btcpayserver: enable build on darwin --- .../applications/blockchains/btcpayserver/default.nix | 10 +++++++--- pkgs/applications/blockchains/nbxplorer/default.nix | 11 ++++++++--- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/pkgs/applications/blockchains/btcpayserver/default.nix b/pkgs/applications/blockchains/btcpayserver/default.nix index 074e3b24af13..0a8414a96643 100644 --- a/pkgs/applications/blockchains/btcpayserver/default.nix +++ b/pkgs/applications/blockchains/btcpayserver/default.nix @@ -1,4 +1,7 @@ -{ lib, buildDotnetModule, fetchFromGitHub, dotnetCorePackages +{ lib +, buildDotnetModule +, fetchFromGitHub +, dotnetCorePackages , altcoinSupport ? false }: buildDotnetModule rec { @@ -19,8 +22,9 @@ buildDotnetModule rec { buildType = if altcoinSupport then "Altcoins-Release" else "Release"; + # macOS has a case-insensitive filesystem, so these two can be the same file postFixup = '' - mv $out/bin/{BTCPayServer,btcpayserver} + mv $out/bin/{BTCPayServer,btcpayserver} || : ''; meta = with lib; { @@ -28,6 +32,6 @@ buildDotnetModule rec { homepage = "https://btcpayserver.org"; maintainers = with maintainers; [ kcalvinalvin erikarvstedt ]; license = licenses.mit; - platforms = platforms.linux; + platforms = platforms.linux ++ platforms.darwin; }; } diff --git a/pkgs/applications/blockchains/nbxplorer/default.nix b/pkgs/applications/blockchains/nbxplorer/default.nix index 7d0f34492519..17cf43f8af0a 100644 --- a/pkgs/applications/blockchains/nbxplorer/default.nix +++ b/pkgs/applications/blockchains/nbxplorer/default.nix @@ -1,4 +1,8 @@ -{ lib, buildDotnetModule, fetchFromGitHub, dotnetCorePackages }: +{ lib +, buildDotnetModule +, fetchFromGitHub +, dotnetCorePackages +}: buildDotnetModule rec { pname = "nbxplorer"; @@ -16,14 +20,15 @@ buildDotnetModule rec { dotnet-runtime = dotnetCorePackages.aspnetcore_6_0; + # macOS has a case-insensitive filesystem, so these two can be the same file postFixup = '' - mv $out/bin/{NBXplorer,nbxplorer} + mv $out/bin/{NBXplorer,nbxplorer} || : ''; meta = with lib; { description = "Minimalist UTXO tracker for HD Cryptocurrency Wallets"; maintainers = with maintainers; [ kcalvinalvin erikarvstedt ]; license = licenses.mit; - platforms = platforms.linux; + platforms = platforms.linux ++ platforms.darwin; }; }