Browse Source

d/newlib-arm-none-eabi: Removed.

current-20191101
Damien Goutte-Gattat 2 years ago
parent
commit
ddf0df955c
  1. 1
      d/newlib-arm-none-eabi/gcc-6.3.1svn253039.tar.xz.sha256
  2. 1
      d/newlib-arm-none-eabi/newlib-2.4.0.20160527.tar.gz.sha256
  3. 173
      d/newlib-arm-none-eabi/newlib-arm-none-eabi.SlackBuild
  4. 12
      d/newlib-arm-none-eabi/slack-desc

1
d/newlib-arm-none-eabi/gcc-6.3.1svn253039.tar.xz.sha256

@ -1 +0,0 @@
6f940fdd70fbfe9452177a773cb3f0c144a72ead29943719f55d90c0f44bc578 gcc-6.3.1svn253039.tar.xz

1
d/newlib-arm-none-eabi/newlib-2.4.0.20160527.tar.gz.sha256

@ -1 +0,0 @@
46a48b10415d4f27d1574a3eaf91ee25b8bdc9b6ae173ad4a3bd88a90c324367 newlib-2.4.0.20160527.tar.gz

173
d/newlib-arm-none-eabi/newlib-arm-none-eabi.SlackBuild

@ -1,173 +0,0 @@
#!/bin/bash
# Build script for Slackware
# Copyright (C) 2018 Damien Goutte-Gattat
#
# Redistribution and use of this script, with or without modifications,
# is permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AS IS'' AND ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
# INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
# IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
#
# Contact: Damien Goutte-Gattat <dgouttegattat@incenp.org>
#
# Latest newlib sourcecode is available at: <http://sourceware.org/>.
#
# Depends: d/binutils-arm-none-eabi
# Source package infos
NAMESRC=${NAMESRC:-newlib}
VERSION=${VERSION:-2.4.0.20160527}
ARCHIVE=${ARCHIVE:-$NAMESRC-$VERSION.tar.gz}
WGET=${WGET:-ftp://sourceware.org/pub/newlib/$ARCHIVE}
GCC_VERSION=${GCC_VERSION:-6.3.1}
GCC_REVISION=${GCC_REVISION:-253039}
# Build infos
NAMEPKG=${NAMEPKG:-newlib-arm-none-eabi}
BUILD=${BUILD:-1GGD}
ARCH=${ARCH:-$(uname -m | sed 's/^i.86$/i486/;s/^arm.*/arm/')}
JOBS=${JOBS:-1}
EXT=${EXT:-txz}
# Directories
TMP=${TMP:-/tmp}
OUT=${OUT:-$TMP/build}
PKG=${PKG:-$OUT/$NAMEPKG}
CWD=$(pwd)
set -e # Quit if a command returns non-zero
# Sanity checks
if [ $UID -eq 0 ]; then
echo "You should NOT run this script as ROOT!"
exit 1
fi
if [ ! -d $TMP ]; then
echo "$TMP does not exists or is not a directory!"
exit 1
fi
# Get and verify the source archive
if [ ! -r $ARCHIVE ]; then
wget -c -O $ARCHIVE.part "$WGET"
mv $ARCHIVE.part $ARCHIVE
fi
sha256sum -c $ARCHIVE.sha256
NAME=$(tar ft $ARCHIVE | head -n 1 | cut -d / -f 1)
# Get source archive for GCC
NAMEGCC=gcc-${GCC_VERSION}svn$GCC_REVISION
if [ ! -r $NAMEGCC.tar.xz ]; then
svn co svn://gcc.gnu.org/svn/gcc/branches/ARM/embedded-6-branch@$GCC_REVISION $NAMEGCC
tar -c --xz \
--exclude=".svn" \
--exclude="libffi" \
--exclude="libgomp" \
--exclude="libquadmath" \
--exclude="libssp" \
--exclude="libada" \
--exclude="libgfortran" \
--exclude="libcilkrts" \
--exclude="libgo" \
--exclude="libjava" \
--exclude="zlib" \
--exclude="gcc/testsuite/ada" \
--exclude="gcc/testsuite/gfortran.dg" \
--exclude="gcc/testsuite/gfortran.fortran-torture" \
--exclude="gcc/testsuite/go.dg" \
--exclude="gcc/testsuite/go.go-torture" \
--exclude="gcc/testsuite/go.test" \
--exclude="gcc/testsuite/objc" \
--exclude="gcc/testsuite/obj-c++.dg" \
--exclude="gcc/testsuite/objc.dg" \
--exclude="gcc/testsuite/objc-obj-c++-shared" \
--exclude="gcc/ada/doc" \
-f $NAMEGCC.tar.xz $NAMEGCC
rm -rf $NAMEGCC
fi
sha256sum -c $NAMEGCC.tar.xz.sha256
# Compile 1st stage GCC
cd $TMP
echo "Building $NAMEGCC.tar.xz..."
tar xf $CWD/$NAMEGCC.tar.xz
cd $NAMEGCC
./configure \
--build=$ARCH-slackware-linux \
--target=arm-none-eabi \
--prefix=$TMP/gccstage1 \
--with-sysroot=/usr/arm-none-eabi \
--enable-languages=c \
--disable-decimal-float \
--disable-libffi \
--disable-libgomp \
--disable-libmudflap \
--disable-libquadmath \
--disable-libssp \
--disable-libstdcxx-pch \
--disable-nls \
--disable-shared \
--disable-threads \
--disable-tls \
--with-newlib \
--without-headers \
--with-gnu-as \
--with-gnu-ld \
--with-python-dir=share/gcc-arm-none-eabi
make -j $JOBS all-gcc
make install-gcc
ln -s /usr/bin/arm-none-eabi-as $TMP/gccstage1/bin/as
export PATH=$TMP/gccstage1/bin:$PATH
# Compile newlib
cd $TMP
echo "Building $ARCHIVE..."
tar xf $CWD/$ARCHIVE
cd $NAME
./configure \
--build=$ARCH-slackware-linux \
--target=arm-none-eabi \
--prefix=/usr \
--enable-newlib-io-long-long \
--enable-newlib-register-fini \
--enable-newlib-retargetable-locking \
--disable-newlib-supplied-syscalls \
--disable-nls \
--with-build-sysroot=$TMP/gccstage1
make -j $JOBS
make install DESTDIR=$PKG
# Copy slack-desc file
install -D -m 644 $CWD/slack-desc $PKG/install/slack-desc
# Add dependency infos
cat <<EOF > $PKG/install/slack-required
binutils-arm-none-eabi
EOF
# Package the tree
cd $PKG
mkdir -p $OUT
PACKAGING="
chown root:root . -R
/sbin/makepkg -l y -c n $OUT/$NAMEPKG-$VERSION-$ARCH-$BUILD.$EXT
rm -rf $PKG
rm -rf $TMP/$NAME $TMP/$NAMEGCC $TMP/gccstage1
"
if type -p fakeroot ; then
echo "$PACKAGING" | fakeroot
else
su -c "$PACKAGING"
fi

12
d/newlib-arm-none-eabi/slack-desc

@ -1,12 +0,0 @@
|-----handy-ruler-----------------------------------------------------|
newlib-arm-none-eabi: newlib-arm-none-eabi (C library for ARM)
newlib-arm-none-eabi:
newlib-arm-none-eabi: This is newlib, a simple ANSI C library, math library, and
newlib-arm-none-eabi: collection of board support packages, targeting the ARM
newlib-arm-none-eabi: architecture.
newlib-arm-none-eabi:
newlib-arm-none-eabi:
newlib-arm-none-eabi:
newlib-arm-none-eabi:
newlib-arm-none-eabi:
newlib-arm-none-eabi:
Loading…
Cancel
Save