contrib/lua-language-server/linux.ninja.patch

80 lines
3.0 KiB
Diff

--- a/3rd/luamake/compile/ninja/linux.ninja
+++ b/3rd/luamake/compile/ninja/linux.ninja
@@ -2,12 +2,12 @@
builddir = build/linux
bin = $builddir/bin
obj = $builddir/obj
-cc = gcc
-ar = ar
+cc = REPLACE_ME
+ar = REPLACE_AR
luamake = luamake
rule c_source_bee
command = $cc -MMD -MT $out -MF $out.d -std=c11 -O2 -Wall $
- -fvisibility=hidden -Itools/lua54 -DNDEBUG -fPIC -o $out -c $in
+ -fvisibility=hidden -Itools/lua54 -DNDEBUG -fPIC -o $out -c $in CFLAGS
description = Compile C $out
deps = gcc
depfile = $out.d
@@ -15,14 +15,14 @@
bee.lua/3rd/lua-seri/lua-seri.c
rule cxx_source_bee
command = $cc -MMD -MT $out -MF $out.d -std=c++17 -fno-rtti -O2 -Wall $
- -fvisibility=hidden -DNDEBUG -fPIC -o $out -c $in
+ -fvisibility=hidden -DNDEBUG -fPIC -o $out -c $in CXXFLAGS
description = Compile C++ $out
deps = gcc
depfile = $out.d
build $obj/source_bee/format.obj: cxx_source_bee bee.lua/3rd/fmt/format.cc
rule cxx_source_bee_1
command = $cc -MMD -MT $out -MF $out.d -std=c++17 -fno-rtti -O2 -Wall $
- -fvisibility=hidden -Ibee.lua -DNDEBUG -fPIC -o $out -c $in
+ -fvisibility=hidden -Ibee.lua -DNDEBUG -fPIC -o $out -c $in CXXFLAGS
description = Compile C++ $out
deps = gcc
depfile = $out.d
@@ -57,7 +57,7 @@
rule cxx_source_bee_2
command = $cc -MMD -MT $out -MF $out.d -std=c++17 -fno-rtti -O2 -Wall $
-fvisibility=hidden -Ibee.lua -Itools/lua54 -DBEE_STATIC -DNDEBUG -fPIC $
- -o $out -c $in
+ -o $out -c $in CXXFLAGS
description = Compile C++ $out
deps = gcc
depfile = $out.d
@@ -80,14 +80,14 @@
rule c_source_lua
command = $cc -MMD -MT $out -MF $out.d -std=c11 -O2 -Wall $
-fvisibility=hidden -DNDEBUG -fPIC -o $out -c $in
- description = Compile C $out
+ description = Compile C $out CFLAGS
deps = gcc
depfile = $out.d
build $obj/source_lua/utf8_crt.obj: c_source_lua bee.lua/3rd/lua/utf8_crt.c
rule c_source_lua_1
command = $cc -MMD -MT $out -MF $out.d -std=c11 -O2 -Wall -DMAKE_LIB $
-DLUA_USE_LINUX -DNDEBUG -Wno-maybe-uninitialized -fPIC -o $out -c $in
- description = Compile C $out
+ description = Compile C $out CFLAGS
deps = gcc
depfile = $out.d
build $obj/source_lua/linit.obj: c_source_lua_1 bee.lua/3rd/lua/linit.c
@@ -95,7 +95,7 @@
rule cxx_source_bootstrap
command = $cc -MMD -MT $out -MF $out.d -std=c++17 -fno-rtti -O2 -Wall $
-fvisibility=hidden -Ibee.lua/3rd/lua -Ibee.lua -DLUA_USE_LINUX $
- -DNDEBUG -fPIC -o $out -c $in
+ -DNDEBUG -fPIC -o $out -c $in CXXFLAGS
description = Compile C++ $out
deps = gcc
depfile = $out.d
@@ -103,7 +103,7 @@
bee.lua/bootstrap/main.cpp
rule link_bootstrap
command = $cc $in -o $out -Wl,-E -static-libgcc -lm -ldl -lstdc++fs $
- -pthread -Wl,-Bstatic -lstdc++ -Wl,-Bdynamic -s
+ -pthread -Wl,-Bstatic -lstdc++ -Wl,-Bdynamic LDFLAGS
description = Link Exe $out
build $bin/bootstrap: link_bootstrap $obj/source_bootstrap/main.obj $
$obj/source_bee/lua-seri.obj $obj/source_bee/format.obj $