Initial commit of the new version of this starter project.

master
Zed A. Shaw 1 week ago
parent d5578be562
commit cb9d22078d
  1. 11
      .gitignore
  2. 1
      .vimrc_proj
  3. 19
      LICENSE
  4. 44
      Makefile
  5. 64
      README.md
  6. BIN
      assets/click.mp3
  7. BIN
      assets/sprite.png
  8. 47
      dbc.cpp
  9. 50
      dbc.hpp
  10. 157
      main.cpp
  11. 99
      meson.build
  12. 7
      scripts/reset_build.ps1
  13. 10
      scripts/reset_build.sh
  14. 6
      tests/example.cpp
  15. 12
      wraps/box2d.wrap
  16. 11
      wraps/catch2.wrap
  17. 13
      wraps/flac.wrap
  18. 13
      wraps/fmt.wrap
  19. 11
      wraps/freetype2.wrap
  20. 13
      wraps/libpng.wrap
  21. 11
      wraps/nlohmann_json.wrap
  22. 13
      wraps/ogg.wrap
  23. 14
      wraps/sfml.wrap
  24. 14
      wraps/vorbis.wrap

11
.gitignore vendored

@ -0,0 +1,11 @@
.*.sw*
.DS_Store
*.sqlite3
*.sqlite3-wal
*.sqlite3-shm
debug
coverage/
.coverage
builddir
subprojects
*.exe

@ -0,0 +1 @@
set makeprg=make\ -f\ ../Makefile\ build

@ -1,9 +1,16 @@
MIT License
MIT No Attribution
Copyright (c) <year> <copyright holders>
Copyright 2024 Zed A. Shaw
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
Permission is hereby granted, free of charge, to any person obtaining a copy of this
software and associated documentation files (the "Software"), to deal in the Software
without restriction, including without limitation the rights to use, copy, modify,
merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so.
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

@ -0,0 +1,44 @@
ROOT_DIR := $(dir $(realpath $(lastword $(MAKEFILE_LIST))))
all: build test
reset:
ifeq '$(OS)' 'Windows_NT'
powershell -executionpolicy bypass .\scripts\reset_build.ps1
else
sh -x ./scripts/reset_build.sh
endif
build:
meson compile -j 10 -C $(ROOT_DIR)/builddir
release_build:
meson --wipe builddir -Db_ndebug=true --buildtype release
meson compile -j 10 -C builddir
debug_build:
meson setup --wipe builddir -Db_ndebug=true --buildtype debugoptimized
meson compile -j 10 -C builddir
test: build
./builddir/runtests -d yes
run: build test
ifeq '$(OS)' 'Windows_NT'
powershell "cp ./builddir/sfmldemo.exe ."
./sfmldemo
else
./builddir/sfmldemo
endif
debug: build
gdb --nx -x .gdbinit --ex run --args builddir/sfmldemo
debug_run: build
gdb --nx -x .gdbinit --batch --ex run --ex bt --ex q --args builddir/sfmldemo
clean:
meson compile --clean -C builddir
debug_test: build
gdb --nx -x .gdbinit --ex run --ex bt --ex q --args builddir/runtests -e

