Skip to content

Commit

Permalink
Add installation instructions for the meson build system
Browse files Browse the repository at this point in the history
  • Loading branch information
radare committed Aug 22, 2022
1 parent e342b8a commit b827e93
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,14 @@ incdirs = [
'ghidra-native/src/decompiler/',
]

res = run_command(['r2','-HR2_LIBR_PLUGINS'], capture:true)
if res.returncode() == 0
r2_plugdir = res.stdout().strip()
else
prefix = get_option('prefix')
r2_plugdir = prefix + '/lib/radare2/plugins'
endif

cpp = meson.get_compiler('cpp')
if cpp.get_id() == 'msvc'
incdirs += [
Expand Down Expand Up @@ -189,9 +197,12 @@ r2ghidra_core_plugin = library('core_r2ghidra',
r2ghidra_core_sources,
dependencies: [r_core],
override_options : ['c_std=c11', 'cpp_std=c++11'],
include_directories: r2ghidra_incdirs
include_directories: r2ghidra_incdirs,
install: true,
install_dir: r2_plugdir
)


sleighc_exe = executable('sleighc', sleighc_sources,
include_directories: r2ghidra_incdirs,
override_options : ['c_std=c11', 'cpp_std=c++11'],
Expand Down

0 comments on commit b827e93

Please sign in to comment.