Utgivning av ForgeZero 1.9.0, ett byggverktyg för C och assembler

Release of ForgeZero 1.9.0 (fz) has been published, a console build tool for projects in C, C++, and assembly languages (NASM, GAS, FASM). The tool does not require creating a Makefile or any other configuration files for basic use. The project code is written in Go and is distributed under the MIT license.

ForgeZero determines the file type and automatically selects the required backend. Each code file is compiled into an object file, after which a check for duplicate global symbols across all objects is performed, followed by linking into a single executable file. Compiled files are cached and are only rebuilt after changes to their associated code files. Optional tracking of changes in the file system and rebuilding after code file updates is possible.

Supports compilers GCC, Clang, G++, Clang++; assemblers NASM, GAS, FASM; linkers LD, GCC, Clang; archivers AR. Mandatory warnings for C and C++: "-Wall -Wextra -Werror -Wpedantic -Wshadow -Wconversion". AddressSanitizer and UndefinedBehaviorSanitizer are enabled by default (can be disabled with the flag -sanitize=false). Supported platforms include Linux, macOS, Windows (WSL2, and experimentally natively).

Key changes in version 1.9.0:

  • Added the flag "-target" , allowing for cross-compilation for arbitrary architectures when the corresponding prefix toolchain is available. fz determines the names of the compiler, linker, and archiver based on the specified identifier (e.g., "arm-linux-gnueabihf-gcc"). Any standard GNU target platforms are supported, including arm-linux-gnueabihf, aarch64-linux-gnu, and riscv64-linux-gnu.
  • Support for the LSP (Language Server Protocol) has been implemented. The flag "-compile-commands" generates a compile_commands.json file (Compilation Database) in the root of the project. This file is read by the languages servrar clangd and ccls, providing autocompletion, code navigation, and diagnostics in editors that support LSP (Neovim, VSCode, CLion, Emacs, etc.).
  • The fz command "-update" now saves the current binary file to /usr/local/bin/fz.old before installing a new version, allowing rollback to the previous version without reinstalling.
  • En bugg har Ă„tgĂ€rdats dĂ€r filer med samma grundnamn frĂ„n olika underkataloger i multidirektory-projekt överskrev varandras objektfiler. Namnen pĂ„ objektfilerna genereras nu baserat pĂ„ den fullstĂ€ndiga relativa vĂ€gen till kĂ€llfilen.
  • Interaktivt lĂ€ge "fz -shell" har implementerats för att skapa enskilda filer.
  • TesttĂ€ckning har lagts till för kommandon SplitCommand, CmdSet och CmdBuild. TesttĂ€ckningen för lĂ€nkaren har ökat frĂ„n 17 % till 60 %, och tĂ€ckningen för alla paket har överstigit 40 %.
  • En ersĂ€ttningsmekanism för CheckTool har lagts till för att testa scenarier med saknade komponenter i verktygskedjan.

Ändringar i tidigare versioner:

  • I version 1.8.0 har byggande av statiska bibliotek (-type static / -lib) implementerats, unikhet i namn pĂ„ objektfiler har sĂ€kerstĂ€llts i multidirektory-projekt, och fel relaterade till byggsystemet som involverade vĂ€gen ".." har Ă„tgĂ€rdats.
  • I version 1.7.0 har parallell kompilering (-j N, 0 - automatisk identifiering av antalet kĂ€rnor), stöd för lĂ€nkarskript (-T), ingĂ„ngsadress (-Ttext), interaktivt lĂ€ge (fz -shell), explicit val av utgĂ„ngsformat (elf32, elf64, bin), och kompilering av C++-filer (.cpp, .cc, .cxx) med samma strikta varningsflaggor som för C lagts till.
  • I version 1.6.0 har projektinitiering (fz -init, skapar .fz.yaml, .fzignore, README.md), stöd för bin-format (-format bin) för laddare och firmwares, och konfigurationsfĂ€lt för libs, flags.cc, flags.asm, flags.ld lagts till.
  • I version 1.5.0 har flera kĂ€llkataloger (source_dirs), explicita filistor (source_files), include/exclude-mallar, fĂ€lt för bibliotek för lĂ€nkaren, filen .fzignore och flerradig sammanslagning av konfigurationsfiler implementerats.

KĂ€lla: opennet.ru

Köp pĂ„litlig webbhotell med DDoS-skydd, VPS VDS-servrar đŸ”„ Köp pĂ„litlig webbhotell med DDoS-skydd, VPS VDS-servrar | ProHoster