[CMakeLists.txt] Improved 'sol2' integration.

This commit is contained in:
Quentin Bazin 2020-05-22 19:39:40 +02:00
parent 95b0a55c14
commit 3f2908a6b3
25 changed files with 31 additions and 23 deletions

View File

@ -100,7 +100,9 @@ add_subdirectory(external/lua)
#------------------------------------------------------------------------------
# - sol3 (sol2 v3.x)
#------------------------------------------------------------------------------
include_directories(external/sol2/single/include/sol)
set(LUA_LOCAL_DIR external/lua)
add_subdirectory(external/sol2)
#------------------------------------------------------------------------------
# Subdirectories

View File

@ -53,6 +53,7 @@ target_link_libraries(${PROJECT_NAME}
gamekit
tinyxml2
libglew_static
sol2
lua_static
sfml-system
sfml-window

View File

@ -29,7 +29,7 @@
#include <gk/core/Debug.hpp>
#include <gk/core/Filesystem.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "Config.hpp"

View File

@ -29,7 +29,7 @@
#include <gk/core/Debug.hpp>
#include <gk/core/Filesystem.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "GameKey.hpp"
#include "KeyboardHandler.hpp"

View File

@ -29,7 +29,7 @@
#include <functional>
#include <sol.hpp>
#include <sol/sol.hpp>
#include <gk/graphics/Image.hpp>

View File

@ -23,7 +23,8 @@ add_dependencies(${PROJECT_NAME}
zlib
EnTT
gamekit
lua_static)
lua_static
sol2)
#------------------------------------------------------------------------------
# Compiler flags
@ -45,6 +46,7 @@ target_link_libraries(${PROJECT_NAME}
sfml-network
tinyxml2
zlib
sol2
lua_static
glm)

View File

@ -34,7 +34,7 @@
#include <gk/core/IntTypes.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "ISerializable.hpp"

View File

@ -27,7 +27,7 @@
#ifndef LUACALLBACKCOMPONENT_HPP_
#define LUACALLBACKCOMPONENT_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
struct LuaCallbackComponent {
sol::unsafe_function collisionCallback;

View File

@ -29,7 +29,7 @@
#include <glm/glm.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include <gk/core/Box.hpp>
#include <gk/core/IntTypes.hpp>

View File

@ -31,7 +31,7 @@
#include <string>
#include <unordered_map>
#include <sol.hpp>
#include <sol/sol.hpp>
#include <gk/core/IntTypes.hpp>
#include <gk/core/Exception.hpp>

View File

@ -32,7 +32,7 @@
#include <gk/core/IntTypes.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "ISerializable.hpp"

View File

@ -67,6 +67,8 @@ endif ()
target_link_libraries(${PROJECT_NAME}_lib
sfml-system
sfml-network
sol2
lua_static
glm)
target_link_libraries(${PROJECT_NAME}
@ -75,6 +77,7 @@ target_link_libraries(${PROJECT_NAME}
gamekit
tinyxml2
libglew_static
sol2
lua_static
sfml-system
sfml-network

View File

@ -32,7 +32,7 @@ bool ServerConfig::useItemDrops = false;
#include <gk/core/Debug.hpp>
#include <gk/core/Filesystem.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
void ServerConfig::loadConfigFromFile(const char *file) {
if (gk::Filesystem::fileExists(file)) {

View File

@ -31,7 +31,7 @@
#include <gk/core/IntTypes.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "ISerializable.hpp"
#include "LuaWidget.hpp"

View File

@ -30,7 +30,7 @@
#include <functional>
#include <iostream>
#include <sol.hpp>
#include <sol/sol.hpp>
class Registry;
class ServerModLoader;

View File

@ -29,7 +29,7 @@
#include <glm/vec3.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "LuaCore.hpp"

View File

@ -27,7 +27,7 @@
#ifndef LUABIOMELOADER_HPP_
#define LUABIOMELOADER_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
class Biome;
class LuaMod;

View File

@ -27,7 +27,7 @@
#ifndef LUABLOCKLOADER_HPP_
#define LUABLOCKLOADER_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
class Item;
class LuaMod;

View File

@ -27,7 +27,7 @@
#ifndef LUADIMENSIONLOADER_HPP_
#define LUADIMENSIONLOADER_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
class LuaMod;

View File

@ -27,7 +27,7 @@
#ifndef LUAENTITYLOADER_HPP_
#define LUAENTITYLOADER_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
#include <entt/entt.hpp>

View File

@ -27,7 +27,7 @@
#ifndef LUAITEMLOADER_HPP_
#define LUAITEMLOADER_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
class LuaMod;

View File

@ -27,7 +27,7 @@
#ifndef LUARECIPELOADER_HPP_
#define LUARECIPELOADER_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
class LuaMod;

View File

@ -27,7 +27,7 @@
#ifndef LUASKYLOADER_HPP_
#define LUASKYLOADER_HPP_
#include <sol.hpp>
#include <sol/sol.hpp>
class LuaMod;

View File

@ -33,7 +33,7 @@
#include <entt/entt.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "ChatCommandHandler.hpp"

View File

@ -31,7 +31,7 @@
#include <random.hpp>
#include <sol.hpp>
#include <sol/sol.hpp>
#include "TerrainBiomeSampler.hpp"