jonahshader / alife_cuda

Artificial life simulator using CUDA for compute
0 stars 0 forks source link

ALife CUDA

Artificial life simulation using CUDA for compute. The guide below explains how to set up the project, the necessary dependencies, and how to create both Debug and Release builds.

Dependencies

Setup

  1. Clone the repository:

    git clone https://github.com/jonahshader/alife_cuda.git
    cd alife_cuda
  2. Ensure CUDA and CMake are installed and properly set up. TODO: more details.

Building the Project

Linux

Debug Build

  1. Create a build directory for the debug configuration:

    mkdir build-debug
    cd build-debug
  2. Configure the project with CMAKE_BUILD_TYPE=Debug:

    cmake -DCMAKE_BUILD_TYPE=Debug ..
  3. Build the project:

    cmake --build .

Release Build

  1. Create a build directory for the release configuration:

    mkdir build-release
    cd build-release
  2. Configure the project with CMAKE_BUILD_TYPE=Release:

    cmake -DCMAKE_BUILD_TYPE=Release ..
  3. Build the project:

    cmake --build .

Windows

For Windows users, it's recommended to use the Visual Studio Developer Command Prompt to ensure the MSVC compiler is used.

  1. Open the Visual Studio Developer Command Prompt.

  2. Create separate directories for Debug and Release builds:

    Debug Build

    mkdir build-debug
    cd build-debug
    cmake -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Debug ..
    nmake

    Release Build

    mkdir build-release
    cd build-release
    cmake -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Release ..
    nmake

    Alternatively, you can generate Visual Studio project files using: TODO: verify. I thought a newer version of Visual Studio was needed.

    cmake -G "Visual Studio 16 2019" -A x64 ..

    Then open the generated .sln file in Visual Studio, select the configuration (Debug/Release), and build.

Additional Notes

License

Add license details here.