diff options
| author | Mason Reed <mason@vector35.com> | 2025-04-15 22:49:05 -0400 |
|---|---|---|
| committer | Mason Reed <mason@vector35.com> | 2025-04-15 22:49:05 -0400 |
| commit | 84eecdfdfd8b972cd9fcafb35da81ed62d9698f9 (patch) | |
| tree | 5df22437916f11d22278b361a247fd554391f334 /plugins/svd/src | |
| parent | 2a2e7980cf78a96396a74e502aaefb04a25d7d1e (diff) | |
Include SVD loader in free version
Diffstat (limited to 'plugins/svd/src')
| -rw-r--r-- | plugins/svd/src/lib.rs | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/plugins/svd/src/lib.rs b/plugins/svd/src/lib.rs index aa7f372e..e59e7ab3 100644 --- a/plugins/svd/src/lib.rs +++ b/plugins/svd/src/lib.rs @@ -60,7 +60,21 @@ impl Command for LoadSVDFile { #[no_mangle] #[allow(non_snake_case)] +#[cfg(not(feature = "demo"))] pub extern "C" fn CorePluginInit() -> bool { + plugin_init(); + true +} + +#[no_mangle] +#[allow(non_snake_case)] +#[cfg(feature = "demo")] +pub extern "C" fn SVDPluginInit() -> bool { + plugin_init(); + true +} + +fn plugin_init() { Logger::new("SVD").with_level(LevelFilter::Debug).init(); binaryninja::command::register_command( @@ -107,6 +121,4 @@ pub extern "C" fn CorePluginInit() -> bool { .unwrap(); module_meta_workflow.insert("core.module.loadDebugInfo", [LOADER_ACTIVITY_NAME]); module_meta_workflow.register().unwrap(); - - true -} +}
\ No newline at end of file |
