import { CompilerCallbacks, KeymanCompiler, KeymanCompilerArtifact, KeymanCompilerArtifacts, KeymanCompilerResult } from '@keymanapp/developer-utils'; import { KmpCompilerOptions } from "./kmp-compiler.js"; /** * @public * Sources and metadata for the Windows package installer compiler */ export interface WindowsPackageInstallerSources { msiFilename: string; setupExeFilename: string; licenseFilename: string; titleImageFilename?: string; appName?: string; startDisabled: boolean; startWithConfiguration: boolean; } /** * @public * Options for the .kps Windows package installer compiler */ export interface WindowsPackageInstallerCompilerOptions extends KmpCompilerOptions { /** * Sources and metadata for the Windows package installer compiler */ sources: WindowsPackageInstallerSources; } /** * @public * Internal in-memory build artifacts from a successful compilation */ export interface WindowsPackageInstallerCompilerArtifacts extends KeymanCompilerArtifacts { /** * Binary package installer filedata and filename - installable into Keyman * desktop and mobile projects */ exe: KeymanCompilerArtifact; } /** * @public * Build artifacts from the .kps Windows package installer compiler */ export interface WindowsPackageInstallerCompilerResult extends KeymanCompilerResult { /** * Internal in-memory build artifacts from a successful compilation. Caller * can write these to disk with {@link WindowsPackageInstallerCompiler.write} */ artifacts: WindowsPackageInstallerCompilerArtifacts; } /** * @public * Compiles a .kps file to a .exe installer. The compiler does not read or write * from filesystem or network directly, but relies on callbacks for all external * IO. */ export declare class WindowsPackageInstallerCompiler implements KeymanCompiler { private kmpCompiler; private callbacks; private options; /** * Initialize the compiler. * Copies options. * @param callbacks - Callbacks for external interfaces, including message * reporting and file io * @param options - Compiler options * @returns false if initialization fails */ init(callbacks: CompilerCallbacks, options: WindowsPackageInstallerCompilerOptions): Promise; /** * Compiles a .kps file to .exe Windows package installer file. Returns an * object containing binary artifacts on success. The files are passed in by * name, and the compiler will use callbacks as passed to the * {@link WindowsPackageInstallerCompiler.init} function to read any input * files by disk. * @param infile - Path to source file. Path will be parsed to find relative * references in the .kmn file, such as icon or On Screen * Keyboard file * @param outfile - Path to output file. The file will not be written to, but * will be included in the result for use by * {@link WindowsPackageInstallerCompiler.write}. * @returns Binary artifacts on success, null on failure. */ run(inputFilename: string, outputFilename?: string): Promise; /** * Write artifacts from a successful compile to disk, via callbacks methods. * The artifacts written may include: * * - .exe file - binary Windows package installer executable file * * @param artifacts - object containing artifact binary data to write out * @returns true on success */ write(artifacts: WindowsPackageInstallerCompilerArtifacts): Promise; private buildZip; private buildSetupInf; private buildSfx; } //# sourceMappingURL=windows-package-installer-compiler.d.ts.map