mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-26 13:10:34 +00:00
Fix build breakage (again) when srcdir != objdir, other small fixes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56998 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
e47561ccff
commit
9d1b696441
@ -7,39 +7,14 @@
|
|||||||
#
|
#
|
||||||
##===----------------------------------------------------------------------===##
|
##===----------------------------------------------------------------------===##
|
||||||
|
|
||||||
# Compiled-in plugins
|
|
||||||
##### FIXME: This breaks the build.
|
|
||||||
#####BUILTIN_PLUGINS = Base
|
|
||||||
|
|
||||||
LEVEL = ../..
|
LEVEL = ../..
|
||||||
TOOLNAME = llvmc2
|
|
||||||
LINK_COMPONENTS = support system
|
|
||||||
REQUIRES_EH := 1
|
|
||||||
|
|
||||||
ifneq ($(BUILTIN_PLUGINS),)
|
BUILTIN_PLUGINS = Base
|
||||||
|
DRIVER_NAME = llvmc2
|
||||||
|
DIRS = $(patsubst %,plugins/%,$(BUILTIN_PLUGINS)) src
|
||||||
|
|
||||||
|
export BUILTIN_PLUGINS
|
||||||
|
export DRIVER_NAME
|
||||||
export BUILTIN_LLVMC_PLUGIN=1
|
export BUILTIN_LLVMC_PLUGIN=1
|
||||||
USEDLIBS = $(patsubst %,LLVMC%,$(BUILTIN_PLUGINS))
|
|
||||||
|
|
||||||
endif
|
|
||||||
|
|
||||||
include $(LEVEL)/Makefile.common
|
include $(LEVEL)/Makefile.common
|
||||||
|
|
||||||
TD_COMMON = $(wildcard $(LLVM_SRC_ROOT)/include/llvm/CompilerDriver/*.td)
|
|
||||||
|
|
||||||
# There is probably a better way to do this: currently we enter the
|
|
||||||
# subdirectory 2 times - the second time is not needed.
|
|
||||||
# This probably also needs to be integrated into Makefile.rules.
|
|
||||||
define PLUGIN_template
|
|
||||||
PLUGIN_$(1)_SOURCES=$$(wildcard plugins/$(1)/*.cpp)
|
|
||||||
PLUGIN_$(1)_TD_SOURCES=$$(wildcard plugins/$(1)/*.cpp)
|
|
||||||
|
|
||||||
$$(LibDir)/LLVMC$(1).o: $$(PLUGIN_$(1)_SOURCES) $$(PLUGIN_$(1)_TD_SOURCES) \
|
|
||||||
$$(TD_COMMON)
|
|
||||||
@$$(MAKE) -C plugins/$(1)
|
|
||||||
|
|
||||||
$$(RecursiveTargets) ::
|
|
||||||
@$$(MAKE) -C plugins/$(1) $$@
|
|
||||||
endef
|
|
||||||
|
|
||||||
$(foreach plugin,$(BUILTIN_PLUGINS),$(eval $(call PLUGIN_template,$(plugin))))
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
// A simple wrapper for gcc.
|
// A simple wrapper for gcc.
|
||||||
// To compile, use this command:
|
// To compile, use this command:
|
||||||
// make TOOLNAME=llvmc_simple GRAPH=examples/Simple.td
|
// TOFIX
|
||||||
|
|
||||||
include "Common.td"
|
include "Common.td"
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
//===- Graph.td - LLVMC2 toolchain descriptions ------------*- tablegen -*-===//
|
//===- Base.td - LLVMC2 toolchain descriptions -------------*- tablegen -*-===//
|
||||||
//
|
//
|
||||||
// The LLVM Compiler Infrastructure
|
// The LLVM Compiler Infrastructure
|
||||||
//
|
//
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
// A (first stab at a) replacement for the Clang's ccc script.
|
// A (first stab at a) replacement for the Clang's ccc script.
|
||||||
// To compile, use this command:
|
// To compile, use this command:
|
||||||
// cd $LLVMC2_DIR
|
// cd $LLVMC2_DIR
|
||||||
// make TOOLNAME=ccc2 BUILTIN_PLUGINS=Clang
|
// make DRIVER_NAME=ccc2 BUILTIN_PLUGINS=Clang
|
||||||
|
|
||||||
include "llvm/CompilerDriver/Common.td"
|
include "llvm/CompilerDriver/Common.td"
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
##===- tools/llvmc2/plugins/Makefile.common ----------------*- Makefile -*-===##
|
##===- tools/llvmc2/plugins/Makefile.plugins ----------------*- Makefile -*-===##
|
||||||
#
|
#
|
||||||
# The LLVM Compiler Infrastructure
|
# The LLVM Compiler Infrastructure
|
||||||
#
|
#
|
||||||
@ -28,6 +28,8 @@ endif
|
|||||||
|
|
||||||
include $(LEVEL)/Makefile.common
|
include $(LEVEL)/Makefile.common
|
||||||
|
|
||||||
|
# TOFIX: This should go into Makefile.rules
|
||||||
|
|
||||||
ifdef BUILD_AUTOGENERATED_INC
|
ifdef BUILD_AUTOGENERATED_INC
|
||||||
TD_COMMON = $(wildcard $(LLVM_SRC_ROOT)/include/llvm/CompilerDriver/*.td)
|
TD_COMMON = $(wildcard $(LLVM_SRC_ROOT)/include/llvm/CompilerDriver/*.td)
|
||||||
|
|
||||||
|
19
tools/llvmc2/src/Makefile
Normal file
19
tools/llvmc2/src/Makefile
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
##===- tools/llvmc2/src/Makefile ---------------------------*- Makefile -*-===##
|
||||||
|
#
|
||||||
|
# The LLVM Compiler Infrastructure
|
||||||
|
#
|
||||||
|
# This file is distributed under the University of Illinois Open
|
||||||
|
# Source License. See LICENSE.TXT for details.
|
||||||
|
#
|
||||||
|
##===----------------------------------------------------------------------===##
|
||||||
|
|
||||||
|
LEVEL = ../../..
|
||||||
|
TOOLNAME = $(DRIVER_NAME)
|
||||||
|
LINK_COMPONENTS = support system
|
||||||
|
REQUIRES_EH := 1
|
||||||
|
|
||||||
|
ifneq ($(BUILTIN_PLUGINS),)
|
||||||
|
USEDLIBS = $(patsubst %,LLVMC%,$(BUILTIN_PLUGINS))
|
||||||
|
endif
|
||||||
|
|
||||||
|
include $(LEVEL)/Makefile.common
|
Loading…
Reference in New Issue
Block a user