summaryrefslogtreecommitdiff
path: root/package
diff options
context:
space:
mode:
authorYann E. MORIN <yann.morin.1998@anciens.enib.fr>2011-07-15 00:24:07 +0200
committerPeter Korsgaard <jacmet@sunsite.dk>2011-07-15 22:58:38 +0200
commitbef98b7c10a9969bc3f8b977dd9e0bdafba684a3 (patch)
tree7f95a0993b9b365d7bb28b4147f57746aa73625c /package
parent6d5f6c2cfbc2f0b48704fe99a5b618a594033f80 (diff)
toolchain/crosstool-NG: use the package infrastructure
Move crosstool-NG to package/ and make it an autotarget package. This requires a new patch (now upstream). Now, the crosstool-NG toolchain backend only contains enough to build the toolchain, there's no more reference to building crosstool-NG as a package. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'package')
-rw-r--r--package/crosstool-ng/crosstool-ng-001-no-cvs.patch15
-rw-r--r--package/crosstool-ng/crosstool-ng-002-dont-break-on-existing-symlinks-and-build.log.patch76
-rw-r--r--package/crosstool-ng/crosstool-ng-003-autostuf-compat.patch10
-rw-r--r--package/crosstool-ng/crosstool-ng.mk9
4 files changed, 110 insertions, 0 deletions
diff --git a/package/crosstool-ng/crosstool-ng-001-no-cvs.patch b/package/crosstool-ng/crosstool-ng-001-no-cvs.patch
new file mode 100644
index 000000000..c82d35941
--- /dev/null
+++ b/package/crosstool-ng/crosstool-ng-001-no-cvs.patch
@@ -0,0 +1,15 @@
+Remove dependency on cvs.
+
+cvs is used to retrieve newlib, which is not supported
+under Buildroot, so cvs is not required.
+
+--- crosstool-ng-1.8.0/configure.orig 2010-11-27 15:43:52.000000000 +0000
++++ crosstool-ng-1.8.0/configure 2010-11-27 15:44:10.000000000 +0000
+@@ -359,7 +359,6 @@
+ err="'libtool' 1.5.26 or above was not found"
+ has_or_abort prog=stat
+ has_or_abort prog="curl wget"
+-has_or_abort prog=cvs
+ has_or_abort prog=patch
+ has_or_abort prog=tar
+ has_or_abort prog=gzip
diff --git a/package/crosstool-ng/crosstool-ng-002-dont-break-on-existing-symlinks-and-build.log.patch b/package/crosstool-ng/crosstool-ng-002-dont-break-on-existing-symlinks-and-build.log.patch
new file mode 100644
index 000000000..2bb613ffb
--- /dev/null
+++ b/package/crosstool-ng/crosstool-ng-002-dont-break-on-existing-symlinks-and-build.log.patch
@@ -0,0 +1,76 @@
+
+# HG changeset patch
+# User "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
+# Date 1310507544 -7200
+# Node ID 1ebc2248cc60230cd53ff94ae8f8f1e3261461a3
+# Parent f1c730da41f3b22ca1a1e1b14592da4b7c078797
+scripts, cc/gcc: do not fail on existing symlinks or build.log
+
+If the user builds a toolchain over an existing one, so, without removing
+CT_PREFIX_DIR, the build fails as the symlinks already exist, as does the
+build.log.
+
+This can also happen (for build.log) if the user first ran in download-
+or extract-only.
+
+Patch (with no SoB) originally from:
+ Phil Wilshire <phil.wilshire@overturenetworks.com>
+
+Modified by me as it did not apply cleanly.
+
+Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
+
+diff -r f1c730da41f3 -r 1ebc2248cc60 scripts/build/cc/gcc.sh
+--- a/scripts/build/cc/gcc.sh Tue Jul 12 23:21:27 2011 +0200
++++ b/scripts/build/cc/gcc.sh Tue Jul 12 23:52:24 2011 +0200
+@@ -386,7 +386,7 @@
+ # check whether compiler has an extension
+ file="$( ls -1 "${core_prefix_dir}/bin/${CT_TARGET}-gcc."* 2>/dev/null || true )"
+ [ -z "${file}" ] || ext=".${file##*.}"
+- CT_DoExecLog ALL ln -sv "${CT_TARGET}-gcc${ext}" "${core_prefix_dir}/bin/${CT_TARGET}-cc${ext}"
++ CT_DoExecLog ALL ln -sfv "${CT_TARGET}-gcc${ext}" "${core_prefix_dir}/bin/${CT_TARGET}-cc${ext}"
+
+ CT_EndStep
+ }
+@@ -630,7 +630,7 @@
+ # check whether compiler has an extension
+ file="$( ls -1 "${CT_PREFIX_DIR}/bin/${CT_TARGET}-gcc."* 2>/dev/null || true )"
+ [ -z "${file}" ] || ext=".${file##*.}"
+- CT_DoExecLog ALL ln -sv "${CT_TARGET}-gcc${ext}" "${CT_PREFIX_DIR}/bin/${CT_TARGET}-cc${ext}"
++ CT_DoExecLog ALL ln -sfv "${CT_TARGET}-gcc${ext}" "${CT_PREFIX_DIR}/bin/${CT_TARGET}-cc${ext}"
+
+ CT_EndStep
+ }
+diff -r f1c730da41f3 -r 1ebc2248cc60 scripts/build/internals.sh
+--- a/scripts/build/internals.sh Tue Jul 12 23:21:27 2011 +0200
++++ b/scripts/build/internals.sh Tue Jul 12 23:52:24 2011 +0200
+@@ -86,14 +86,14 @@
+ for t in "${CT_TARGET}-"*; do
+ if [ -n "${CT_TARGET_ALIAS}" ]; then
+ _t=$(echo "$t" |sed -r -e 's/^'"${CT_TARGET}"'-/'"${CT_TARGET_ALIAS}"'-/;')
+- CT_DoExecLog ALL ln -sv "${t}" "${_t}"
++ CT_DoExecLog ALL ln -sfv "${t}" "${_t}"
+ fi
+ if [ -n "${CT_TARGET_ALIAS_SED_EXPR}" ]; then
+ _t=$(echo "$t" |sed -r -e "${CT_TARGET_ALIAS_SED_EXPR}")
+ if [ "${_t}" = "${t}" ]; then
+ CT_DoLog WARN "The sed expression '${CT_TARGET_ALIAS_SED_EXPR}' has no effect on '${t}'"
+ else
+- CT_DoExecLog ALL ln -sv "${t}" "${_t}"
++ CT_DoExecLog ALL ln -sfv "${t}" "${_t}"
+ fi
+ fi
+ done
+diff -r f1c730da41f3 -r 1ebc2248cc60 scripts/crosstool-NG.sh.in
+--- a/scripts/crosstool-NG.sh.in Tue Jul 12 23:21:27 2011 +0200
++++ b/scripts/crosstool-NG.sh.in Tue Jul 12 23:52:24 2011 +0200
+@@ -604,7 +604,7 @@
+ # moment... Consign all ouptut to oblivion...
+ CT_DoLog INFO "Finishing installation (may take a few seconds)..."
+ exec >/dev/null 2>&1
+-
++rm -f ${CT_PREFIX_DIR}/build.log.bz2
+ if [ "${CT_LOG_TO_FILE}" = "y" ]; then
+ cp "${tmp_log_file}" "${CT_PREFIX_DIR}/build.log"
+ if [ "${CT_LOG_FILE_COMPRESS}" = y ]; then
+
diff --git a/package/crosstool-ng/crosstool-ng-003-autostuf-compat.patch b/package/crosstool-ng/crosstool-ng-003-autostuf-compat.patch
new file mode 100644
index 000000000..d79e62bac
--- /dev/null
+++ b/package/crosstool-ng/crosstool-ng-003-autostuf-compat.patch
@@ -0,0 +1,10 @@
+--- crosstool-ng-1.11.3/configure 2011-05-21 01:10:10.000000000 +0200
++++ host-crosstool-ng-1.11.3/configure 2011-07-14 17:35:25.830403914 +0200
+@@ -260,6 +260,7 @@
+ # Skip, auto-stuff compatibility
+ --build=*|--host=*|--infodir=*|--datadir=*|--sysconfdir=*|--localstatedir=*) shift;;
+ --build|--host|--infodir|--datadir|--sysconfdir|--localstatedir) shift 2;;
++ --enable-shared|--disable-shared|--enable-static|--disable-static) shift;;
+ *) printf "Unrecognised option: '${1}'\n"; do_help; exit 1;;
+ esac
+ done
diff --git a/package/crosstool-ng/crosstool-ng.mk b/package/crosstool-ng/crosstool-ng.mk
new file mode 100644
index 000000000..b40cf353b
--- /dev/null
+++ b/package/crosstool-ng/crosstool-ng.mk
@@ -0,0 +1,9 @@
+CROSSTOOL_NG_VERSION = 1.11.3
+CROSSTOOL_NG_SOURCE = crosstool-ng-$(CROSSTOOL_NG_VERSION).tar.bz2
+CROSSTOOL_NG_SITE = http://crosstool-ng.org/download/crosstool-ng/
+CROSSTOOL_NG_INSTALL_STAGING = NO
+CROSSTOOL_NG_INSTALL_TARGET = NO
+CROSSTOOL_NG_MAKE = $(MAKE1)
+HOST_CROSSTOOL_NG_DEPENDENCIES = host-gawk host-automake $(if $(BR2_CCACHE),host-ccache)
+
+$(eval $(call AUTOTARGETS,package,crosstool-ng,host))