# HG changeset patch # User Christophe Lincoln # Date 1393623462 -3600 # Node ID 7e8a95a52792d8825affc057e3913fd25a541ab9 # Parent 13f7bca6b626c8bffba1644ddcc9ddf1c852b679 binutils: add to ARM arch and clean receipt diff -r 13f7bca6b626 -r 7e8a95a52792 binutils/receipt --- a/binutils/receipt Fri Feb 28 22:12:49 2014 +0100 +++ b/binutils/receipt Fri Feb 28 22:37:42 2014 +0100 @@ -12,59 +12,29 @@ #WGET_URL="http://www.kernel.org/pub/linux/devel/binutils/$TARBALL" PROVIDE="libbfd" TAGS="assembler linker" +HOST_ARCH="i486 arm" DEPENDS="glibc zlib" BUILD_DEPENDS="glibc-dev zlib-dev" -# Rules to compile & install the temporary toolchain. -precook_tmp_toolchain() -{ - mkdir -p binutils-build && cd binutils-build - { $src/configure \ - --target=$HOST_SYSTEM --disable-nls \ - --disable-werror && - make - } || return 1 - - #If building on x86_64, create a symlink to ensure the sanity of the toolchain. - [ "$ARCH" = x86_64 ] && mkdir /tools/lib && ln -s lib /tools/lib64 - - make install -} - -cook_tmp_toolchain() -{ - mkdir -p binutils-build && cd binutils-build - { CC="$HOST_SYSTEM-gcc -B/tools/lib/" \ - AR=$HOST_SYSTEM-ar RANLIB=$HOST_SYSTEM-ranlib \ - $src/configure $CONFIGURE_ARGS \ - --disable-nls --with-lib-path=/tools/lib && - make && - make install && - make -C ld clean && - make -C ld LIB_PATH=/usr/lib:/lib - } || return 1 - cp ld/ld-new /tools/bin -} +# Handle cross compilation. +case "$ARCH" in + arm) BUILD_DEPENDS="" ;; +esac # Rules to configure and make the package. compile_rules() { - cd $src - - # Handle ARCH type - case $ARCH in - i?86) - EXTRA_ARGS="--disable-werror" ;; + case "$ARCH" in + i?86) ARCH_ARGS="--disable-werror" ;; esac - mkdir -p ../binutils-build && cd ../binutils-build $src/configure \ --program-prefix=$TOOLPREFIX \ --enable-shared \ --disable-initfini-array \ --with-bugurl="http://bugs.slitaz.org/" \ - $CONFIGURE_ARGS $EXTRA_ARGS && + $CONFIGURE_ARGS $ARCH_ARGS && make tooldir=/usr && make tooldir=/usr install && # This is the default binutils, so create symlinks to the target platform