mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
gcc-arm-none-eabi: Initial gcc package for ARM Cortex-R/M
This commit is contained in:
parent
436069068b
commit
282aadc80f
72
packages/lang/gcc-arm-none-eabi/package.mk
Normal file
72
packages/lang/gcc-arm-none-eabi/package.mk
Normal file
@ -0,0 +1,72 @@
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
# Copyright (C) 2009-2016 Stephan Raue (stephan@openelec.tv)
|
||||
# Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv)
|
||||
|
||||
PKG_NAME="gcc-arm-none-eabi"
|
||||
PKG_VERSION="$(get_pkg_version gcc)"
|
||||
PKG_LICENSE="GPL-2.0-or-later"
|
||||
PKG_URL=""
|
||||
PKG_DEPENDS_HOST="toolchain:host ccache:host autoconf:host binutils-arm-none-eabi:host gmp:host mpfr:host mpc:host zstd:host"
|
||||
PKG_LONGDESC="This package contains the GNU Compiler Collection for ARM Cortex-R/M processors."
|
||||
PKG_DEPENDS_UNPACK+=" gcc"
|
||||
PKG_PATCH_DIRS+=" $(get_pkg_directory gcc)/patches"
|
||||
|
||||
PKG_CONFIGURE_OPTS_HOST="--target=arm-none-eabi \
|
||||
--with-sysroot=${SYSROOT_PREFIX} \
|
||||
--with-gmp=${TOOLCHAIN} \
|
||||
--with-mpfr=${TOOLCHAIN} \
|
||||
--with-mpc=${TOOLCHAIN} \
|
||||
--with-zstd=${TOOLCHAIN} \
|
||||
--with-gnu-as \
|
||||
--with-gnu-ld \
|
||||
--with-newlib \
|
||||
--without-ppl \
|
||||
--without-headers \
|
||||
--without-cloog \
|
||||
--enable-__cxa_atexit \
|
||||
--enable-checking=release \
|
||||
--enable-languages=c \
|
||||
--enable-ld=default \
|
||||
--enable-lto \
|
||||
--enable-plugin \
|
||||
--enable-static \
|
||||
--disable-decimal-float \
|
||||
--disable-gcov \
|
||||
--disable-libada \
|
||||
--disable-libatomic \
|
||||
--disable-libgomp \
|
||||
--disable-libitm \
|
||||
--disable-libmpx \
|
||||
--disable-libmudflap \
|
||||
--disable-libquadmath \
|
||||
--disable-libquadmath-support \
|
||||
--disable-libsanitizer \
|
||||
--disable-libssp \
|
||||
--disable-multilib \
|
||||
--disable-nls \
|
||||
--disable-shared \
|
||||
--disable-threads"
|
||||
|
||||
unpack() {
|
||||
mkdir -p ${PKG_BUILD}
|
||||
tar --strip-components=1 -xf ${SOURCES}/gcc/gcc-${PKG_VERSION}.tar.xz -C ${PKG_BUILD}
|
||||
}
|
||||
|
||||
post_makeinstall_host() {
|
||||
PKG_GCC_PREFIX="${TOOLCHAIN}/bin/arm-none-eabi-"
|
||||
GCC_VERSION=$(${PKG_GCC_PREFIX}gcc -dumpversion)
|
||||
DATE="0501$(echo ${GCC_VERSION} | sed 's/\./0/g')"
|
||||
CROSS_CC=${PKG_GCC_PREFIX}gcc-${GCC_VERSION}
|
||||
|
||||
rm -f ${PKG_GCC_PREFIX}gcc
|
||||
|
||||
cat > ${PKG_GCC_PREFIX}gcc <<EOF
|
||||
#!/bin/sh
|
||||
${TOOLCHAIN}/bin/ccache ${CROSS_CC} "\$@"
|
||||
EOF
|
||||
|
||||
chmod +x ${PKG_GCC_PREFIX}gcc
|
||||
|
||||
# To avoid cache trashing
|
||||
touch -c -t ${DATE} ${CROSS_CC}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user