| @ -0,0 +1,20 @@ | |||||
| # Builder project template | |||||
| This is a project template to be used with [GNOME Builder](https://raw.githubusercontent.com/jubalh/raymario/master/meson.build). | |||||
| We use the [meson](https://raw.githubusercontent.com/jubalh/raymario/master/meson.build) build system here. | |||||
| We can compile our project via the command line: | |||||
| ``` | |||||
| meson build | |||||
| cd build | |||||
| ninja | |||||
| ninja install | |||||
| ``` | |||||
| Or can simply click on the `meson.build` file to open it with Builder. | |||||
| Alternatively you can open Builder first and click on the `open` button and the left top. | |||||
| We added comments to the file to give you an idea which values you should edit. | |||||
| For a full overview of options please check the [meson manual](http://mesonbuild.com/Manual.html). | |||||
| In the provided file we assume that the build file is located at the root folder of your project, and that all your sources are in a `src` subfolder. | |||||
| @ -0,0 +1,27 @@ | |||||
| # This file should be in the main folder of your project | |||||
| # Replace 'projectname' with the name of your project | |||||
| # Replace '1.0' with its version | |||||
| project('projectname', 'c', version: '1.0', | |||||
| meson_version: '>= 0.39.1') | |||||
| # We want a C Compiler to be present | |||||
| cc = meson.get_compiler('c') | |||||
| # Find dependencies | |||||
| glfw_dep = dependency('glfw3') | |||||
| gl_dep = dependency('gl') | |||||
| openal_dep = dependency('openal') | |||||
| m_dep = cc.find_library('m', required : false) | |||||
| raylib_dep = cc.find_library('raylib', required : false) | |||||
| # List your source files here | |||||
| source_c = [ | |||||
| 'src/main.c', | |||||
| ] | |||||
| # Build executable | |||||
| projectname = executable('projectname', | |||||
| source_c, | |||||
| dependencies : [ raylib_dep, glfw_dep, gl_dep, openal_dep, m_dep ], | |||||
| install : true) | |||||