clang: Depend on ndk-stl and remove triplet mess

This commit is contained in:
Fredrik Fornwall 2016-05-21 17:10:33 -04:00
parent 495c95e19d
commit 0b4923cdcf

View File

@ -2,11 +2,11 @@ TERMUX_PKG_HOMEPAGE=http://clang.llvm.org/
TERMUX_PKG_DESCRIPTION="C and C++ frontend for the LLVM compiler" TERMUX_PKG_DESCRIPTION="C and C++ frontend for the LLVM compiler"
_PKG_MAJOR_VERSION=3.8 _PKG_MAJOR_VERSION=3.8
TERMUX_PKG_VERSION=${_PKG_MAJOR_VERSION}.0 TERMUX_PKG_VERSION=${_PKG_MAJOR_VERSION}.0
TERMUX_PKG_BUILD_REVISION=3 TERMUX_PKG_BUILD_REVISION=4
TERMUX_PKG_SRCURL=http://llvm.org/releases/${TERMUX_PKG_VERSION}/llvm-${TERMUX_PKG_VERSION}.src.tar.xz TERMUX_PKG_SRCURL=http://llvm.org/releases/${TERMUX_PKG_VERSION}/llvm-${TERMUX_PKG_VERSION}.src.tar.xz
TERMUX_PKG_HOSTBUILD=true TERMUX_PKG_HOSTBUILD=true
TERMUX_PKG_RM_AFTER_INSTALL="bin/macho-dump bin/bugpoint bin/llvm-tblgen lib/BugpointPasses.so lib/LLVMHello.so" TERMUX_PKG_RM_AFTER_INSTALL="bin/macho-dump bin/bugpoint bin/llvm-tblgen lib/BugpointPasses.so lib/LLVMHello.so"
TERMUX_PKG_DEPENDS="binutils, libgnustl, ncurses, ndk-sysroot, libgcc" TERMUX_PKG_DEPENDS="binutils, libgnustl, ncurses, ndk-sysroot, ndk-stl, libgcc"
termux_step_post_extract_package () { termux_step_post_extract_package () {
CLANG_SRC_TAR=cfe-${TERMUX_PKG_VERSION}.src.tar.xz CLANG_SRC_TAR=cfe-${TERMUX_PKG_VERSION}.src.tar.xz
@ -38,12 +38,10 @@ termux_step_configure () {
LLVM_TARGET_ARCH=$TERMUX_ARCH LLVM_TARGET_ARCH=$TERMUX_ARCH
if [ $TERMUX_ARCH = "arm" ]; then if [ $TERMUX_ARCH = "arm" ]; then
LLVM_TARGET_ARCH=ARM LLVM_TARGET_ARCH=ARM
LLVM_DEFAULT_TARGET_TRIPLE="armv7a-linux-androideabihf"
elif [ $TERMUX_ARCH = "i686" ]; then elif [ $TERMUX_ARCH = "i686" ]; then
LLVM_TARGET_ARCH=X86 LLVM_TARGET_ARCH=X86
elif [ $TERMUX_ARCH = "aarch64" ]; then elif [ $TERMUX_ARCH = "aarch64" ]; then
LLVM_TARGET_ARCH=AArch64 LLVM_TARGET_ARCH=AArch64
LLVM_DEFAULT_TARGET_TRIPLE="aarch64-linux-android"
fi fi
# see CMakeLists.txt and tools/clang/CMakeLists.txt # see CMakeLists.txt and tools/clang/CMakeLists.txt
cmake -G "Unix Makefiles" .. \ cmake -G "Unix Makefiles" .. \