Add support for building object files from LLVM assembly sources - close #175
This commit is contained in:
1 parent
6e7139abb1
commit
ba71e8d5e3
10 files changed
+79
No files matched your search
@@ -156,6 +156,7 @@ require_relative "rscons/builders/lang/asm"
|
||||
require_relative "rscons/builders/lang/c"
|
||||
require_relative "rscons/builders/lang/cxx"
|
||||
require_relative "rscons/builders/lang/d"
|
||||
require_relative "rscons/builders/lang/llvm_asm"
|
||||
|
||||
# Unbuffer $stdout
|
||||
$stdout.sync = true
|
||||
@@ -0,0 +1,10 @@
|
||||
Rscons::Builders::Object.register(
|
||||
command: "${LLVMAS_CMD}",
|
||||
direct_command: "${LLVMAS_CMD:direct}",
|
||||
suffix: "${LLVMAS_SUFFIX}",
|
||||
short_description: "Assembling")
|
||||
Rscons::Builders::SharedObject.register(
|
||||
command: "${LLVMAS_CMD}",
|
||||
direct_command: "${LLVMAS_CMD:direct}",
|
||||
suffix: "${LLVMAS_SUFFIX}",
|
||||
short_description: "Assembling")
|
||||
@@ -58,6 +58,11 @@ module Rscons
|
||||
"LIBPATH" => [],
|
||||
"LIBS" => [],
|
||||
"LIBSUFFIX" => ".a",
|
||||
"LLVMAS" => "clang",
|
||||
"LLVMAS_CMD" => %w[${LLVMAS} -c -o ${_TARGET} ${LLVMAS_FLAGS} ${_SOURCES}],
|
||||
"LLVMAS_CMD:direct" => %w[${LLVMAS} -o ${_TARGET} ${LLVMAS_FLAGS} ${LDFLAGS} ${_SOURCES} ${LIBDIRPREFIX}${LIBPATH} ${LIBLINKPREFIX}${LIBS}],
|
||||
"LLVMAS_FLAGS" => [],
|
||||
"LLVMAS_SUFFIX" => ".ll",
|
||||
"OBJDUMP" => "objdump",
|
||||
"OBJSUFFIX" => %w[.o],
|
||||
"PROGSUFFIX" => on_windows ? ".exe" : "",
|
||||
|
||||
Reference in new issue
Block a user