From a52cb577a9d9207f1d0cb28ee1f42cc459d66989 Mon Sep 17 00:00:00 2001 From: adany292 <adany292@student.liu.se> Date: Sun, 8 Dec 2024 21:11:21 +0100 Subject: [PATCH] README updated with new build instructions --- README.md | 44 ++++++++++++++++++++++++-------------------- 1 file changed, 24 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 6b4104a..39c7461 100644 --- a/README.md +++ b/README.md @@ -23,42 +23,46 @@ These values are adjustable within the code and can be fine-tuned based on desir * **CUDA Toolkit** – for CUDA language support, GPU parallelization, and CUDA/OpenGL interoperability * **GLEW** – for OpenGL Extension Wrangler Library -* **freeGLUT** – for OpenGL windowing and event handling -* **GLM** – for vector and matrix math operations in OpenGL +* **GLFW** * **Thrust** – for high-performance parallel algorithms (comes with the CUDA Toolkit) +--- -### Build Instructions +## Build Instructions for Ubuntu -1. **Install Dependencies** +### **Dependencies** +Install all required dependencies using the following command: +```bash +sudo apt update && sudo apt install -y build-essential cmake libglew-dev libglfw3-dev mesa-common-dev libx11-dev +``` - On Ubuntu, you can install the required libraries using: +- **CUDA Toolkit**: Download and install [NVIDIA CUDA Toolkit](https://developer.nvidia.com/cuda-downloads). + +--- + +### **Building the Project** +1. Clone the repository and navigate to the project directory: ```bash - sudo apt update - sudo apt install -y build-essential cmake libglew-dev freeglut3-dev libglm-dev + git clone https://github.com/your_username/your_project.git + cd your_project ``` - Install the **CUDA Toolkit** from NVIDIA’s official site [here](https://developer.nvidia.com/cuda-toolkit), which includes both CUDA and Thrust libraries. - -2. **Build the Project with CMake** - Navigate to the project src folder and create a `build` folder: +2. Create a build directory: ```bash mkdir build cd build ``` - Run CMake to configure and generate the makefiles, then compile the code: +3. Configure and build the project: ```bash cmake .. make ``` - This will produce an executable named `cuda_opengl_integration` in the `build` directory. +--- - -## Run - - From the `build` directory, run the executable: - ```bash - ./cuda_opengl_integration - ``` \ No newline at end of file +### **Running the Application** +Run the application from the build directory: +```bash +./fluidSimulator +``` \ No newline at end of file -- GitLab