nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 bundlerEnv,
4 bundlerUpdateScript,
5 defaultGemConfig,
6 ronin,
7 testers,
8 yasm,
9}:
10
11bundlerEnv rec {
12 name = "ronin";
13 version = "2.1.1";
14 gemdir = ./.;
15
16 gemConfig = defaultGemConfig // {
17 ronin-code-asm = attrs: {
18 dontBuild = false;
19 postPatch = ''
20 substituteInPlace lib/ronin/code/asm/program.rb \
21 --replace "YASM::Command.run(" "YASM::Command.run(
22 command_path: '${yasm}/bin/yasm',"
23 '';
24 };
25 };
26
27 postBuild = ''
28 shopt -s extglob
29 rm $out/bin/!(ronin*)
30 '';
31
32 passthru.updateScript = bundlerUpdateScript "ronin";
33
34 passthru.tests.version = testers.testVersion {
35 package = ronin;
36 command = "ronin --version";
37 version = "ronin ${version}";
38 };
39
40 meta = with lib; {
41 description = "Free and Open Source Ruby toolkit for security research and development";
42 homepage = "https://ronin-rb.dev";
43 license = licenses.gpl3Plus;
44 maintainers = with maintainers; [ Ch1keen ];
45 };
46}