mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2025-03-19 00:21:40 +00:00
extra/llvm to 3.4-2
This commit is contained in:
parent
19677b7b9a
commit
1197ad8d42
3 changed files with 385 additions and 1 deletions
|
@ -15,7 +15,7 @@
|
|||
pkgname=('llvm' 'llvm-libs' 'llvm-ocaml' 'clang' 'clang-analyzer'
|
||||
'clang-tools-extra')
|
||||
pkgver=3.4
|
||||
pkgrel=1
|
||||
pkgrel=2
|
||||
arch=('i686' 'x86_64')
|
||||
url="http://llvm.org/"
|
||||
license=('custom:University of Illinois/NCSA Open Source License')
|
||||
|
@ -26,6 +26,8 @@ source=(http://llvm.org/releases/$pkgver/llvm-$pkgver.src.tar.gz
|
|||
http://llvm.org/releases/$pkgver/clang-tools-extra-$pkgver.src.tar.gz
|
||||
http://llvm.org/releases/$pkgver/compiler-rt-$pkgver.src.tar.gz
|
||||
clang-3.3-use-gold-linker.patch
|
||||
clang-3.4-max_align_t.patch
|
||||
llvm-3.4-provide-cmake-modules.patch
|
||||
llvm-Config-config.h
|
||||
llvm-Config-llvm-config.h)
|
||||
sha256sums=('25a5612d692c48481b9b397e2b55f4870e447966d66c96d655241702d44a2628'
|
||||
|
@ -33,6 +35,8 @@ sha256sums=('25a5612d692c48481b9b397e2b55f4870e447966d66c96d655241702d44a2628'
|
|||
'ba85187551ae97fe1c8ab569903beae5ff0900e21233e5eb5389f6ceab1028b4'
|
||||
'f37c89b1383ce462d47537a0245ac798600887a9be9f63073e16b79ed536ab5c'
|
||||
'8240adda155d7961eeb5d07ed50ead10cb7125f70283dff7f1c9fee9df3cea09'
|
||||
'0f0cbff69af54e83383385abbdeb1fee23e6e69427f8530060c492c0b07c2bbe'
|
||||
'b6bb154d5ec998328e818bb09acfc6229e41367ba45cea7cc5b2dd2a7c835cf5'
|
||||
'312574e655f9a87784ca416949c505c452b819fad3061f2cde8aced6540a19a3'
|
||||
'597dc5968c695bbdbb0eac9e8eb5117fcd2773bc91edf5ec103ecffffab8bc48')
|
||||
|
||||
|
@ -53,6 +57,16 @@ prepare() {
|
|||
|
||||
# Make -flto work; use ld.gold instead of the default linker
|
||||
patch -d tools/clang -Np1 -i "$srcdir/clang-3.3-use-gold-linker.patch"
|
||||
|
||||
# Teach Clang to provide ::max_align_t in C11 and C++11 modes (FS#40229)
|
||||
# http://reviews.llvm.org/rL201729
|
||||
patch -d tools/clang -Np0 -i "$srcdir/clang-3.4-max_align_t.patch"
|
||||
|
||||
# Provide CMake modules (FS#38705)
|
||||
# http://reviews.llvm.org/rL201047
|
||||
# http://reviews.llvm.org/rL201048
|
||||
# http://reviews.llvm.org/rL201053
|
||||
patch -Np0 -i "$srcdir/llvm-3.4-provide-cmake-modules.patch"
|
||||
}
|
||||
|
||||
build() {
|
||||
|
@ -206,6 +220,21 @@ package_clang() {
|
|||
python2 -m compileall "$pkgdir/usr/lib/python2.7/site-packages/clang"
|
||||
python2 -O -m compileall "$pkgdir/usr/lib/python2.7/site-packages/clang"
|
||||
|
||||
# Install clang-format editor integration files (FS#38485)
|
||||
# Destination paths are copied from clang-format/CMakeLists.txt
|
||||
install -d "$pkgdir/usr/share/$pkgname"
|
||||
(
|
||||
cd tools/clang-format
|
||||
cp \
|
||||
clang-format-diff.py \
|
||||
clang-format-sublime.py \
|
||||
clang-format.el \
|
||||
clang-format.py \
|
||||
"$pkgdir/usr/share/$pkgname/"
|
||||
cp git-clang-format "$pkgdir/usr/bin/"
|
||||
sed -i 's|/usr/bin/python$|&2|' "$pkgdir/usr/bin/git-clang-format"
|
||||
)
|
||||
|
||||
install -Dm644 LICENSE.TXT "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
|
||||
}
|
||||
|
||||
|
|
36
extra/llvm/clang-3.4-max_align_t.patch
Normal file
36
extra/llvm/clang-3.4-max_align_t.patch
Normal file
|
@ -0,0 +1,36 @@
|
|||
Index: lib/Headers/stddef.h
|
||||
===================================================================
|
||||
--- lib/Headers/stddef.h (revision 201728)
|
||||
+++ lib/Headers/stddef.h (revision 201729)
|
||||
@@ -84,6 +84,16 @@
|
||||
#endif
|
||||
#endif
|
||||
|
||||
+#if __STDC_VERSION__ >= 201112L || __cplusplus >= 201103L
|
||||
+typedef struct {
|
||||
+ long long __clang_max_align_nonce1
|
||||
+ __attribute__((__aligned__(__alignof__(long long))));
|
||||
+ long double __clang_max_align_nonce2
|
||||
+ __attribute__((__aligned__(__alignof__(long double))));
|
||||
+} max_align_t;
|
||||
+#define __CLANG_MAX_ALIGN_T_DEFINED
|
||||
+#endif
|
||||
+
|
||||
#define offsetof(t, d) __builtin_offsetof(t, d)
|
||||
|
||||
#endif /* __STDDEF_H */
|
||||
Index: test/Headers/c11.c
|
||||
===================================================================
|
||||
--- test/Headers/c11.c (revision 201728)
|
||||
+++ test/Headers/c11.c (revision 201729)
|
||||
@@ -22,6 +22,10 @@
|
||||
#define __STDC_WANT_LIB_EXT1__ 1
|
||||
#include <stddef.h>
|
||||
rsize_t x = 0;
|
||||
+_Static_assert(sizeof(max_align_t) >= sizeof(long long), "");
|
||||
+_Static_assert(alignof(max_align_t) >= alignof(long long), "");
|
||||
+_Static_assert(sizeof(max_align_t) >= sizeof(long double), "");
|
||||
+_Static_assert(alignof(max_align_t) >= alignof(long double), "");
|
||||
|
||||
// If we are freestanding, then also check RSIZE_MAX (in a hosted implementation
|
||||
// we will use the host stdint.h, which may not yet have C11 support).
|
319
extra/llvm/llvm-3.4-provide-cmake-modules.patch
Normal file
319
extra/llvm/llvm-3.4-provide-cmake-modules.patch
Normal file
|
@ -0,0 +1,319 @@
|
|||
Index: cmake/modules/LLVMConfig.cmake.in
|
||||
===================================================================
|
||||
--- cmake/modules/LLVMConfig.cmake.in (revision 201046)
|
||||
+++ cmake/modules/LLVMConfig.cmake.in (revision 201047)
|
||||
@@ -41,16 +41,6 @@
|
||||
set(LLVM_LIBRARY_DIRS ${LLVM_INSTALL_PREFIX}/lib)
|
||||
set(LLVM_DEFINITIONS "-D__STDC_LIMIT_MACROS" "-D__STDC_CONSTANT_MACROS")
|
||||
|
||||
-# We try to include using the current setting of CMAKE_MODULE_PATH,
|
||||
-# which suppossedly was filled by the user with the directory where
|
||||
-# this file was installed:
|
||||
-include( LLVM-Config OPTIONAL RESULT_VARIABLE LLVMCONFIG_INCLUDED )
|
||||
-
|
||||
-# If failed, we assume that this is an un-installed build:
|
||||
-if( NOT LLVMCONFIG_INCLUDED )
|
||||
- set(CMAKE_MODULE_PATH
|
||||
- ${CMAKE_MODULE_PATH}
|
||||
- "@LLVM_SOURCE_DIR@/cmake/modules")
|
||||
- include( LLVM-Config )
|
||||
-endif()
|
||||
-
|
||||
+get_filename_component(_SELF_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
|
||||
+include(${_SELF_DIR}/LLVM-Config.cmake)
|
||||
+unset(_SELF_DIR)
|
||||
Index: cmake/modules/LLVMConfig.cmake.in
|
||||
===================================================================
|
||||
--- cmake/modules/LLVMConfig.cmake.in (revision 201047)
|
||||
+++ cmake/modules/LLVMConfig.cmake.in (revision 201048)
|
||||
@@ -1,5 +1,7 @@
|
||||
# This file provides information and services to the final user.
|
||||
|
||||
+@LLVM_CONFIG_CODE@
|
||||
+
|
||||
set(LLVM_VERSION_MAJOR @LLVM_VERSION_MAJOR@)
|
||||
set(LLVM_VERSION_MINOR @LLVM_VERSION_MINOR@)
|
||||
set(LLVM_PACKAGE_VERSION @PACKAGE_VERSION@)
|
||||
@@ -36,11 +38,9 @@
|
||||
set(LLVM_ON_UNIX @LLVM_ON_UNIX@)
|
||||
set(LLVM_ON_WIN32 @LLVM_ON_WIN32@)
|
||||
|
||||
-set(LLVM_INSTALL_PREFIX "@LLVM_INSTALL_PREFIX@")
|
||||
-set(LLVM_INCLUDE_DIRS ${LLVM_INSTALL_PREFIX}/include)
|
||||
-set(LLVM_LIBRARY_DIRS ${LLVM_INSTALL_PREFIX}/lib)
|
||||
+set(LLVM_INCLUDE_DIRS "@LLVM_CONFIG_INCLUDE_DIRS@")
|
||||
+set(LLVM_LIBRARY_DIRS "@LLVM_CONFIG_LIBRARY_DIRS@")
|
||||
set(LLVM_DEFINITIONS "-D__STDC_LIMIT_MACROS" "-D__STDC_CONSTANT_MACROS")
|
||||
+set(LLVM_CMAKE_DIR "@LLVM_CONFIG_CMAKE_DIR@")
|
||||
|
||||
-get_filename_component(_SELF_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
|
||||
-include(${_SELF_DIR}/LLVM-Config.cmake)
|
||||
-unset(_SELF_DIR)
|
||||
+include(${LLVM_CMAKE_DIR}/LLVM-Config.cmake)
|
||||
Index: utils/llvm-build/llvmbuild/main.py
|
||||
===================================================================
|
||||
--- utils/llvm-build/llvmbuild/main.py (revision 201052)
|
||||
+++ utils/llvm-build/llvmbuild/main.py (revision 201053)
|
||||
@@ -573,6 +573,40 @@
|
||||
|
||||
f.close()
|
||||
|
||||
+ def write_cmake_exports_fragment(self, output_path):
|
||||
+ """
|
||||
+ write_cmake_exports_fragment(output_path) -> None
|
||||
+
|
||||
+ Generate a CMake fragment which includes LLVMBuild library
|
||||
+ dependencies expressed similarly to how CMake would write
|
||||
+ them via install(EXPORT).
|
||||
+ """
|
||||
+
|
||||
+ dependencies = list(self.get_fragment_dependencies())
|
||||
+
|
||||
+ # Write out the CMake exports fragment.
|
||||
+ make_install_dir(os.path.dirname(output_path))
|
||||
+ f = open(output_path, 'w')
|
||||
+
|
||||
+ f.write("""\
|
||||
+# Explicit library dependency information.
|
||||
+#
|
||||
+# The following property assignments tell CMake about link
|
||||
+# dependencies of libraries imported from LLVM.
|
||||
+""")
|
||||
+ for ci in self.ordered_component_infos:
|
||||
+ # We only write the information for libraries currently.
|
||||
+ if ci.type_name != 'Library':
|
||||
+ continue
|
||||
+
|
||||
+ f.write("""\
|
||||
+set_property(TARGET %s PROPERTY IMPORTED_LINK_INTERFACE_LIBRARIES %s)\n""" % (
|
||||
+ ci.get_prefixed_library_name(), " ".join(sorted(
|
||||
+ dep.get_prefixed_library_name()
|
||||
+ for dep in self.get_required_libraries_for_component(ci)))))
|
||||
+
|
||||
+ f.close()
|
||||
+
|
||||
def write_make_fragment(self, output_path):
|
||||
"""
|
||||
write_make_fragment(output_path) -> None
|
||||
@@ -780,6 +814,10 @@
|
||||
dest="write_cmake_fragment", metavar="PATH",
|
||||
help="Write the CMake project information to PATH",
|
||||
action="store", default=None)
|
||||
+ group.add_option("", "--write-cmake-exports-fragment",
|
||||
+ dest="write_cmake_exports_fragment", metavar="PATH",
|
||||
+ help="Write the CMake exports information to PATH",
|
||||
+ action="store", default=None)
|
||||
group.add_option("", "--write-make-fragment",
|
||||
dest="write_make_fragment", metavar="PATH",
|
||||
help="Write the Makefile project information to PATH",
|
||||
@@ -861,6 +899,8 @@
|
||||
# Write out the cmake fragment, if requested.
|
||||
if opts.write_cmake_fragment:
|
||||
project_info.write_cmake_fragment(opts.write_cmake_fragment)
|
||||
+ if opts.write_cmake_exports_fragment:
|
||||
+ project_info.write_cmake_exports_fragment(opts.write_cmake_exports_fragment)
|
||||
|
||||
# Configure target definition files, if requested.
|
||||
if opts.configure_target_def_files:
|
||||
Index: Makefile.rules
|
||||
===================================================================
|
||||
--- Makefile.rules (revision 201052)
|
||||
+++ Makefile.rules (revision 201053)
|
||||
@@ -78,6 +78,12 @@
|
||||
|
||||
# The files we are going to generate using llvm-build.
|
||||
LLVMBuildMakeFrag := $(PROJ_OBJ_ROOT)/Makefile.llvmbuild
|
||||
+LLVMBuildCMakeFrag := $(PROJ_OBJ_ROOT)/LLVMBuild.cmake
|
||||
+LLVMBuildCMakeExportsFrag := $(PROJ_OBJ_ROOT)/cmake/modules/LLVMBuildExports.cmake
|
||||
+LLVMBuildMakeFrags := \
|
||||
+ $(LLVMBuildMakeFrag) \
|
||||
+ $(LLVMBuildCMakeFrag) \
|
||||
+ $(LLVMBuildCMakeExportsFrag)
|
||||
LLVMConfigLibraryDependenciesInc := \
|
||||
$(PROJ_OBJ_ROOT)/tools/llvm-config/LibraryDependencies.inc
|
||||
|
||||
@@ -94,8 +100,8 @@
|
||||
#
|
||||
# We include a dependency on this Makefile to ensure that changes to the
|
||||
# generation command get picked up.
|
||||
-$(LLVMBuildMakeFrag): $(PROJ_SRC_ROOT)/Makefile.rules \
|
||||
- $(PROJ_OBJ_ROOT)/Makefile.config
|
||||
+$(LLVMBuildMakeFrags): $(PROJ_SRC_ROOT)/Makefile.rules \
|
||||
+ $(PROJ_OBJ_ROOT)/Makefile.config
|
||||
$(Echo) Constructing LLVMBuild project information.
|
||||
$(Verb)$(PYTHON) $(LLVMBuildTool) \
|
||||
--native-target "$(TARGET_NATIVE_ARCH)" \
|
||||
@@ -102,10 +108,12 @@
|
||||
--enable-targets "$(TARGETS_TO_BUILD)" \
|
||||
--enable-optional-components "$(OPTIONAL_COMPONENTS)" \
|
||||
--write-library-table $(LLVMConfigLibraryDependenciesInc) \
|
||||
- --write-make-fragment $(LLVMBuildMakeFrag)
|
||||
+ --write-make-fragment $(LLVMBuildMakeFrag) \
|
||||
+ --write-cmake-fragment $(LLVMBuildCMakeFrag) \
|
||||
+ --write-cmake-exports-fragment $(LLVMBuildCMakeExportsFrag)
|
||||
|
||||
# For completeness, let Make know how the extra files are generated.
|
||||
-$(LLVMConfigLibraryDependenciesInc): $(LLVMBuildMakeFrag)
|
||||
+$(LLVMConfigLibraryDependenciesInc): $(LLVMBuildMakeFrags)
|
||||
|
||||
# Include the generated Makefile fragment.
|
||||
#
|
||||
@@ -120,7 +128,7 @@
|
||||
|
||||
# Clean the generated makefile fragment at the top-level.
|
||||
clean-local::
|
||||
- -$(Verb) $(RM) -f $(LLVMBuildMakeFrag)
|
||||
+ -$(Verb) $(RM) -f $(LLVMBuildMakeFrags)
|
||||
endif
|
||||
-include $(LLVMBuildMakeFrag)
|
||||
|
||||
Index: Makefile
|
||||
===================================================================
|
||||
--- Makefile (revision 201052)
|
||||
+++ Makefile (revision 201053)
|
||||
@@ -15,7 +15,7 @@
|
||||
# 3. Build IR, which builds the Intrinsics.inc file used by libs.
|
||||
# 4. Build libs, which are needed by llvm-config.
|
||||
# 5. Build llvm-config, which determines inter-lib dependencies for tools.
|
||||
-# 6. Build tools and docs.
|
||||
+# 6. Build tools, docs, and cmake modules.
|
||||
#
|
||||
# When cross-compiling, there are some things (tablegen) that need to
|
||||
# be build for the build system first.
|
||||
@@ -31,7 +31,7 @@
|
||||
OPTIONAL_DIRS := tools/clang/utils/TableGen
|
||||
else
|
||||
DIRS := lib/Support lib/TableGen utils lib/IR lib tools/llvm-shlib \
|
||||
- tools/llvm-config tools docs unittests
|
||||
+ tools/llvm-config tools docs cmake unittests
|
||||
OPTIONAL_DIRS := projects bindings
|
||||
endif
|
||||
|
||||
Index: cmake/modules/Makefile
|
||||
===================================================================
|
||||
--- cmake/modules/Makefile (revision 0)
|
||||
+++ cmake/modules/Makefile (revision 201053)
|
||||
@@ -0,0 +1,106 @@
|
||||
+##===- cmake/modules/Makefile ------------------------------*- Makefile -*-===##
|
||||
+#
|
||||
+# The LLVM Compiler Infrastructure
|
||||
+#
|
||||
+# This file is distributed under the University of Illinois Open Source
|
||||
+# License. See LICENSE.TXT for details.
|
||||
+#
|
||||
+##===----------------------------------------------------------------------===##
|
||||
+
|
||||
+LEVEL = ../..
|
||||
+
|
||||
+LINK_COMPONENTS := all
|
||||
+
|
||||
+include $(LEVEL)/Makefile.common
|
||||
+
|
||||
+PROJ_cmake := $(DESTDIR)$(PROJ_prefix)/share/llvm/cmake
|
||||
+
|
||||
+OBJMODS := LLVMConfig.cmake LLVMConfigVersion.cmake LLVMExports.cmake
|
||||
+
|
||||
+# TODO: Teach LLVM-Config.cmake to work without explicit terminfo libs.
|
||||
+TERMINFO_LIBS := tinfo terminfo curses ncurses ncursesw
|
||||
+TERMINFO_LIBS := $(filter $(TERMINFO_LIBS),$(subst -l,,$(LIBS)))
|
||||
+
|
||||
+$(PROJ_OBJ_DIR)/LLVMConfig.cmake: LLVMConfig.cmake.in $(LLVMBuildCMakeFrag)
|
||||
+ $(Echo) 'Generating LLVM CMake package config file'
|
||||
+ $(Verb) ( \
|
||||
+ cat $< | sed \
|
||||
+ -e 's/@LLVM_CONFIG_CODE@/set(LLVM_INSTALL_PREFIX "'"$(subst /,\/,$(PROJ_prefix))"'")/' \
|
||||
+ -e 's/@LLVM_VERSION_MAJOR@/'"$(LLVM_VERSION_MAJOR)"'/' \
|
||||
+ -e 's/@LLVM_VERSION_MINOR@/'"$(LLVM_VERSION_MINOR)"'/' \
|
||||
+ -e 's/@PACKAGE_VERSION@/'"$(LLVMVersion)"'/' \
|
||||
+ -e 's/@LLVM_COMMON_DEPENDS@//' \
|
||||
+ -e 's/"@llvm_libs@"/'"$(subst -l,,$(LLVMConfigLibs))"'/' \
|
||||
+ -e 's/@LLVM_ALL_TARGETS@/'"$(ALL_TARGETS)"'/' \
|
||||
+ -e 's/@LLVM_TARGETS_TO_BUILD@/'"$(TARGETS_TO_BUILD)"'/' \
|
||||
+ -e 's/@LLVM_TARGETS_WITH_JIT@/'"$(TARGETS_WITH_JIT)"'/' \
|
||||
+ -e 's/@TARGET_TRIPLE@/'"$(TARGET_TRIPLE)"'/' \
|
||||
+ -e 's/@LLVM_ENABLE_TERMINFO@/'"$(ENABLE_TERMINFO)"'/' \
|
||||
+ -e 's/@LLVM_ENABLE_THREADS@/'"$(ENABLE_THREADS)"'/' \
|
||||
+ -e 's/@LLVM_ENABLE_ZLIB@/'"$(ENABLE_ZLIB)"'/' \
|
||||
+ -e 's/@LLVM_NATIVE_ARCH@/'"$(LLVM_NATIVE_ARCH)"'/' \
|
||||
+ -e 's/@LLVM_ENABLE_PIC@/'"$(ENABLE_PIC)"'/' \
|
||||
+ -e 's/@HAVE_TERMINFO@/'"$(HAVE_TERMINFO)"'/' \
|
||||
+ -e 's/@TERMINFO_LIBS@/'"$(TERMINFO_LIBS)"'/' \
|
||||
+ -e 's/@HAVE_LIBDL@/'"$(HAVE_DLOPEN)"'/' \
|
||||
+ -e 's/@HAVE_LIBPTHREAD@/'"$(HAVE_PTHREAD)"'/' \
|
||||
+ -e 's/@HAVE_LIBZ@/'"$(HAVE_LIBZ)"'/' \
|
||||
+ -e 's/@LLVM_ON_UNIX@/'"$(LLVM_ON_UNIX)"'/' \
|
||||
+ -e 's/@LLVM_ON_WIN32@/'"$(LLVM_ON_WIN32)"'/' \
|
||||
+ -e 's/@LLVM_CONFIG_INCLUDE_DIRS@/'"$(subst /,\/,$(PROJ_includedir))"'/' \
|
||||
+ -e 's/@LLVM_CONFIG_LIBRARY_DIRS@/'"$(subst /,\/,$(PROJ_libdir))"'/' \
|
||||
+ -e 's/@LLVM_CONFIG_CMAKE_DIR@/'"$(subst /,\/,$(PROJ_cmake))"'/' \
|
||||
+ -e 's/@LLVM_CONFIG_EXPORTS_FILE@/$${LLVM_CMAKE_DIR}\/LLVMExports.cmake/' \
|
||||
+ -e 's/@all_llvm_lib_deps@//' \
|
||||
+ && \
|
||||
+ # TODO: Teach LLVM-Config.cmake to use builtin CMake features \
|
||||
+ # for library dependencies. For now add the generated fragments. \
|
||||
+ grep '^set_property.*LLVMBUILD_LIB_DEPS_' "$(LLVMBuildCMakeFrag)" \
|
||||
+ ) > $@
|
||||
+
|
||||
+$(PROJ_OBJ_DIR)/LLVMConfigVersion.cmake: LLVMConfigVersion.cmake.in
|
||||
+ $(Echo) 'Generating LLVM CMake package version file'
|
||||
+ $(Verb) cat $< | sed \
|
||||
+ -e 's/@PACKAGE_VERSION@/'"$(LLVMVersion)"'/' \
|
||||
+ > $@
|
||||
+
|
||||
+$(PROJ_OBJ_DIR)/LLVMExports.cmake: $(LLVMBuildCMakeExportsFrag)
|
||||
+ $(Echo) 'Generating LLVM CMake target exports file'
|
||||
+ $(Verb) ( \
|
||||
+ echo '# LLVM CMake target exports. Do not include directly.' && \
|
||||
+ for lib in $(subst -l,,$(LLVMConfigLibs)); do \
|
||||
+ echo 'add_library('"$$lib"' STATIC IMPORTED)' && \
|
||||
+ echo 'set_property(TARGET '"$$lib"' PROPERTY IMPORTED_LOCATION "'"$(PROJ_libdir)/lib$$lib.a"'")' ; \
|
||||
+ done && \
|
||||
+ cat "$(LLVMBuildCMakeExportsFrag)" \
|
||||
+ ) > $@
|
||||
+
|
||||
+all-local:: $(addprefix $(PROJ_OBJ_DIR)/, $(OBJMODS))
|
||||
+
|
||||
+SKIPSRCMODS := \
|
||||
+ CheckAtomic.cmake \
|
||||
+ GetHostTriple.cmake \
|
||||
+ LLVMBuildExports.cmake \
|
||||
+ LLVMConfig.cmake \
|
||||
+ LLVMConfigVersion.cmake \
|
||||
+ LLVMExports.cmake \
|
||||
+ VersionFromVCS.cmake
|
||||
+
|
||||
+SRCMODS := $(notdir $(wildcard $(PROJ_SRC_DIR)/*.cmake))
|
||||
+SRCMODS := $(filter-out $(SKIPSRCMODS),$(SRCMODS))
|
||||
+INSTSRCMODS := $(addprefix $(PROJ_cmake)/, $(SRCMODS))
|
||||
+INSTOBJMODS := $(addprefix $(PROJ_cmake)/, $(OBJMODS))
|
||||
+
|
||||
+$(PROJ_cmake):
|
||||
+ $(Echo) Making install directory: $@
|
||||
+ $(Verb) $(MKDIR) $@
|
||||
+
|
||||
+$(INSTSRCMODS): $(PROJ_cmake)/%.cmake: $(PROJ_SRC_DIR)/%.cmake | $(PROJ_cmake)
|
||||
+ $(Echo) Installing cmake modules: $(notdir $<)
|
||||
+ $(Verb) $(DataInstall) $< $(PROJ_cmake)
|
||||
+
|
||||
+$(INSTOBJMODS): $(PROJ_cmake)/%.cmake: $(PROJ_OBJ_DIR)/%.cmake | $(PROJ_cmake)
|
||||
+ $(Echo) Installing cmake modules: $(notdir $<)
|
||||
+ $(Verb) $(DataInstall) $< $(PROJ_cmake)
|
||||
+
|
||||
+install-local:: $(INSTSRCMODS) $(INSTOBJMODS)
|
||||
Index: cmake/Makefile
|
||||
===================================================================
|
||||
--- cmake/Makefile (revision 0)
|
||||
+++ cmake/Makefile (revision 201053)
|
||||
@@ -0,0 +1,12 @@
|
||||
+##===- cmake/Makefile --------------------------------------*- Makefile -*-===##
|
||||
+#
|
||||
+# The LLVM Compiler Infrastructure
|
||||
+#
|
||||
+# This file is distributed under the University of Illinois Open Source
|
||||
+# License. See LICENSE.TXT for details.
|
||||
+#
|
||||
+##===----------------------------------------------------------------------===##
|
||||
+LEVEL = ..
|
||||
+DIRS := modules
|
||||
+
|
||||
+include $(LEVEL)/Makefile.common
|
Loading…
Reference in a new issue