Skip to content

Commit

Permalink
Merge pull request #1276 from LORgames/ssurtees/codeliteForceIncludes
Browse files Browse the repository at this point in the history
Added support for forceincludes in CodeLite
  • Loading branch information
tdesveauxPKFX authored May 2, 2019
2 parents 5913b0e + b6c9bc3 commit cdb6d3f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions modules/codelite/codelite_project.lua
Original file line number Diff line number Diff line change
Expand Up @@ -196,8 +196,9 @@
end

local toolset = m.getcompiler(cfg)
local cxxflags = table.concat(table.join(toolset.getcxxflags(cfg), cfg.buildoptions), ";")
local cflags = table.concat(table.join(toolset.getcflags(cfg), cfg.buildoptions), ";")
local forceincludes = toolset.getforceincludes(cfg)
local cxxflags = table.concat(table.join(toolset.getcxxflags(cfg), forceincludes, cfg.buildoptions), ";")
local cflags = table.concat(table.join(toolset.getcflags(cfg), forceincludes, cfg.buildoptions), ";")
local asmflags = ""
local pch = ""

Expand Down
3 changes: 2 additions & 1 deletion modules/codelite/tests/test_codelite_config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,12 @@
language "C++"
cppdialect "C++11"
flags { "NoBufferSecurityCheck" }
forceincludes { "forced_include1.h", "forced_include2.h" }
buildoptions { "-opt1", "-opt2" }
prepare()
codelite.project.compiler(cfg)
test.capture [[
<Compiler Options="-O0;-fPIC;-g;-std=c++11;-fno-exceptions;-fno-stack-protector;-fno-rtti;-opt1;-opt2" C_Options="-O0;-fPIC;-g;-opt1;-opt2" Assembler="" Required="yes" PreCompiledHeader="" PCHInCommandLine="no" UseDifferentPCHFlags="no" PCHFlags="">
<Compiler Options="-O0;-fPIC;-g;-std=c++11;-fno-exceptions;-fno-stack-protector;-fno-rtti;-include forced_include1.h;-include forced_include2.h;-opt1;-opt2" C_Options="-O0;-fPIC;-g;-include forced_include1.h;-include forced_include2.h;-opt1;-opt2" Assembler="" Required="yes" PreCompiledHeader="" PCHInCommandLine="no" UseDifferentPCHFlags="no" PCHFlags="">
</Compiler>
]]
end
Expand Down

0 comments on commit cdb6d3f

Please sign in to comment.