Skip to content

Commit

Permalink
remove more codes
Browse files Browse the repository at this point in the history
  • Loading branch information
waruqi committed Aug 1, 2023
1 parent 589975d commit 0f88991
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 55 deletions.
15 changes: 0 additions & 15 deletions xmake/actions/build/kinds/shared.lua
Original file line number Diff line number Diff line change
Expand Up @@ -54,21 +54,6 @@ function _do_link_target(target, opt)
local depvalues = {linkinst:program(), linkflags}
depend.on_changed(function ()

-- TODO make headers (deprecated)
if not dryrun then
local srcheaders, dstheaders = target:headers()
if srcheaders and dstheaders then
local i = 1
for _, srcheader in ipairs(srcheaders) do
local dstheader = dstheaders[i]
if dstheader then
os.cp(srcheader, dstheader)
end
i = i + 1
end
end
end

-- the target file
local targetfile = target:targetfile()

Expand Down
15 changes: 0 additions & 15 deletions xmake/actions/build/kinds/static.lua
Original file line number Diff line number Diff line change
Expand Up @@ -54,21 +54,6 @@ function _do_link_target(target, opt)
local depvalues = {linkinst:program(), linkflags}
depend.on_changed(function ()

-- TODO make headers (deprecated)
if not dryrun then
local srcheaders, dstheaders = target:headers()
if srcheaders and dstheaders then
local i = 1
for _, srcheader in ipairs(srcheaders) do
local dstheader = dstheaders[i]
if dstheader then
os.cp(srcheader, dstheader)
end
i = i + 1
end
end
end

-- the target file
local targetfile = target:targetfile()

Expand Down
4 changes: 0 additions & 4 deletions xmake/modules/target/action/clean/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,6 @@ function main(target)
remove_files(target:pcoutputfile("c"))
remove_files(target:pcoutputfile("cxx"))

-- TODO remove the header files (deprecated)
local _, dstheaders = target:headers()
remove_files(dstheaders)

-- remove the clean files
remove_files(target:get("cleanfiles"))

Expand Down
18 changes: 0 additions & 18 deletions xmake/plugins/project/cmake/cmakelists.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1005,21 +1005,6 @@ function _add_target_custom_commands(cmakelists, target, outputdir)
_add_target_custom_commands_for_batchcmds(cmakelists, target, outputdir, "after", cmds_after)
end

-- TODO export target headers (deprecated)
function _export_target_headers(target)
local srcheaders, dstheaders = target:headers()
if srcheaders and dstheaders then
local i = 1
for _, srcheader in ipairs(srcheaders) do
local dstheader = dstheaders[i]
if dstheader then
os.cp(srcheader, dstheader)
end
i = i + 1
end
end
end

-- add target
function _add_target(cmakelists, target, outputdir)

Expand All @@ -1044,9 +1029,6 @@ function _add_target(cmakelists, target, outputdir)
raise("unknown target kind %s", target:kind())
end

-- TODO export target headers (deprecated)
_export_target_headers(target)

-- add target dependencies
_add_target_dependencies(cmakelists, target)

Expand Down
3 changes: 0 additions & 3 deletions xmake/plugins/project/make/makefile.lua
Original file line number Diff line number Diff line change
Expand Up @@ -655,9 +655,6 @@ function _add_clean_target(makefile, target, outputdir)
_add_remove_files(makefile, target:targetfile(), outputdir)
_add_remove_files(makefile, target:symbolfile(), outputdir)
_add_remove_files(makefile, target:objectfiles(), outputdir)
-- TODO remove the header files (deprecated)
local _, dstheaders = target:headers()
_add_remove_files(makefile, dstheaders, outputdir)
end
makefile:print("")
end
Expand Down

0 comments on commit 0f88991

Please sign in to comment.