mysimulation/docs/compiling.md
Tony Bark f9764eac17 Updated documentation
- In general, the README should be more clean and concise
- Moved building section to seperate file (doesn't include set up page)
- Added contributing section in REMADE
- Updated license section in README
- Added config file and struct for later use
2024-05-06 07:24:11 -04:00

1.2 KiB

Compiling

WARNING: This is a work in progress

Client

Compiling the client requires Zig 0.11 or later.

To simply build the client:

zig build

If you want to run and test the client:

zig build run

Libaries & Tools

Note: The setup process is outdated, and currently planned to be rewritten.

Zig Backend (Optional)

While My Simulation uses NioTSO's C headers directly, you can still compile tools that make use of them. In this case, it is recommend to use Zig's C/C++ compiler as a backend.

CC="zig cc" CXX="zig c++" cmake -B build
cd build && make -j8

On Unix-based systems, you can add it to your .bashrc or .zshrc file.

# C/C++ Linker
export CC="zig cc"
export CXX="zig c++"

Afterwards, you can pass the same commands without.

cmake -B build && cd build && make -j8

Building

At bare minium, My Simulation's C/C++ libaries require make and cmake. Generate the build files:

cd library # Or cd tools
cmake

Afterwards, comile the software:

make

Server

Coming soon!