Compare commits

..

8 Commits

Author SHA1 Message Date
Ninja3047 c711ddce7b bump ghidra in flake 2023-09-23 18:26:26 -04:00
Ninja3047 5b76dd9ed5 update flake.lock 2023-09-23 18:26:26 -04:00
Ninja3047 0f40864cec debug and asan build 2023-09-23 18:26:26 -04:00
Ninja3047 7ea4feb70e fix deprecation 2023-09-23 18:26:26 -04:00
Ninja3047 daa95e1d6b format nix 2023-09-23 18:26:26 -04:00
Ninja3047 da1b36dfb7 experimental nix flake 2023-09-23 18:17:51 -04:00
auto-updater[bot] 393adb711e Update Ghidra HEAD to commit 4561e8335 (#208)
Bump Ghidra HEAD commit 4561e8335

Changed files:

```
M	Ghidra/Features/Decompiler/src/decompile/cpp/Doxyfile
M	Ghidra/Features/Decompiler/src/decompile/cpp/architecture.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/block.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/block.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/cover.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/database.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/fspec.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/funcdata.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/heritage.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/jumptable.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/merge.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/options.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/prettyprint.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/prettyprint.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/printc.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/printc.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/printjava.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/printlanguage.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/printlanguage.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/ruleaction.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/sleigh.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/subflow.cc
M	Ghidra/Features/Decompiler/src/decompile/cpp/type.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/typeop.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/variable.hh
M	Ghidra/Features/Decompiler/src/decompile/cpp/varmap.cc
A	Ghidra/Features/Decompiler/src/decompile/datatests/boolless.xml
```

Co-authored-by: pgoodman <pgoodman@users.noreply.github.com>
2023-09-18 13:03:13 +10:00
dependabot[bot] fb4dec76cb build(deps): bump tibdex/github-app-token from 1 to 2 (#207)
Bumps [tibdex/github-app-token](https://github.com/tibdex/github-app-token) from 1 to 2.
- [Release notes](https://github.com/tibdex/github-app-token/releases)
- [Commits](https://github.com/tibdex/github-app-token/compare/v1...v2)

---
updated-dependencies:
- dependency-name: tibdex/github-app-token
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-11 16:21:32 +10:00
6 changed files with 181 additions and 3 deletions
+1
View File
@@ -0,0 +1 @@
use flake
+1 -1
View File
@@ -27,7 +27,7 @@ jobs:
# Need this to run further Actions on the newly created PR
# See here for more details https://github.com/peter-evans/create-pull-request/blob/28fa4848947e0faa7fa50647691d01477589d5e9/docs/concepts-guidelines.md#authenticating-with-github-app-generated-tokens
- uses: tibdex/github-app-token@v1
- uses: tibdex/github-app-token@v2
if: steps.head_update.outputs.did_update
id: generate-token
with:
+2
View File
@@ -4,3 +4,5 @@ build
# FetchContent Ghidra source directories
/src/ghidra*
cmake_fc_*
.direnv/
Generated
+95
View File
@@ -0,0 +1,95 @@
{
"nodes": {
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1681202837,
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1682291304,
"narHash": "sha256-VkufTQNEclnZ0HnSXxmXC2Qvtj6/3/8SyZfRyL4AllI=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "b2d51541a37678ad4e870f75326b6e68daf3b3c7",
"type": "github"
},
"original": {
"owner": "nixos",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_2": {
"locked": {
"lastModified": 1680945546,
"narHash": "sha256-8FuaH5t/aVi/pR1XxnF0qi4WwMYC+YxlfdsA0V+TEuQ=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "d9f759f2ea8d265d974a6e1259bd510ac5844c5d",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs",
"treefmt-nix": "treefmt-nix"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"treefmt-nix": {
"inputs": {
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1681486253,
"narHash": "sha256-EjiQZvXQH9tUPCyLC6lQpfGnoq4+kI9v59bDJWPicYo=",
"owner": "numtide",
"repo": "treefmt-nix",
"rev": "b25d1a3c2c7554d0462ab1dfddf2f13128638b90",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "treefmt-nix",
"type": "github"
}
}
},
"root": "root",
"version": 7
}
+80
View File
@@ -0,0 +1,80 @@
{
inputs = {
nixpkgs.url = "github:nixos/nixpkgs";
flake-utils.url = "github:numtide/flake-utils";
treefmt-nix.url = "github:numtide/treefmt-nix";
};
outputs = {
self,
nixpkgs,
flake-utils,
treefmt-nix,
}:
{
overlays.default = final: prev: {
ghidra = with final;
applyPatches {
src = fetchFromGitHub {
owner = "NationalSecurityAgency";
repo = "ghidra";
rev = "refs/tags/Ghidra_10.3.3_build";
sha256 = "sha256-KDSiZ/JwAqX6Obg9UD8ZQut01l/eMXbioJy//GluXn0=";
};
patches = [
./src/patches/stable/0001-Fix-UBSAN-errors-in-decompiler.patch
./src/patches/stable/0002-Use-stroull-instead-of-stroul-to-parse-address-offse.patch
];
};
sleigh = with final;
stdenv.mkDerivation {
name = "sleigh";
src = ./.;
nativeBuildInputs = [
cmake
ninja
git
];
buildInputs = [
ghidra
];
cmakeFlags = [
"-DFETCHCONTENT_SOURCE_DIR_GHIDRASOURCE=${ghidra}"
];
};
sleigh-debug = with final;
final.sleigh.overrideAttrs (o: {
dontStrip = true;
enableDebugging = true;
separateDebugInfo = true;
});
sleigh-asan = with final;
final.sleigh-debug.overrideAttrs (o: {
cmakeFlags = o.cmakeFlags ++ ["-DCMAKE_C_FLAGS=-fsanitize=address" "-DCMAKE_CXX_FLAGS=-fsanitize=address"];
});
};
}
// flake-utils.lib.eachDefaultSystem (
system: let
pkgs = import nixpkgs {
inherit system;
overlays = [self.overlays.default];
};
in {
packages.default = pkgs.sleigh;
devShells.default = pkgs.mkShell {
packages = with pkgs; [
sleigh-asan
clang-tools
];
};
formatter = treefmt-nix.lib.mkWrapper pkgs {
projectRootFile = ".git/config";
programs = {
alejandra.enable = true;
clang-format.enable = true;
};
};
}
);
}
+2 -2
View File
@@ -46,9 +46,9 @@ set(ghidra_patches
if("${sleigh_RELEASE_TYPE}" STREQUAL "HEAD")
# TODO: Try to remember to look at Ghidra/application.properties
# TODO: CMake only likes numeric characters in the version string....
set(ghidra_head_version "10.4")
set(ghidra_head_version "10.5")
set(ghidra_version "${ghidra_head_version}")
set(ghidra_head_git_tag "d7d6b44e296ac4a215766916d5c24e8b53b2909a")
set(ghidra_head_git_tag "4561e8335d3b62329c4afdf5a91bc6ce113b7002")
set(ghidra_git_tag "${ghidra_head_git_tag}")
set(ghidra_shallow FALSE)
set(ghidra_patches