Explorar o código

Added Multicompile flag + sample improvment

Eiyeron Fulmincendii %!s(int64=5) %!d(string=hai) anos
pai
achega
b8248ce76c
Modificáronse 2 ficheiros con 8 adicións e 9 borrados
  1. 4 2
      prelude/init.lua
  2. 4 7
      premake5.sample.lua

+ 4 - 2
prelude/init.lua

@@ -19,6 +19,8 @@ local function base_workspace_settings()
     configurations {"Debug", "DebugOpt", "Release"}
     location "build"
     architecture "x86_64"
+    flags { "MultiProcessorCompile" }
+
 
     filter "configurations:Debug"
         defines {"DEBUG"}
@@ -66,7 +68,7 @@ local function library_module(lib_name, folder)
         defines = {},
         win_defines = {},
         linux_defines = {},
-        
+
         -- Separating private/public includes helps
         -- to reuse the public when needed.
 
@@ -173,7 +175,7 @@ local function library_module(lib_name, folder)
                 files(self.win_files)
                 includedirs(self.win_private_includes)
                 links(self.win_links)
-            
+
             filter "system:linux"
                 defines(self.linux_defines)
                 files(self.linux_files)

+ 4 - 7
premake5.sample.lua

@@ -8,8 +8,8 @@ local glm = require "prelude.libraries.glm"
 
 
 workspace "Your Project here"
-    configurations {"Debug", "DebugOpt", "Release"}
-    location "build"
+    prelude.base_workspace_settings()
+    startproject "Main"
 
     -- TODO: Decide about whether keeping the group usage here or include it in
     -- use's call.
@@ -24,7 +24,7 @@ workspace "Your Project here"
     project "Core"
         kind "StaticLib"
         files {"include/core/**.hpp", "src/core/**.cpp"}
-        includedirs {""}
+        includedirs {"include"}
 
     project "Main"
         cppdialect "C++17"
@@ -32,10 +32,7 @@ workspace "Your Project here"
         files {"include/main/**.hpp", "src/main/**.cpp"}
         includedirs {"include"}
         links {"Core"}
-        
+
         -- TODO : issues at link on VS2015. Does it happen at home?
         -- Need to manually check "Link Library Dependencies" every time.
         prelude.link_against_modules {portaudio, physfs, glm}
-
-    prelude.base_project_settings()
-