Skip to content

Commit cbff128

Browse files
Fixed some paths.
1 parent b900699 commit cbff128

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

init.lua

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -325,15 +325,14 @@ function load (code,exec)
325325

326326
local compile_dir = _make_path_..paths.dirname(filename)
327327
-- write file to disk
328-
sys.execute(_mkdir_ .. compile_dir)
328+
sys.execute(_mkdir_ .. '"' .. compile_dir .. '"')
329329
local f = io.open(_make_path_..filename, 'w')
330330
f:write(parsed)
331331
f:close()
332332

333333
-- copy any local headers to the compilation dir
334334
for vlh in pairs(current_localheaders) do
335-
sys.execute('cp '..sys.dirname(filename)..'/'..vlh..' '..
336-
compile_dir)
335+
sys.execute('cp "'..sys.dirname(filename)..'/'..vlh..'" "'..compile_dir..'"')
337336
end
338337

339338
local gcc_str = _make_c_ .. _make_flags_ ..
@@ -346,10 +345,10 @@ function load (code,exec)
346345
print(c.blue .. gcc_str .. c.none)
347346
end
348347
-- compile it
349-
local msgs = sys.execute('cd '..compile_dir..'; '.. gcc_str)
348+
local msgs = sys.execute('cd "'..compile_dir..'"; '.. gcc_str)
350349
if string.match(msgs,'error') then
351350
-- cleanup
352-
sys.execute(_rmdir_ .. _make_path_..filename)
351+
sys.execute(_rmdir_ .. '"' .. _make_path_..filename .. '"')
353352
print(c.blue)
354353
local debug = ''
355354
local itr = 1
@@ -410,7 +409,7 @@ end
410409
----------------------------------------------------------------------
411410
function flush ()
412411
-- complete cleanup
413-
sys.execute(_rmdir_ .. _make_path_)
412+
sys.execute(_rmdir_ .. '"' .. _make_path_ .. '"')
414413
end
415414

416415
----------------------------------------------------------------------

0 commit comments

Comments
 (0)