Skip to main content

Build System & Compilation

Overview

The build system handles the compilation of source code into executable binaries. It manages temporary file creation, compiler invocation (gcc / rustc), and cleanup.

Requirements Specification

IDFeature NameDescriptionImplementation Detail
TRQ-BLD-001Temp Directory BuildAll compilation occurs in the system %TEMP% directory to avoid permission issues and Antivirus locking.Path: app.getPath('temp') + timestamped filename.
TRQ-BLD-002C CompilationCompiles C code using GCC with console subsystem support.Command: gcc "file.c" -o "out.exe" -mconsole.
TRQ-BLD-003Rust CompilationCompiles Rust code using the Rust compiler with debug info.Command: rustc "file.rs" -g -o "out.exe".
TRQ-BLD-004File Locking PreventionThe system generates unique filenames (trinova_build_{timestamp}.exe) for every build to prevent EBUSY or Permission Denied errors if a previous build is still running.Implemented in getBuildPath.