@ -1,3 +1,63 @@
# cpp-starter-project
# Game Dev Starter Pack
This is a project that students of Learn C++ the hardway checkout to confirm their setup is correct, and also doubles as a quick start for a basic C++ game project start.
This repository contains a simple C++ project with the basics you need to get a game in C++ going. It's meant to be an educational starting point for people interested in learning to make games in C++ from scratch. It also would be a decent starting point for building a game with other frameworks like [Raylib](https://www.libsdl.org/), [SDL2](https://www.libsdl.org/), or anything that needs to be compiled. This setup also works on Windows, OSX, and Linux and includes a "meta install" script for Windows that installs a complete C++ development environment.
I recommend you get this project working with SFML and then rework it for the other framework you want to use, but honestly SFML is really good and works well.
## If You Just Want to Make a Game
This project is more geared toward people who want to learn C++ by making a bunch of little games, or people who want to learn how to make games from almost nothing. If you have a burning desire to craft a game, then I recommend _not_ using this project and instead go learn any of these:
1. [Defold](https://defold.com/)
2. [Game Maker Studio](https://gamemaker.io/en)
3. [Godot](https://godotengine.org/)
4. [Unreal Engine](https://www.unrealengine.com/en-US)
5. [O3DE](https://o3de.org/)
Keep in mind that I've only played with each of these, and have _not_ made a full game in them, so my opinion is highly suspect. You should probably just download each one, think of a tiny little game to make, and try to make it. Pick the framework that gets the most of your game done with the least effort.
## Windows
If you have nothing installed then you'll want to run the `scripts/windows_setup.ps1` script to install everything. This script will run and prompt you for admin passwords as it installs what you need, so be sure to stay near your computer to type passwords in when requested. To run it do this:
1. Start a _normal_ non-Administrator PowerShell window.
2. `irm https://learncodethehardway.com/cppsetup.ps1 > cppsetup.ps1`
3. `powershell -executionpolicy bypass .\cppsetup.ps1`
4. _STAY HERE_. For some dumb reason many installers have a timeout that will cause the installer to fail if you don't enter a password fast enough, so stay close until this is done.
5. Close this PowerShell window and then you can run Windows Terminal and everything should work. If not please email help@learncodethehardway.com to tell me what happened.
The `cppsetup.ps1` file and the `scripts/windows_setup.ps1` should be exactly the same. I'm having you use the `cppsetup.ps1` file since I assume you don't have `git` yet. Once that's done you should then be able to build the project:
2. Run `.\setup.ps1`
3. `meson compile -C builddir`
4. `.\builddir\sfmldemo` -- That should run it and you see a window with ImGUI's demo panel.
**WARNING**: You should look in the `setup.ps1` and `reset_build.p1` files for how a build is actually configured. The most important line is at the bottom `meson setup -Ddefault_library=static builddir` which properly configures the build so that the `sfmldemo.exe` program actually runs. Without the `-Ddefault_library=static` the `sfmldemo.exe` file will not have the `.dll` files it needs and will silently fail. If it fails to start then run `start builddir` and double click on it to get the error messages. Then run `reset_build.ps1` to get a good build.
## OSX
1. Get XCode and [Meson](https://mesonbuild.com/) installed.
2. Run `./setup.sh`
3. `meson compile -C builddir`
4. `.\builddir\sfmldemo` -- That should run it and you see a window with ImGUI's demo panel.
I'll have more extensive instructions in a later blog post, but if you have time try this out and let me know how it went at help@learncodethehardway.com. Please let me know if you tried a different compiler, Windows version, etc. If you're on OSX or Linux it should work the same but Linux people might want to use their package manager instead.
### "Keyboard without any keys"
If you get a weird error message of, "We got a keyboard without any keys" it's because of a security feature in OSX. Go to `Security settings->Input Monitoring` and select your Terminal. Check it, enter your admin password, then restart your Terminal. Now you can...read the keyboard in your own software.
No, this does not enhance security at all. These people have gone full on insane at this point.
## Linux
I actually don't have a Linux computer ready to test, but if you have a brand of Linux you like then try the OSX instructions and email me at [help@learncodethehardway.com](mailto:help@learncodethehardway.com).
## Next Steps
I want the `main.cpp` to hit all the major features of SFML without getting too large, so these are some of the features I need to add:
1. Joystick control.
2. Drawing a floor and walls that work with the physics.
3. Possibly using the networking and threading capabilities of SFML, but not really sure for what.
4. Some kind of hit point calculator, since most everyone needs that.

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

@ -0,0 +1,47 @@
#include "dbc.hpp"
#include <iostream>
void dbc::log(const string &message, const std::source_location location) {
std::cout << '[' << location.file_name() << ':'
<< location.line() << "|"
<< location.function_name() << "] "
<< message << std::endl;
}
void dbc::sentinel(const string &message, const std::source_location location) {
string err = fmt::format("[SENTINEL!] {}", message);
dbc::log(err, location);
throw dbc::SentinelError{err};
}
void dbc::pre(const string &message, bool test, const std::source_location location) {
if(!test) {
string err = fmt::format("[PRE!] {}", message);
dbc::log(err, location);
throw dbc::PreCondError{err};
}
}
void dbc::pre(const string &message, std::function<bool()> tester, const std::source_location location) {
dbc::pre(message, tester(), location);
}
void dbc::post(const string &message, bool test, const std::source_location location) {
if(!test) {
string err = fmt::format("[POST!] {}", message);
dbc::log(err, location);
throw dbc::PostCondError{err};
}
}
void dbc::post(const string &message, std::function<bool()> tester, const std::source_location location) {
dbc::post(message, tester(), location);
}
void dbc::check(bool test, const string &message, const std::source_location location) {
if(!test) {
string err = fmt::format("[CHECK!] {}\n", message);
dbc::log(err, location);
throw dbc::CheckError{err};
}
}

@ -0,0 +1,50 @@
#pragma once
#include <string>
#include <fmt/core.h>
#include <functional>
#include <source_location>
using std::string;
namespace dbc {
class Error {
public:
const string message;
Error(string m) : message{m} {}
Error(const char *m) : message{m} {}
};
class CheckError : public Error {};
class SentinelError : public Error {};
class PreCondError : public Error {};
class PostCondError : public Error {};
void log(const string &message,
const std::source_location location =
std::source_location::current());
[[noreturn]] void sentinel(const string &message,
const std::source_location location =
std::source_location::current());
void pre(const string &message, bool test,
const std::source_location location =
std::source_location::current());
void pre(const string &message, std::function<bool()> tester,
const std::source_location location =
std::source_location::current());
void post(const string &message, bool test,
const std::source_location location =
std::source_location::current());
void post(const string &message, std::function<bool()> tester,
const std::source_location location =
std::source_location::current());
void check(bool test, const string &message,
const std::source_location location =
std::source_location::current());
}

@ -0,0 +1,157 @@
#define _USE_MATH_DEFINES
#include <math.h>
#include <fmt/core.h>
#include <box2d/box2d.h>
#include <SFML/Graphics/Sprite.hpp>
#include <SFML/Graphics/Texture.hpp>
#include <SFML/Graphics/RenderWindow.hpp>
#include <SFML/System.hpp>
#include <SFML/Audio.hpp>
#include <SFML/Window/Event.hpp>
#include "dbc.hpp"
void Window_update(sf::RenderWindow &window, sf::Sprite &player) {
window.clear();
window.draw(player);
window.display();
}
struct BoxTest {
b2Body *groundBody;
b2Body *body;
};
struct BoxTest Box2d_setup(b2World &world) {
b2BodyDef groundBodyDef;
groundBodyDef.position.Set(0.0f, -10.0f);
b2Body *groundBody = world.CreateBody(&groundBodyDef);
b2PolygonShape groundBox;
groundBox.SetAsBox(50.0f, 10.0f);
groundBody->CreateFixture(&groundBox, 0.0f);
b2BodyDef bodyDef;
bodyDef.type = b2_dynamicBody;
bodyDef.position.Set(3.0f, 4.0f);
b2Body *body = world.CreateBody(&bodyDef);
b2PolygonShape dynamicBox;
dynamicBox.SetAsBox(1.0f, 1.0f);
b2FixtureDef fixtureDef;
fixtureDef.shape = &dynamicBox;
fixtureDef.density = 1.0f;
fixtureDef.friction = 0.3f;
body->CreateFixture(&fixtureDef);
BoxTest box {groundBody, body};
return box;
}
void Handle_events(sf::RenderWindow &window, BoxTest &box, sf::Sound &click) {
// is this a main event loop
while (const auto event = window.pollEvent()) {
if(event->is<sf::Event::Closed>()) {
fmt::print("Exiting...\n");
window.close();
} else if (const auto* key = event->getIf<sf::Event::KeyPressed>()) {
if(key->scancode == sf::Keyboard::Scan::Left) {
b2Vec2 force(-200, 1000);
box.body->ApplyForceToCenter(force, true);
box.body->ApplyTorque(100.0f, true);
click.play();
} else if(key->scancode == sf::Keyboard::Scan::Right) {
b2Vec2 force(200, 1000);
box.body->ApplyForceToCenter(force, true);
box.body->ApplyTorque(-100.0f, true);
click.play();
}
} else if(const auto* mouse = event->getIf<sf::Event::MouseButtonPressed>()) {
if(mouse->button == sf::Mouse::Button::Left) {
b2Vec2 force(-200, 1000);
box.body->ApplyForceToCenter(force, true);
box.body->ApplyTorque(100.0f, true);
click.play();
} else if(mouse->button == sf::Mouse::Button::Right) {
b2Vec2 force(200, 1000);
box.body->ApplyForceToCenter(force, true);
box.body->ApplyTorque(-100.0f, true);
click.play();
}
}
}
}
sf::Time Update_entities(sf::RenderWindow &window, b2World &world, sf::Clock &clock, sf::Time &tick, BoxTest &box, sf::Sprite &player) {
sf::Vector2u winSize = window.getSize();
float timeStep = 1.0f / 60.0f;
int velocityIterations = 6;
int positionIterations = 2;
sf::Time since = clock.getElapsedTime();
sf::Time nextTick = since - tick > sf::seconds(1) ? since : tick;
world.Step(timeStep, velocityIterations, positionIterations);
b2Vec2 position = box.body->GetPosition();
float angle = box.body->GetAngle();
player.setPosition({position.x * 100.0f, winSize.y - position.y * 100.0f});
player.setRotation(sf::degrees(angle * 180.0f / M_PI));
Window_update(window, player);
return nextTick;
}
sf::Sprite Create_player(sf::RenderWindow &window, sf::Texture &texture) {
if(!texture.loadFromFile("assets/sprite.png")) {
fmt::print("Error loading sprite!");
}
texture.setSmooth(true);
sf::Sprite player(texture);
player.setTexture(texture);
// position the prite
sf::Vector2u winSize = window.getSize();
player.setPosition({float(winSize.x) / 2, float(winSize.y) / 2});
player.setOrigin({50.f, 50.f});
return player;
}
int main() {
fmt::print("Setting up a window for you...\n");
sf::RenderWindow window(sf::VideoMode({1280, 720}), "Simple Game Demo");
window.setFramerateLimit(60);
window.setVerticalSyncEnabled(true);
sf::SoundBuffer buffer;
if(!buffer.loadFromFile("assets/click.mp3")) {
fmt::print("Failed to load click.ogg!\n");
}
sf::Sound click(buffer);
sf::Clock deltaClock;
sf::Clock clock;
sf::Time tick = clock.getElapsedTime();
sf::Texture texture;
auto player = Create_player(window, texture);
b2Vec2 gravity(0.0f, -10.0f);
b2World world(gravity);
BoxTest box = Box2d_setup(world);
while (window.isOpen()) {
Handle_events(window, box, click);
// preparing for refactoring this into a class or struct for everything
tick = Update_entities(window, world, clock, tick, box, player);
}
}

@ -0,0 +1,99 @@
project('sfmldemo', 'cpp',
version: '0.1.0',
default_options: [
'cpp_std=c++20',
'cpp_args=-D_GLIBCXX_DEBUG=1 -D_GLIBCXX_DEBUG_PEDANTIC=1',
])
# use this for common options only for our executables
cpp_args=[]
link_args=[]
# these are passed as override_defaults
exe_defaults = [ 'warning_level=2' ]
cc = meson.get_compiler('cpp')
dependencies = []
if build_machine.system() == 'windows'
add_global_link_arguments(
'-static-libgcc',
'-static-libstdc++',
'-static',
language: 'cpp',
)
sfml_main = dependency('sfml_main')
opengl32 = cc.find_library('opengl32', required: true)
winmm = cc.find_library('winmm', required: true)
gdi32 = cc.find_library('gdi32', required: true)
dependencies += [
opengl32, winmm, gdi32, sfml_main
]
exe_defaults += ['werror=true']
elif build_machine.system() == 'darwin'
add_global_link_arguments(
language: 'cpp',
)
opengl = dependency('OpenGL')
corefoundation = dependency('CoreFoundation')
carbon = dependency('Carbon')
cocoa = dependency('Cocoa')
iokit = dependency('IOKit')
corevideo = dependency('CoreVideo')
link_args += ['-ObjC']
exe_defaults += ['werror=false']
dependencies += [
opengl, corefoundation, carbon, cocoa, iokit, corevideo
]
endif
catch2 = subproject('catch2').get_variable('catch2_with_main_dep')
fmt = subproject('fmt').get_variable('fmt_dep')
json = subproject('nlohmann_json').get_variable('nlohmann_json_dep')
freetype2 = subproject('freetype2').get_variable('freetype_dep')
flac = subproject('flac').get_variable('flac_dep')
ogg = subproject('ogg').get_variable('libogg_dep')
vorbis = subproject('vorbis').get_variable('vorbis_dep')
vorbisfile = subproject('vorbis').get_variable('vorbisfile_dep')
vorbisenc = subproject('vorbis').get_variable('vorbisenc_dep')
sfml_audio = subproject('sfml').get_variable('sfml_audio_dep')
sfml_graphics = subproject('sfml').get_variable('sfml_graphics_dep')
sfml_network = subproject('sfml').get_variable('sfml_network_dep')
sfml_system = subproject('sfml').get_variable('sfml_system_dep')
sfml_window = subproject('sfml').get_variable('sfml_window_dep')
box2d = subproject('box2d').get_variable('box2d_dep')
dependencies += [
fmt, json, freetype2,
flac, ogg, vorbis, vorbisfile, vorbisenc,
sfml_audio, sfml_graphics,
sfml_network, sfml_system,
sfml_window, box2d
]
sources = [
'dbc.cpp',
]
tests = [
'tests/example.cpp'
]
executable('sfmldemo',
sources + [ 'main.cpp' ],
cpp_args: cpp_args,
link_args: link_args,
override_options: exe_defaults,
dependencies: dependencies)
executable('runtests',
sources + tests,
cpp_args: cpp_args,
link_args: link_args,
override_options: exe_defaults,
dependencies: dependencies + [catch2])

@ -0,0 +1,7 @@
mv .\subprojects\packagecache .
rm -recurse -force .\subprojects\,.\builddir\
mkdir subprojects
mv .\packagecache .\subprojects\
mkdir builddir
cp wraps\*.wrap subprojects\
meson setup --default-library=static --prefer-static builddir

@ -0,0 +1,10 @@
#!/usr/bin/env bash
mv -f ./subprojects/packagecache .
rm -rf subprojects builddir
mkdir subprojects
mv -f packagecache ./subprojects/ && true
mkdir builddir
cp wraps/*.wrap subprojects/
# on OSX you can't do this with static
meson setup --default-library=static --prefer-static builddir

@ -0,0 +1,6 @@
#include <catch2/catch_test_macros.hpp>
TEST_CASE("sample test", "[sample]") {
int test = 100;
REQUIRE(test == 100);
}

@ -0,0 +1,12 @@
[wrap-file]
directory = box2d-2.4.1
source_url = https://github.com/erincatto/box2d/archive/v2.4.1/box2d-2.4.1.tar.gz
source_filename = box2d-2.4.1.tar.gz
source_hash = d6b4650ff897ee1ead27cf77a5933ea197cbeef6705638dd181adc2e816b23c2
patch_filename = box2d_2.4.1-3_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/box2d_2.4.1-3/get_patch
patch_hash = 040bc127d1a8a9cd649cd53f15e8a9fa71d5cc70eaa36bb77d057ba7017cf3c8
wrapdb_version = 2.4.1-3
[provide]
box2d = box2d_dep

@ -0,0 +1,11 @@
[wrap-file]
directory = Catch2-3.7.1
source_url = https://github.com/catchorg/Catch2/archive/v3.7.1.tar.gz
source_filename = Catch2-3.7.1.tar.gz
source_hash = c991b247a1a0d7bb9c39aa35faf0fe9e19764213f28ffba3109388e62ee0269c
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/catch2_3.7.1-1/Catch2-3.7.1.tar.gz
wrapdb_version = 3.7.1-1
[provide]
catch2 = catch2_dep
catch2-with-main = catch2_with_main_dep

@ -0,0 +1,13 @@
[wrap-file]
directory = flac-1.4.3
source_url = https://github.com/xiph/flac/releases/download/1.4.3/flac-1.4.3.tar.xz
source_filename = flac-1.4.3.tar.xz
source_hash = 6c58e69cd22348f441b861092b825e591d0b822e106de6eb0ee4d05d27205b70
patch_filename = flac_1.4.3-2_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/flac_1.4.3-2/get_patch
patch_hash = 3eace1bd0769d3e0d4ff099960160766a5185d391c8f583293b087a1f96c2a9c
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/flac_1.4.3-2/flac-1.4.3.tar.xz
wrapdb_version = 1.4.3-2
[provide]
flac = flac_dep

@ -0,0 +1,13 @@
[wrap-file]
directory = fmt-11.0.2
source_url = https://github.com/fmtlib/fmt/archive/11.0.2.tar.gz
source_filename = fmt-11.0.2.tar.gz
source_hash = 6cb1e6d37bdcb756dbbe59be438790db409cdb4868c66e888d5df9f13f7c027f
patch_filename = fmt_11.0.2-1_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/fmt_11.0.2-1/get_patch
patch_hash = 90c9e3b8e8f29713d40ca949f6f93ad115d78d7fb921064112bc6179e6427c5e
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/fmt_11.0.2-1/fmt-11.0.2.tar.gz
wrapdb_version = 11.0.2-1
[provide]
fmt = fmt_dep

@ -0,0 +1,11 @@
[wrap-file]
directory = freetype-2.13.3
source_url = https://download.savannah.gnu.org/releases/freetype/freetype-2.13.3.tar.xz
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/freetype2_2.13.3-1/freetype-2.13.3.tar.xz
source_filename = freetype-2.13.3.tar.xz
source_hash = 0550350666d427c74daeb85d5ac7bb353acba5f76956395995311a9c6f063289
wrapdb_version = 2.13.3-1
[provide]
freetype2 = freetype_dep
freetype = freetype_dep

@ -0,0 +1,13 @@
[wrap-file]
directory = libpng-1.6.44
source_url = https://github.com/glennrp/libpng/archive/v1.6.44.tar.gz
source_filename = libpng-1.6.44.tar.gz
source_hash = 0ef5b633d0c65f780c4fced27ff832998e71478c13b45dfb6e94f23a82f64f7c
patch_filename = libpng_1.6.44-1_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/libpng_1.6.44-1/get_patch
patch_hash = 394b07614c45fbd1beac8b660386216a490fe12f841a1a445799b676c9c892fb
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/libpng_1.6.44-1/libpng-1.6.44.tar.gz
wrapdb_version = 1.6.44-1
[provide]
libpng = libpng_dep

@ -0,0 +1,11 @@
[wrap-file]
directory = nlohmann_json-3.11.3
lead_directory_missing = true
source_url = https://github.com/nlohmann/json/releases/download/v3.11.3/include.zip
source_filename = nlohmann_json-3.11.3.zip
source_hash = a22461d13119ac5c78f205d3df1db13403e58ce1bb1794edc9313677313f4a9d
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/nlohmann_json_3.11.3-1/nlohmann_json-3.11.3.zip
wrapdb_version = 3.11.3-1
[provide]
nlohmann_json = nlohmann_json_dep

@ -0,0 +1,13 @@
[wrap-file]
directory = libogg-1.3.5
source_url = https://downloads.xiph.org/releases/ogg/libogg-1.3.5.tar.xz
source_filename = libogg-1.3.5.tar.xz
source_hash = c4d91be36fc8e54deae7575241e03f4211eb102afb3fc0775fbbc1b740016705
patch_filename = ogg_1.3.5-6_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/ogg_1.3.5-6/get_patch
patch_hash = 8be6dcd5f93bbf9c0b9c8ec1fa29810226a60f846383074ca05b313a248e78b2
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/ogg_1.3.5-6/libogg-1.3.5.tar.xz
wrapdb_version = 1.3.5-6
[provide]
ogg = libogg_dep

@ -0,0 +1,14 @@
[wrap-git]
directory=SFML-3.0.0
url=https://github.com/SFML/SFML.git
revision=3.0.0
depth=1
method=cmake
[provide]
sfml_audio = sfml_audio_dep
sfml_graphics = sfml_graphics_dep
sfml_main = sfml_main_dep
sfml_network = sfml_network_dep
sfml_system = sfml_system_dep
sfml_window = sfml_window_dep

@ -0,0 +1,14 @@
[wrap-file]
directory = libvorbis-1.3.7
source_url = https://downloads.xiph.org/releases/vorbis/libvorbis-1.3.7.tar.xz
source_filename = libvorbis-1.3.7.tar.xz
source_hash = b33cc4934322bcbf6efcbacf49e3ca01aadbea4114ec9589d1b1e9d20f72954b
patch_filename = vorbis_1.3.7-4_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/vorbis_1.3.7-4/get_patch
patch_hash = 979e22b24b16c927040700dfd8319cd6ba29bf52a14dbc66b1cb4ea60504f14a
wrapdb_version = 1.3.7-4
[provide]
vorbis = vorbis_dep
vorbisfile = vorbisfile_dep
vorbisenc = vorbisenc_dep
Loading…
Cancel
Save