Skip to content

Commit 15a095c

Browse files
authored
append build_options last so backend args pass correctly (#263)
append the `build_options` args last so that passing `"--", "<some backend arg>"` works correctly
1 parent e0658e7 commit 15a095c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lua/cmake-tools/init.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -353,8 +353,6 @@ function cmake.build(opt, callback)
353353
}
354354
end
355355

356-
vim.list_extend(args, config:build_options())
357-
358356
if opt.target ~= nil then
359357
vim.list_extend(args, { "--target", opt.target })
360358
vim.list_extend(args, fargs)
@@ -366,6 +364,8 @@ function cmake.build(opt, callback)
366364
vim.list_extend(args, fargs)
367365
end
368366

367+
vim.list_extend(args, config:build_options())
368+
369369
local env = environment.get_build_environment(config)
370370
local cmd = const.cmake_command
371371
return utils.execute(cmd, config.env_script, env, args, config.cwd, config.executor, callback)

0 commit comments

Comments
 (0)