Expand description

Find local installations of the Wolfram Language and Wolfram applications.

This crate provides functionality to find and query information about Wolfram Language applications installed on the current computer.

Use cases

  • Programs that depend on the Wolfram Language, and want to automatically use the newest version available locally.

  • Build scripts that need to locate the Wolfram LibraryLink or WSTP header files and static/dynamic library assets.

  • A program used on different computers that will automatically locate the Wolfram Language, even if it resides in a different location on each computer.

Examples

Find the default Wolfram Language installation on this computer
use wolfram_app_discovery::WolframApp;

let app = WolframApp::try_default()
    .expect("unable to locate any Wolfram apps");

println!("App location: {:?}", app.app_directory());
println!("Wolfram Language version: {}", app.wolfram_version().unwrap());
Find a local Wolfram Engine installation
use wolfram_app_discovery::{discover, WolframApp, WolframAppType};

let engine: WolframApp = discover()
    .into_iter()
    .filter(|app: &WolframApp| app.app_type() == WolframAppType::Engine)
    .next()
    .unwrap();

Modules

  • Functions for querying the locations of Wolfram development SDK resources, for use in build scripts.
  • Configuration of wolfram-app-discovery behavior.

Structs

Enums

Functions