Skip to content
This repository has been archived by the owner on Jun 30, 2024. It is now read-only.

How can I compile the code #1

Closed
AryanSethi opened this issue Jun 3, 2021 · 2 comments
Closed

How can I compile the code #1

AryanSethi opened this issue Jun 3, 2021 · 2 comments
Assignees
Labels
documentation Improvements or additions to documentation good first issue Good for newcomers question Further information is requested

Comments

@AryanSethi
Copy link

I'm relatively new to C++ dev. How can I compile the code on my own PC ?

@mircea-pavel-anton
Copy link
Owner

If you're using a Linux based system, then you need to make sure you have the following packages installed:

  • the g++ compiler itself, in order to compile the code
  • gnu make in order to utilize the provided makefile
  • sfml in order to have access to the graphics library used

On a Debian based system, the command would look something like this:

sudo apt install g++ make libsfml-dev -y

Once you have these installed, clone the repo, and in the root of the project (in the same directory where the Makefile is), you have a few options:

  1. run make build-debug which will compile the project with the debug directives
    These directives enable features such as:
    • a performance monitoring tool that will save the time taken in microseconds that the program spent in each function in a .csv file
    • rendering the target tile of each ghost
  2. run make build-release which will compile the project without the debug directives
    Without the debug directives, you will be looking at the program stripped down of the previously mentioned features.

If you're using a windows based systems, it'll be a bit more tricky. You have to install MinGW to get the g++ compiler and download and install SFML from the official site. Then, you have to manually extract the contents of the makefile and run them manually.

@mircea-pavel-anton
Copy link
Owner

I will be adding soon a CONTRIBUTING.md file which will detail the steps mentioned above. Thank you for the heads up!

@mircea-pavel-anton mircea-pavel-anton added documentation Improvements or additions to documentation good first issue Good for newcomers question Further information is requested labels Jun 3, 2021
@mircea-pavel-anton mircea-pavel-anton self-assigned this Jun 3, 2021
@mircea-pavel-anton mircea-pavel-anton pinned this issue Jun 3, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Improvements or additions to documentation good first issue Good for newcomers question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants