mirror of
https://github.com/rizinorg/cutter.git
synced 2024-12-18 19:06:10 +00:00
Update rizin & translation submodules (#3194)
* Fix plugins paths for windows builds due recent changes in rizin * Disable openssl support for yara win * Disable use_sys_yara in linux/osx/win builds
This commit is contained in:
parent
44917603fa
commit
4742003ff4
2
dist/CMakeLists.txt
vendored
2
dist/CMakeLists.txt
vendored
@ -7,7 +7,7 @@ unset(RZ_GHIDRA_PREFIX_PATH)
|
|||||||
|
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
set(CPACK_GENERATOR "ZIP")
|
set(CPACK_GENERATOR "ZIP")
|
||||||
set(RIZIN_INSTALL_PLUGDIR "lib/plugins")
|
set(RIZIN_INSTALL_PLUGDIR "lib/rizin/plugins")
|
||||||
|
|
||||||
if (CUTTER_PACKAGE_DEPENDENCIES)
|
if (CUTTER_PACKAGE_DEPENDENCIES)
|
||||||
if (CUTTER_ENABLE_PYTHON)
|
if (CUTTER_ENABLE_PYTHON)
|
||||||
|
7
dist/bundle_jsdec.ps1
vendored
7
dist/bundle_jsdec.ps1
vendored
@ -5,12 +5,13 @@ if (-not (Test-Path -Path 'jsdec' -PathType Container)) {
|
|||||||
git clone https://github.com/rizinorg/jsdec.git --depth 1 --branch master
|
git clone https://github.com/rizinorg/jsdec.git --depth 1 --branch master
|
||||||
}
|
}
|
||||||
cd jsdec
|
cd jsdec
|
||||||
& meson.exe --buildtype=release -Dc_args=-DDUK_USE_DATE_NOW_WINDOWS -Djsc_folder=".." --prefix=$dist p build
|
& meson.exe --buildtype=release -Dc_args=-DDUK_USE_DATE_NOW_WINDOWS -Djsc_folder=".." --prefix="$dist" p build
|
||||||
ninja -C build install
|
ninja -C build install
|
||||||
$ErrorActionPreference = 'Stop'
|
$ErrorActionPreference = 'Stop'
|
||||||
$pathdll = "$dist\lib\plugins\core_pdd.dll"
|
$pathdll = "$dist\lib\rizin\plugins\core_pdd.dll"
|
||||||
if(![System.IO.File]::Exists($pathdll)) {
|
if(![System.IO.File]::Exists($pathdll)) {
|
||||||
type build\meson-logs\meson-log.txt
|
type build\meson-logs\meson-log.txt
|
||||||
|
ls "$dist\lib\rizin\plugins\"
|
||||||
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
||||||
}
|
}
|
||||||
Remove-Item -Recurse -Force $dist\lib\plugins\core_pdd.lib
|
Remove-Item -Recurse -Force "$dist\lib\rizin\plugins\core_pdd.lib"
|
||||||
|
6
dist/bundle_rz_libswift.ps1
vendored
6
dist/bundle_rz_libswift.ps1
vendored
@ -7,10 +7,10 @@ if (-not (Test-Path -Path 'libswift' -PathType Container)) {
|
|||||||
cd libswift
|
cd libswift
|
||||||
& meson.exe --buildtype=release --prefix=$dist build
|
& meson.exe --buildtype=release --prefix=$dist build
|
||||||
ninja -C build install
|
ninja -C build install
|
||||||
$pathdll = "$dist/lib/plugins/swift.dll"
|
$pathdll = "$dist\lib\rizin\plugins\swift.dll"
|
||||||
if(![System.IO.File]::Exists($pathdll)) {
|
if(![System.IO.File]::Exists($pathdll)) {
|
||||||
type build/meson-logs/meson-log.txt
|
type build/meson-logs/meson-log.txt
|
||||||
ls "$dist/lib/plugins/"
|
ls "$dist\lib\rizin\plugins\"
|
||||||
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
||||||
}
|
}
|
||||||
Remove-Item -Recurse -Force $dist/lib/plugins/swift.lib
|
Remove-Item -Recurse -Force "$dist\lib\rizin\plugins\swift.lib"
|
||||||
|
8
dist/bundle_rz_libyara.ps1
vendored
8
dist/bundle_rz_libyara.ps1
vendored
@ -8,15 +8,15 @@ if (-not (Test-Path -Path 'rz_libyara' -PathType Container)) {
|
|||||||
git -C rz_libyara submodule update
|
git -C rz_libyara submodule update
|
||||||
}
|
}
|
||||||
cd rz_libyara
|
cd rz_libyara
|
||||||
& meson.exe --buildtype=release --prefix=$dist build
|
& meson.exe --buildtype=release --prefix=$dist -Duse_sys_yara=disabled -Denable_openssl=false build
|
||||||
ninja -C build install
|
ninja -C build install
|
||||||
$pathdll = "$dist/lib/plugins/rz_yara.dll"
|
$pathdll = "$dist\lib\rizin\plugins\rz_yara.dll"
|
||||||
if(![System.IO.File]::Exists($pathdll)) {
|
if(![System.IO.File]::Exists($pathdll)) {
|
||||||
type build/meson-logs/meson-log.txt
|
type build/meson-logs/meson-log.txt
|
||||||
ls "$dist/lib/plugins/"
|
ls "$dist\lib\rizin\plugins\"
|
||||||
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
||||||
}
|
}
|
||||||
Remove-Item -Recurse -Force $dist/lib/plugins/rz_yara.lib
|
Remove-Item -Recurse -Force "$dist\lib\rizin\plugins\rz_yara.lib"
|
||||||
|
|
||||||
cd cutter-plugin
|
cd cutter-plugin
|
||||||
mkdir build
|
mkdir build
|
||||||
|
6
dist/bundle_rz_silhouette.ps1
vendored
6
dist/bundle_rz_silhouette.ps1
vendored
@ -8,10 +8,10 @@ if (-not (Test-Path -Path 'rz-silhouette' -PathType Container)) {
|
|||||||
cd rz-silhouette
|
cd rz-silhouette
|
||||||
& meson.exe --buildtype=release --prefix=$dist build
|
& meson.exe --buildtype=release --prefix=$dist build
|
||||||
ninja -C build install
|
ninja -C build install
|
||||||
$pathdll = "$dist/lib/plugins/rz_silhouette.dll"
|
$pathdll = "$dist\lib\rizin\plugins\rz_silhouette.dll"
|
||||||
if(![System.IO.File]::Exists($pathdll)) {
|
if(![System.IO.File]::Exists($pathdll)) {
|
||||||
type build/meson-logs/meson-log.txt
|
type build/meson-logs/meson-log.txt
|
||||||
ls "$dist/lib/plugins/"
|
ls "$dist\lib\rizin\plugins\"
|
||||||
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
throw (New-Object System.IO.FileNotFoundException("File not found: $pathdll", $pathdll))
|
||||||
}
|
}
|
||||||
Remove-Item -Recurse -Force $dist/lib/plugins/rz_silhouette.lib
|
Remove-Item -Recurse -Force "$dist\lib\rizin\plugins\rz_silhouette.lib"
|
||||||
|
2
rizin
2
rizin
@ -1 +1 @@
|
|||||||
Subproject commit 9ab709bc34843f04ffde3b63322c809596123e77
|
Subproject commit 9c6feafd4733903fca0cdad50b3bd213ab2b6228
|
@ -15,7 +15,7 @@ fi
|
|||||||
|
|
||||||
cd rz_libyara
|
cd rz_libyara
|
||||||
|
|
||||||
meson --buildtype=release --pkg-config-path="$INSTALL_PREFIX/lib/pkgconfig" --prefix="$INSTALL_PREFIX" build
|
meson --buildtype=release --pkg-config-path="$INSTALL_PREFIX/lib/pkgconfig" --prefix="$INSTALL_PREFIX" -Duse_sys_yara=disabled build
|
||||||
ninja -C build install
|
ninja -C build install
|
||||||
|
|
||||||
cd cutter-plugin
|
cd cutter-plugin
|
||||||
|
@ -33,9 +33,9 @@
|
|||||||
// has RZ_GITTAP defined and uses it in rz_core_version().
|
// has RZ_GITTAP defined and uses it in rz_core_version().
|
||||||
// After that, RZ_GITTAP is not defined anymore and RZ_VERSION is used.
|
// After that, RZ_GITTAP is not defined anymore and RZ_VERSION is used.
|
||||||
#ifdef RZ_GITTAP
|
#ifdef RZ_GITTAP
|
||||||
#define CUTTER_COMPILE_TIME_RZ_VERSION "" RZ_GITTAP
|
# define CUTTER_COMPILE_TIME_RZ_VERSION "" RZ_GITTAP
|
||||||
#else
|
#else
|
||||||
#define CUTTER_COMPILE_TIME_RZ_VERSION "" RZ_VERSION
|
# define CUTTER_COMPILE_TIME_RZ_VERSION "" RZ_VERSION
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
CutterApplication::CutterApplication(int &argc, char **argv) : QApplication(argc, argv)
|
CutterApplication::CutterApplication(int &argc, char **argv) : QApplication(argc, argv)
|
||||||
@ -162,7 +162,8 @@ CutterApplication::CutterApplication(int &argc, char **argv) : QApplication(argc
|
|||||||
appdir.cdUp(); // appdir
|
appdir.cdUp(); // appdir
|
||||||
|
|
||||||
auto sleighHome = appdir;
|
auto sleighHome = appdir;
|
||||||
sleighHome.cd("lib/rizin/plugins/rz_ghidra_sleigh/"); // appdir/lib/rizin/plugins/rz_ghidra_sleigh/
|
// appdir/lib/rizin/plugins/rz_ghidra_sleigh/
|
||||||
|
sleighHome.cd("lib/rizin/plugins/rz_ghidra_sleigh/");
|
||||||
Core()->setConfig("ghidra.sleighhome", sleighHome.absolutePath());
|
Core()->setConfig("ghidra.sleighhome", sleighHome.absolutePath());
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -174,8 +175,8 @@ CutterApplication::CutterApplication(int &argc, char **argv) : QApplication(argc
|
|||||||
rzprefix.cd("Resources"); // Contents/Resources/
|
rzprefix.cd("Resources"); // Contents/Resources/
|
||||||
|
|
||||||
auto sleighHome = rzprefix;
|
auto sleighHome = rzprefix;
|
||||||
sleighHome.cd(
|
// Contents/Resources/lib/rizin/plugins/rz_ghidra_sleigh
|
||||||
"lib/rizin/plugins/rz_ghidra_sleigh"); // Contents/Resources/lib/rizin/plugins/rz_ghidra_sleigh
|
sleighHome.cd("lib/rizin/plugins/rz_ghidra_sleigh");
|
||||||
Core()->setConfig("ghidra.sleighhome", sleighHome.absolutePath());
|
Core()->setConfig("ghidra.sleighhome", sleighHome.absolutePath());
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
@ -183,7 +184,7 @@ CutterApplication::CutterApplication(int &argc, char **argv) : QApplication(argc
|
|||||||
#if defined(Q_OS_WIN) && defined(CUTTER_ENABLE_PACKAGING)
|
#if defined(Q_OS_WIN) && defined(CUTTER_ENABLE_PACKAGING)
|
||||||
{
|
{
|
||||||
auto sleighHome = QDir(QCoreApplication::applicationDirPath());
|
auto sleighHome = QDir(QCoreApplication::applicationDirPath());
|
||||||
sleighHome.cd("lib/plugins/rz_ghidra_sleigh");
|
sleighHome.cd("lib/rizin/plugins/rz_ghidra_sleigh");
|
||||||
Core()->setConfig("ghidra.sleighhome", sleighHome.absolutePath());
|
Core()->setConfig("ghidra.sleighhome", sleighHome.absolutePath());
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -3084,8 +3084,6 @@ QList<ImportDescription> CutterCore::getAllImports()
|
|||||||
RzBinImport *import;
|
RzBinImport *import;
|
||||||
RzListIter *iter;
|
RzListIter *iter;
|
||||||
bool va = core->io->va || core->bin->is_debugger;
|
bool va = core->io->va || core->bin->is_debugger;
|
||||||
int bin_demangle = getConfigi("bin.demangle");
|
|
||||||
int keep_lib = getConfigi("bin.demangle.libs");
|
|
||||||
CutterRzListForeach (imports, iter, RzBinImport, import) {
|
CutterRzListForeach (imports, iter, RzBinImport, import) {
|
||||||
if (RZ_STR_ISEMPTY(import->name)) {
|
if (RZ_STR_ISEMPTY(import->name)) {
|
||||||
continue;
|
continue;
|
||||||
@ -3099,13 +3097,6 @@ QList<ImportDescription> CutterCore::getAllImports()
|
|||||||
if (RZ_STR_ISNOTEMPTY(import->classname)) {
|
if (RZ_STR_ISNOTEMPTY(import->classname)) {
|
||||||
name = QString("%1.%2").arg(import->classname, import->name);
|
name = QString("%1.%2").arg(import->classname, import->name);
|
||||||
}
|
}
|
||||||
if (bin_demangle) {
|
|
||||||
char *dname = rz_bin_demangle(bf, NULL, name.toUtf8().constData(),
|
|
||||||
importDescription.plt, keep_lib);
|
|
||||||
if (dname) {
|
|
||||||
name = fromOwnedCharPtr(dname);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (core->bin->prefix) {
|
if (core->bin->prefix) {
|
||||||
name = QString("%1.%2").arg(core->bin->prefix, name);
|
name = QString("%1.%2").arg(core->bin->prefix, name);
|
||||||
}
|
}
|
||||||
@ -3135,7 +3126,6 @@ QList<ExportDescription> CutterCore::getAllExports()
|
|||||||
return {};
|
return {};
|
||||||
}
|
}
|
||||||
|
|
||||||
QString lang = getConfigi("bin.demangle") ? getConfig("bin.lang") : "";
|
|
||||||
bool va = core->io->va || core->bin->is_debugger;
|
bool va = core->io->va || core->bin->is_debugger;
|
||||||
|
|
||||||
QList<ExportDescription> ret;
|
QList<ExportDescription> ret;
|
||||||
@ -3145,7 +3135,7 @@ QList<ExportDescription> CutterCore::getAllExports()
|
|||||||
}
|
}
|
||||||
|
|
||||||
RzBinSymNames sn = {};
|
RzBinSymNames sn = {};
|
||||||
rz_core_sym_name_init(core, &sn, symbol, lang.isEmpty() ? NULL : lang.toUtf8().constData());
|
rz_core_sym_name_init(&sn, symbol);
|
||||||
|
|
||||||
ExportDescription exportDescription;
|
ExportDescription exportDescription;
|
||||||
exportDescription.vaddr = rva(bf->o, symbol->paddr, symbol->vaddr, va);
|
exportDescription.vaddr = rva(bf->o, symbol->paddr, symbol->vaddr, va);
|
||||||
@ -3543,19 +3533,18 @@ QList<BinClassDescription> CutterCore::getAllClassesFromBin()
|
|||||||
RzListIter *iter, *iter2, *iter3;
|
RzListIter *iter, *iter2, *iter3;
|
||||||
RzBinClass *c;
|
RzBinClass *c;
|
||||||
RzBinSymbol *sym;
|
RzBinSymbol *sym;
|
||||||
RzBinField *f;
|
RzBinClassField *f;
|
||||||
CutterRzListForeach (cs, iter, RzBinClass, c) {
|
CutterRzListForeach (cs, iter, RzBinClass, c) {
|
||||||
BinClassDescription classDescription;
|
BinClassDescription classDescription;
|
||||||
classDescription.name = c->name;
|
classDescription.name = c->name;
|
||||||
classDescription.addr = c->addr;
|
classDescription.addr = c->addr;
|
||||||
classDescription.index = c->index;
|
|
||||||
CutterRzListForeach (c->methods, iter2, RzBinSymbol, sym) {
|
CutterRzListForeach (c->methods, iter2, RzBinSymbol, sym) {
|
||||||
BinClassMethodDescription methodDescription;
|
BinClassMethodDescription methodDescription;
|
||||||
methodDescription.name = sym->name;
|
methodDescription.name = sym->name;
|
||||||
methodDescription.addr = sym->vaddr;
|
methodDescription.addr = sym->vaddr;
|
||||||
classDescription.methods << methodDescription;
|
classDescription.methods << methodDescription;
|
||||||
}
|
}
|
||||||
CutterRzListForeach (c->fields, iter3, RzBinField, f) {
|
CutterRzListForeach (c->fields, iter3, RzBinClassField, f) {
|
||||||
BinClassFieldDescription fieldDescription;
|
BinClassFieldDescription fieldDescription;
|
||||||
fieldDescription.name = f->name;
|
fieldDescription.name = f->name;
|
||||||
fieldDescription.addr = f->vaddr;
|
fieldDescription.addr = f->vaddr;
|
||||||
@ -3591,7 +3580,6 @@ QList<BinClassDescription> CutterCore::getAllClassesFromFlags()
|
|||||||
}
|
}
|
||||||
desc->name = match.captured(1);
|
desc->name = match.captured(1);
|
||||||
desc->addr = item.offset;
|
desc->addr = item.offset;
|
||||||
desc->index = RVA_INVALID;
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3605,7 +3593,6 @@ QList<BinClassDescription> CutterCore::getAllClassesFromFlags()
|
|||||||
BinClassDescription cls;
|
BinClassDescription cls;
|
||||||
cls.name = tr("Unknown (%1)").arg(className);
|
cls.name = tr("Unknown (%1)").arg(className);
|
||||||
cls.addr = RVA_INVALID;
|
cls.addr = RVA_INVALID;
|
||||||
cls.index = 0;
|
|
||||||
ret << cls;
|
ret << cls;
|
||||||
classDesc = &ret.last();
|
classDesc = &ret.last();
|
||||||
classesCache[className] = classDesc;
|
classesCache[className] = classDesc;
|
||||||
|
@ -239,7 +239,6 @@ struct BinClassDescription
|
|||||||
QString name;
|
QString name;
|
||||||
RVA addr = RVA_INVALID;
|
RVA addr = RVA_INVALID;
|
||||||
RVA vtableAddr = RVA_INVALID;
|
RVA vtableAddr = RVA_INVALID;
|
||||||
ut64 index = 0;
|
|
||||||
QList<BinClassBaseClassDescription> baseClasses;
|
QList<BinClassBaseClassDescription> baseClasses;
|
||||||
QList<BinClassMethodDescription> methods;
|
QList<BinClassMethodDescription> methods;
|
||||||
QList<BinClassFieldDescription> fields;
|
QList<BinClassFieldDescription> fields;
|
||||||
|
@ -1 +1 @@
|
|||||||
Subproject commit e8fc5ca1acd70fd82a2ac9ac02b0261e57703250
|
Subproject commit 5ac7217b12623c7bfd0378380f923cf694ccee22
|
@ -13,7 +13,7 @@ ComboQuickFilterView::ComboQuickFilterView(QWidget *parent)
|
|||||||
[this]() { emit filterTextChanged(ui->lineEdit->text()); });
|
[this]() { emit filterTextChanged(ui->lineEdit->text()); });
|
||||||
|
|
||||||
connect(ui->lineEdit, &QLineEdit::textChanged, this,
|
connect(ui->lineEdit, &QLineEdit::textChanged, this,
|
||||||
[this](const QString &text) { debounceTimer->start(150); });
|
[this]() { debounceTimer->start(150); });
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboQuickFilterView::~ComboQuickFilterView()
|
ComboQuickFilterView::~ComboQuickFilterView()
|
||||||
|
@ -16,7 +16,7 @@ QuickFilterView::QuickFilterView(QWidget *parent, bool defaultOn)
|
|||||||
[this]() { emit filterTextChanged(ui->filterLineEdit->text()); });
|
[this]() { emit filterTextChanged(ui->filterLineEdit->text()); });
|
||||||
|
|
||||||
connect(ui->filterLineEdit, &QLineEdit::textChanged, this,
|
connect(ui->filterLineEdit, &QLineEdit::textChanged, this,
|
||||||
[this](const QString &text) { debounceTimer->start(150); });
|
[this]() { debounceTimer->start(150); });
|
||||||
|
|
||||||
if (!defaultOn) {
|
if (!defaultOn) {
|
||||||
closeFilter();
|
closeFilter();
|
||||||
|
Loading…
Reference in New Issue
Block a user