Browse Source

integration of lonely tiger as subproject

Kajetan Johannes Hammerle 3 years ago
parent
commit
641a658319
3 changed files with 26 additions and 16 deletions
  1. 3 0
      .gitmodules
  2. 22 16
      meson.build
  3. 1 0
      subprojects/lonely-tiger

+ 3 - 0
.gitmodules

@@ -4,3 +4,6 @@
 [submodule "raw-terminal"]
 	path = raw-terminal
 	url = git@git.hammerle.me:kjhammerle/raw-terminal.git
+[submodule "lonely-tiger"]
+	path = subprojects/lonely-tiger
+	url = git@git.hammerle.me:kjhammerle/lonely-tiger.git

+ 22 - 16
meson.build

@@ -1,6 +1,6 @@
 project('cubes plus plus', 'cpp')
 
-sourcesCommon = [
+sources_common = [
     'common/block/Block.cpp', 
     'common/block/BlockRegistry.cpp', 
     'common/world/BlockMap.cpp',
@@ -12,16 +12,18 @@ sourcesCommon = [
     'gaming-core/utils/BitArray.cpp',
     'gaming-core/math/Vector.cpp', 
     'gaming-core/network/Packet.cpp',
-    'gaming-core/network/ENet.cpp']
+    'gaming-core/network/ENet.cpp'
+]
 
-sourcesServer = ['server/Main.cpp',
+sources_server = ['server/Main.cpp',
     'server/GameServer.cpp',
     'server/commands/ServerState.cpp',
     'server/commands/CommandManager.cpp',
     'server/world/WorldGenerator.cpp',
-    'gaming-core/network/Server.cpp',]
+    'gaming-core/network/Server.cpp'
+]
 
-sourcesClient = ['client/Main.cpp',
+sources_client = ['client/Main.cpp',
     'gaming-core/utils/Size.cpp',
     'gaming-core/math/Frustum.cpp',
     'gaming-core/math/Plane.cpp',
@@ -57,30 +59,34 @@ sourcesClient = ['client/Main.cpp',
     'client/rendering/Vertex.cpp',
     'client/rendering/Triangle.cpp',
     'client/gui/BaseGUI.cpp',
-    'client/gui/StartGUI.cpp']
+    'client/gui/StartGUI.cpp'
+]
 
-sourcesTest = ['tests/Main.cpp']
+sources_test = ['tests/Main.cpp']
 
-threadDep = dependency('threads')
-glewDep = dependency('glew')
-glfwDep = dependency('glfw3')
-pngDep = dependency('libpng')
+thread_dep = dependency('threads')
+glew_dep = dependency('glew')
+glfw_dep = dependency('glfw3')
+png_dep = dependency('libpng')
 
 args = ['-Wall', '-Wextra', '-pedantic', '-Werror']
 
+liblonelytiger_proj = subproject('lonely-tiger')
+liblonelytiger_dep = liblonelytiger_proj.get_variable('liblonelytiger_dep')
+
 executable('game_server', 
-    sources: sourcesCommon + sourcesServer,
-    dependencies : [threadDep],
+    sources: sources_common + sources_server,
+    dependencies : [thread_dep, liblonelytiger_dep],
     include_directories : include_directories('gaming-core'),
     cpp_args: args)
     
 executable('game_tests', 
-    sources: sourcesTest,
+    sources: sources_test,
     include_directories : include_directories('gaming-core'),
     cpp_args: args)
     
 executable('game_client', 
-    sources: sourcesCommon + sourcesClient,
-    dependencies : [threadDep, glewDep, glfwDep, pngDep],
+    sources: sources_common + sources_client,
+    dependencies : [thread_dep, glew_dep, glfw_dep, png_dep],
     include_directories : include_directories('gaming-core'),
     cpp_args: args)

+ 1 - 0
subprojects/lonely-tiger

@@ -0,0 +1 @@
+Subproject commit 993103cb86db1793b0aac9a19365fa00e7a5c444