better access to townengine headers from any point in source tree

This commit is contained in:
veclav talica 2024-07-29 23:40:15 +03:00
parent 09f2f82d27
commit 922e521867
13 changed files with 16 additions and 13 deletions

View File

@ -171,6 +171,9 @@ function(link_and_include_deps target)
third-party/stb
)
# allow access to headers from any point in source tree
target_include_directories(${target} PRIVATE ./)
target_link_libraries(${target} PUBLIC
SDL2::SDL2
SDL2::SDL2main

View File

@ -1,6 +1,5 @@
#include "game.h"
#include "../textures.h"
#include "../game_api.h"
#include "townengine/game_api.h"
#include "state.h"
#include "scenes/scene.h"
#include "scenes/title.h"

View File

@ -2,7 +2,7 @@
#define GAME_H
#include "../game_api.h"
#include "townengine/game_api.h"
#include <stdint.h>

View File

@ -1,6 +1,6 @@
#include "player.h"
#include "world.h"
#include "../game_api.h"
#include "townengine/game_api.h"
#include <SDL2/SDL.h>

View File

@ -2,7 +2,7 @@
#define PLAYER_H
#include "../game_api.h"
#include "townengine/game_api.h"
struct world;

View File

@ -2,7 +2,7 @@
#include "title.h"
#include "scene.h"
#include "../../audio.h"
#include "townengine/game_api.h"
static void ingame_tick(struct state *state) {

View File

@ -2,7 +2,7 @@
#define INGAME_H
#include "../../game_api.h"
#include "townengine/game_api.h"
#include "../state.h"
#include "scene.h"
#include "../player.h"

View File

@ -2,7 +2,7 @@
#include "ingame.h"
#include "../world.h"
#include "../player.h"
#include "../../game_api.h"
#include "townengine/game_api.h"
static void title_tick(struct state *state) {

View File

@ -2,7 +2,7 @@
#define TITLE_H
#include "../../game_api.h"
#include "townengine/game_api.h"
#include "../state.h"
#include "scene.h"
#include "../player.h"

View File

@ -2,7 +2,7 @@
#define STATE_H
#include "../game_api.h"
#include "townengine/game_api.h"
struct state {

View File

@ -1,5 +1,5 @@
#include "world.h"
#include "../game_api.h"
#include "townengine/game_api.h"
#include <stdbool.h>
#include <stdlib.h>

View File

@ -1,7 +1,7 @@
#ifndef WORLD_H
#define WORLD_H
#include "../game_api.h"
#include "townengine/game_api.h"
#include <stdint.h>
#include <stdbool.h>

1
townengine Symbolic link
View File

@ -0,0 +1 @@
src