3 releases (breaking)

Uses old Rust 2015

0.3.0 Dec 22, 2018
0.2.0 Dec 19, 2018
0.1.0 Dec 9, 2018

#1769 in Command line utilities

36 downloads per month
Used in p3dtxt

GPL-2.0-or-later

100KB
2.5K SLoC

armake2

Successor to armake written in Rust for maintainability and memory safety, aiming to provide the same features except for the custom P3D binarization, which was never finished.

Status: PAA commands not implemented, some options not implemented, testing.

Changes since armake

  • New v3 signatures
  • Signature verification
  • Seperate preprocess command
  • Seperate pack command for non-binarized PBOs instead of build -p
  • Configs are now rapified via the rapify command
  • Improved config parser errors
  • Automatic warning truncation to prevent spam

Performance

Performance should be equal or better than armake depending on modification makeup and environment. More is done in-memory, reducing disk I/O at the expense of memory usage. Especially during binarization, less copies are performed, resulting in much faster builds for asset-heavy modifications or users without SSDs.

BWMod build benchmarks

armake1:

Time (mean ± σ):     676.463 s ± 17.609 s    [User: 1.5 ms, System: 3.9 ms]
Range (min … max):   653.793 s … 706.619 s

armake2:

Time (mean ± σ):     434.666 s ±  1.109 s    [User: 0.0 ms, System: 4.1 ms]
Range (min … max):   433.415 s … 435.526 s

Speedup: 1.56

ACE3 build benchmarks

da7bb856f

armake1:

Time (mean ± σ):     110.083 s ±  2.772 s    [User: 4.9 ms, System: 16.8 ms]
Range (min … max):   108.270 s … 113.274 s

armake2:

Time (mean ± σ):     98.190 s ±  0.452 s    [User: 0.0 ms, System: 13.6 ms]
Range (min … max):   97.767 s … 98.666 s

Speedup: 1.12

(all benchmarks performed with 4 threads on a 4 core VM on an i5-8600K)

Building

The build requires cargo, Rust's package manager and the OpenSSL development libraries. To compile and run, use:

cargo run

To build a release, use:

cargo build --release

On Windows, the easiest way to get compilation and static linking of OpenSSL to work is to download precompiled OpenSSL binaries (non-light, 64bit) and set the following environment variables:

  • OPENSSL_DIR=C:\OpenSSL-WIN64
  • OPENSSL_STATIC=1
  • OPENSSL_LIBS=libssl_static:libcrypto_static

Usage

armake2

Usage:
    armake2 rapify [-v] [-f] [-w <wname>]... [-i <includefolder>]... [<source> [<target>]]
    armake2 preprocess [-v] [-f] [-w <wname>]... [-i <includefolder>]... [<source> [<target>]]
    armake2 derapify [-v] [-f] [-d <indentation>] [<source> [<target>]]
    armake2 binarize [-v] [-f] [-w <wname>]... <source> <target>
    armake2 build [-v] [-f] [-w <wname>]... [-i <includefolder>]... [-x <excludepattern>]... [-e <headerext>]... [-k <privatekey>] [-s <signature>] <sourcefolder> [<target>]
    armake2 pack [-v] [-f] <sourcefolder> [<target>]
    armake2 inspect [-v] [<source>]
    armake2 unpack [-v] [-f] <source> <targetfolder>
    armake2 cat [-v] <source> <filename> [<target>]
    armake2 keygen [-v] [-f] <keyname>
    armake2 sign [-v] [-f] [-s <signature>] [--v2] <privatekey> <pbo> [<signature>]
    armake2 verify [-v] <publickey> <pbo> [<signature>]
    armake2 paa2img [-v] [-f] [<source> [<target>]]
    armake2 img2paa [-v] [-f] [-z] [-t <paatype>] [<source> [<target>]]
    armake2 (-h | --help)
    armake2 --version

See armake2 --help for more.

Dependencies

~6–17MB
~203K SLoC