Files
old-core/README.md

69 lines
1.4 KiB
Markdown
Raw Normal View History

2018-10-28 15:06:27 +01:00
# Basic C SDL project
2018-10-28 18:46:41 +01:00
This project is a basic C [SDL][] project that uses [CMake][] as a build system.
2018-10-28 15:06:27 +01:00
2018-10-28 15:08:50 +01:00
## Dependencies
2018-10-28 18:46:41 +01:00
- [Git][]
2018-10-28 15:08:50 +01:00
- C Compiler (gcc, ...)
2018-10-28 18:46:41 +01:00
- [CMake][]
- [SDL2][SDL] library
2018-10-28 15:08:50 +01:00
**On Debian/Ubuntu based distributions, use the following command:**
```sh
sudo apt install git-core build-essential pkg-config cmake cmake-data libsdl2-dev
```
**Optional packages:**
2018-10-28 18:46:41 +01:00
- [SDL2_image][] library
- [SDL2_ttf][] library
- [SDL2_gfx][] library
2018-10-28 15:08:50 +01:00
```sh
sudo apt install libsdl2-image-dev libsdl2-ttf-dev libsdl2-gfx-dev
```
2018-10-28 15:09:31 +01:00
## Build instructions
```sh
# Clone this repo
2018-11-07 22:01:39 +01:00
git clone https://gitlab.com/aminosbh/basic-c-sdl-project.git
2018-10-28 15:09:31 +01:00
cd basic-c-sdl-project
# Create a build folder
mkdir build
cd build
# Build
cmake ..
make
# Run
./basic-c-sdl-project
```
***Note:*** To use SDL2_image, SDL2_ttf or SDL2_gfx, you should uncomment
some instructions in the CMakeLists.txt file and re-execute `cmake ..` and `make`
2018-10-28 18:50:35 +01:00
### Open the project with an IDE under Linux
2018-11-20 08:28:27 +01:00
See [IDE_USAGE.md](IDE_USAGE.md) for details.
2018-10-28 18:54:03 +01:00
2018-10-28 15:06:27 +01:00
## License
2018-11-08 21:36:47 +01:00
Author: Amine B. Hassouna [@aminosbh](https://gitlab.com/aminosbh)
2018-10-28 15:06:27 +01:00
This project is distributed under the terms of the MIT license
[<LICENSE>](LICENSE).
2018-10-27 21:31:08 +00:00
2018-10-28 18:46:41 +01:00
[SDL]: https://www.libsdl.org
[CMake]: https://cmake.org
[Git]: https://git-scm.com
[SDL2_image]: https://www.libsdl.org/projects/SDL_image
[SDL2_ttf]: https://www.libsdl.org/projects/SDL_ttf
[SDL2_gfx]: http://www.ferzkopp.net/wordpress/2016/01/02/sdl_gfx-sdl2_gfx