aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/luarocks/build/cmake.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/luarocks/build/cmake.lua b/src/luarocks/build/cmake.lua
index c8f5a669..a1c08dfa 100644
--- a/src/luarocks/build/cmake.lua
+++ b/src/luarocks/build/cmake.lua
@@ -35,7 +35,6 @@ function cmake.run(rockspec)
35 cmake_handler:close() 35 cmake_handler:close()
36 end 36 end
37 37
38
39 -- Execute cmake with variables. 38 -- Execute cmake with variables.
40 local args = "" 39 local args = ""
41 if cfg.cmake_generator then 40 if cfg.cmake_generator then
@@ -45,6 +44,11 @@ function cmake.run(rockspec)
45 args = args .. ' -D' ..k.. '="' ..v.. '"' 44 args = args .. ' -D' ..k.. '="' ..v.. '"'
46 end 45 end
47 46
47 -- Generate 64 bit build if appropiate.
48 if not not cfg.arch:match("%-x86_64$") then
49 args = args .. " -DCMAKE_GENERATOR_PLATFORM=x64"
50 end
51
48 if not fs.execute_string(rockspec.variables.CMAKE.." -H. -Bbuild.luarocks "..args) then 52 if not fs.execute_string(rockspec.variables.CMAKE.." -H. -Bbuild.luarocks "..args) then
49 return nil, "Failed cmake." 53 return nil, "Failed cmake."
50 end 54 end