module battery.detect.nasm
Detect and find the nasm command.
Code Map
//! Detect and find the nasm command.
module battery.detect.nasm;
//! Used as a argument when supplying a command on the command line.
struct FromArgs
{
public:
cmd: string;
args: string[];
}
//! The result of the dection, also holds any extra arguments to get NASM
//! to output in the correct format.
struct Result
{
public:
from: string;
cmd: string;
args: string[];
}
//! Detect and find the nasm command.
fn detectFromPath(path: string, results: Result[]) bool { }
fn detectFromBatConf(batConf: BatteryConfig, result: Result) bool { }
//! Detect nasm from arguments.
fn detectFromArgs(arg: FromArgs, result: Result) bool { }
//! Add extra arguments to the command, any given args are appended after
//! the extra arguments.
fn addArgs(from: Result, arch: Arch, platform: Platform, res: Result) { }
struct FromArgs
Used as a argument when supplying a command on the command line.
struct Result
The result of the dection, also holds any extra arguments to get NASM to output in the correct format.
fn detectFromPath(path: string, results: Result[]) bool
Detect and find the nasm command.
fn detectFromArgs(arg: FromArgs, result: Result) bool
Detect nasm from arguments.
fn addArgs(from: Result, arch: Arch, platform: Platform, res: Result)
Add extra arguments to the command, any given args are appended after the extra arguments.
global log: battery.util.log.Logger
So we get the right prefix on logged messages.
fn fromPath(path: string, res: Result) bool
Search the path.Pretty print the result.
fn getFormatString(arch: Arch, platform: Platform) string
Returns the format to be outputed for this configuration.