-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
89 additions
and
83 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,78 +1,2 @@ | ||
{ lib | ||
, stdenv | ||
, fetchFromGitHub | ||
, autoreconfHook | ||
, pkg-config | ||
, util-linux | ||
, hexdump | ||
, autoSignDarwinBinariesHook ? null | ||
, wrapQtAppsHook ? null | ||
, boost | ||
, libevent | ||
, miniupnpc | ||
, zeromq | ||
, zlib | ||
, db48 | ||
, sqlite | ||
, qrencode | ||
, qtbase ? null | ||
, qttools ? null | ||
, python3 | ||
, withGui ? false | ||
, withWallet ? true | ||
}: | ||
|
||
stdenv.mkDerivation rec { | ||
pname = if withGui then "sequentia" else "sequentiad"; | ||
version = "23.2.1"; | ||
|
||
src = ./.; | ||
|
||
nativeBuildInputs = | ||
[ autoreconfHook pkg-config ] | ||
++ lib.optionals stdenv.isLinux [ util-linux ] | ||
++ lib.optionals stdenv.isDarwin [ hexdump ] | ||
++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ autoSignDarwinBinariesHook ] | ||
++ lib.optionals withGui [ wrapQtAppsHook ]; | ||
|
||
buildInputs = [ boost libevent miniupnpc zeromq zlib ] | ||
++ lib.optionals withWallet [ db48 sqlite ] | ||
++ lib.optionals withGui [ qrencode qtbase qttools ]; | ||
|
||
configureFlags = [ | ||
"--with-boost-libdir=${boost.out}/lib" | ||
"--disable-bench" | ||
] ++ lib.optionals (!doCheck) [ | ||
"--disable-tests" | ||
"--disable-gui-tests" | ||
] ++ lib.optionals (!withWallet) [ | ||
"--disable-wallet" | ||
] ++ lib.optionals withGui [ | ||
"--with-gui=qt5" | ||
"--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin" | ||
]; | ||
|
||
# fix "Killed: 9 test/test_bitcoin" | ||
# https://github.com/NixOS/nixpkgs/issues/179474 | ||
hardeningDisable = lib.optionals (stdenv.isAarch64 && stdenv.isDarwin) [ "fortify" "stackprotector" ]; | ||
|
||
nativeCheckInputs = [ python3 ]; | ||
|
||
doCheck = false; | ||
|
||
checkFlags = | ||
[ "LC_ALL=en_US.UTF-8" ] | ||
# QT_PLUGIN_PATH needs to be set when executing QT, which is needed when testing Bitcoin's GUI. | ||
# See also https://github.com/NixOS/nixpkgs/issues/24256 | ||
++ lib.optional withGui "QT_PLUGIN_PATH=${qtbase}/${qtbase.qtPluginPrefix}"; | ||
|
||
enableParallelBuilding = true; | ||
|
||
meta = with lib; { | ||
description = "Sequentia is a Bitcoin sidechain dedicated to asset tokenization and decentralized exchanges"; | ||
homepage = "https://www.github.com/SequentiaSEQ/SEQ-Core-Elements"; | ||
maintainers = []; | ||
license = licenses.mit; | ||
platforms = platforms.unix; | ||
}; | ||
} | ||
let pkgs = import ./pkgs.nix; in | ||
pkgs.sequentia |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
let | ||
let | ||
pkgs = import ./pkgs.nix; | ||
sequentia = pkgs.callPackage ./default.nix {}; | ||
sequentia = pkgs.sequentia; | ||
in pkgs.mkShell { | ||
inputsFrom = [ | ||
sequentia | ||
]; | ||
} | ||
} |