summaryrefslogtreecommitdiff
path: root/scripts/functions
AgeCommit message (Collapse)AuthorFilesLines
2010-10-03complibs: better deduce whether to backup complibs or notYann E. MORIN"1-6/+2
To decide whether we need to backup the companion libraries, do not rely on the !shared case. In the future other cases may require not to save the companion libraries (eg. if using the ones provided by the host distro). Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
2010-08-26scripts/log: do not interpret log string as printf formatYann E. MORIN"1-1/+1
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
2010-08-11scripts: in case of failed download, remove partial filesYann E. MORIN"1-2/+2
It happens from time to time that the server mis-behaves, and breaks the connection right in the middle of nowhere, for no good reason, leaving us with a partial file, on which the extract pass would choke. Remove partial downloads, to fail early. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
2010-08-11scripts: when downloading, use aria2 only when //Yann E. MORIN"1-1/+1
Even when // downloads are not enabled, aria2 can fail on some servers (eg. uclibc.org). Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
2010-07-30Fix CT_SanitizePathJohannes Stezenbach1-7/+5
Replace the over-engineered and buggy test in CT_SanitizePath with a straight forward string pattern match, and also handle empty PATH elements which are qeuivalent to ".". Thanks-To: Arnaud Lacombe <lacombar@gmail.com> Signed-off-by: Johannes Stezenbach <js@sig21.net>
2010-07-29scripts: remove . from $PATHYann E. MORIN"1-0/+18
Add CT_SanitizePath function which removes entries referring to ., /tmp and non-existing directories from $PATH, and call it early in the build script. If . is in PATH, gcc-4.4.4 build breaks: [ALL ] checking what assembler to use... /tmp/build/targets/arm-unknown-linux-uclibcgnueabi/build/gcc-core-static/arm-unknown-linux-uclibcgnueabi/bin/as ... [ALL ] config.status: creating as i.e. "as" is supposed to be the arm-unknown-linux-uclibcgnueabi cross assembler, but config.status creates a local "as" script which is calling the host assembler. Signed-off-by: Johannes Stezenbach <js@sig21.net> [Yann E. MORIN: style fixes + explanations] Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
2010-07-17scripts/functions: recognise Cygwin build hostsYann E. MORIN"1-1/+1
2010-05-19scripts/functions: Use stat correctly on non-GNU (BSD/Darwin) systems.Titus von Boxberg1-1/+11
Call to get the directory mode depending on $CT_SYS_OS yann.morin.1998@anciens.enib.fr: CT_SYS_OS has changed on Linuxsystem, it only gets the kernel name "Linux", and not the system name, 'GNU/'.
2010-04-13scripts/functions: log the test stringsYann E. MORIN"1-0/+3
2010-04-13scripts/functions: compress with gzip level 3, as stated in the documentationYann E. MORIN"1-8/+12
Thanks to Bruno Tarquini <btarquini@gmail.com> for the report.
2010-04-13scripts/functions: add a save/restore handlerYann E. MORIN"1-62/+62
Saving and restoring the steps requires saving/restoring multiple directories. Depending on the configuration, some may not exist. Add a wrapper that checks before creating/extracting the tarballs.
2010-04-13scripts/functions: fix CT_Patch againYann E. MORIN"1-4/+6
2010-04-12scripts/functions: fix CT_PatchYann E. MORIN"1-2/+2
2010-04-11scripts/functions: make CT_Patch dumberYann E. MORIN"1-20/+25
It is the responsibility of the caller to split the package name from its version. It already knows that.
2010-04-09scripts: prevent trailing - in CT_TARGETBart vdr Meulen1-4/+4
Not all target tuples consist of an VENDOR, KERNEL and SYSTEM part, build up the tuple in such a way to no extra or trailing dashes are added to CT_TARGET Signed-off-by: Bart vdr Meulen <bartvdrmeulen@gmail.com>
2010-04-11complibs: save directory with static complibs for stop/restartYann E. MORIN"1-0/+14
2010-02-02scripts/functions: fix date munging when ns are not availableTitus von Boxberg1-1/+1
On some systems (eg. *BSD and Darwin), date does not support nanoseconds (%N) precision. Instead of printing '%N' in this case, it just prints 'N'. Fix the sed expression to handle this case.
2010-01-31scripts: Do not create backup files when patchingYann E. MORIN"1-1/+1
Some patches may apply with offset and/or fuzz, and would leave .orig files.
2010-01-14scripts/functions: add git wrapperYann E. MORIN"1-6/+88
Add a git wrapper to retrieve components from their git tree. Add a git wrapper to create a working copy (in our tarballs dir). Recognise git trees when searching for local copies.
2010-01-12scripts/functions: change handling of nochdirYann E. MORIN"1-12/+34
- 'nochdir' must be the first option - have systematic pushd/popd, even if nochdir
2010-01-23scripts/functions: do not compute CT_KERNEL_ARCH, it's obsoleteYann E. MORIN"1-3/+0
Since we merged the 32/64-bit archs, and we explicitly used the Linux kernel arch name, we can get rid of CT_KERNEL_ARCH.
2010-01-16scripts/functions: inverse log level ALL and DEBUGYann E. MORIN"1-2/+2
2010-01-10scrips/functions: fix downloads using curlRichard Strand1-2/+2
By default curl doesn't folow redirects. This breaks sourceforge downloads. Add the -L option to curl to fix this. Curl also downloads the html as a file even when it gets a 404. This breaks http downloads when using the failback system. Add the -f option to curl to fix this. Signed-off-by: Richard Strand <richard.strand@icomera.com>
2010-01-09scripts/functions: fix extractionYann E. MORIN"1-7/+7
2010-01-07config: don't force the vendor part in the tupleYann E. MORIN"1-2/+4
Note however that some configurations (eg. arm-elf) will still have the vendor part 'unknown' forced in (by config.sub).
2009-11-30scripts: protect against partially extracted sourceYann E. MORIN"1-0/+11
In case of failure (eg. user hitting Ctrl-C), avoid extracting over partially extracted source. Will help once we have git available.
2009-11-29scripts: handle custom or empty extension when extractingYann E. MORIN"1-8/+10
2009-11-25scripts/functions: do not double check if downloads are allowedYann E. MORIN"1-9/+0
Only call the *_get functions if downloads are allowed, so there is no need to check it again in the retrieval wrappers.
2010-01-03scripts/functions: make aria2 less verbose when downloadingYann E. MORIN"1-2/+2
2010-01-01scripts/functions: fix downloading with aria2Yann E. MORIN"1-1/+1
In case the remote file does not exist (and probably for some other reasons as well), aria2 nonetheless creates an empty file (or not empty for some other reasons). The solution is to delete the file whenever aria2 fails.
2010-01-01scripts/functions: fix using Aria2Yann E. MORIN"1-2/+2
Latest aria2 no longer recognise the --retry-wait option.
2009-12-30scripts/functions: add aria2, a powerfull downloaderYann E. MORIN"1-2/+21
aria2 is a powerfull downloader that is capable of chunking and parallel retrieval. Due to li;itations in crosstool-NG retrieval facilities, it's not possible to take fully advantage of aria2. It might happen that, in the future, those limitations get lifted away, so we can take use features such as parallel downloading from more than one server at the same time. For now, it should still speed up downloads thanks to parallel downloading of chunks.
2009-12-29scripts/functions: simplify wget vs. curl checkYann E. MORIN"1-5/+7
2009-11-16config/global: enable not using patches at allYann E. MORIN"1-0/+1
It can be needed to build a toolchain with no patch at all.
2009-10-26libc/newlib: allow using CVS snapshotsYann E. MORIN"1-2/+2
The newlib "team" rolls new releases about once a year (december). This is quite a long time between releases, in case code was fixed. So, allow user to use a CVS snapshot to benefit early from fixes and enhancements to newlib.
2009-10-26functions: allow using sub-dir of a moduleYann E. MORIN"1-3/+14
Some projects' module (eg. newlib) are checked-out into a sudirectory rather than into their own directory. Handle this case in the CT_GetCVS function.
2009-10-21libc/newlib: allow using newlib with archs other than avr32Yann E. MORIN"1-1/+1
2009-10-23scripts/functions: Fix a variable name.Frederic Roussel1-1/+1
Signed-off-by: Frederic Roussel <fr.frasc@gmail.com>
2009-09-06log functions: fix CT_DoLog and CT_DoExecLogYann E. MORIN"1-2/+2
$@ and $* are different when in double quotes; use $* to print the message.
2009-08-31config: add fallback to patch orderYann E. MORIN"1-0/+3
Add the possibility to fallback to either bundled or local patches if local or bundled are missing.
2009-08-31config: add the local,bundled patch orderYann E. MORIN"1-0/+1
This ordering first applies the local patches, then the bundeld ones.
2009-08-31config: make selecting the patch origin a choice rather than a boolYann E. MORIN"1-9/+17
2009-08-31functions: do not over-detect error when patchingYann E. MORIN"1-1/+0
2009-06-22[functions] Allow newlines (\n) in log messagesYann E. MORIN"1-1/+1
Allow caller to log messages with embedded newlines when calling CT_DoLog and other logging functions (eg. CT_Abort...).
2009-05-27/devel/gcc-4.4:Yann E. MORIN"1-0/+30
- functions: add a utility function that sets and exports LD_LIBRARY_PATH -------- diffstat follows -------- /devel/gcc-4.4/scripts/functions | 30 30 0 0 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+)
2009-04-20There's no longer any reason to require GNU awk:Yann E. MORIN"1-2/+2
- the only part that required it (socks proxy settings) is gone, - all remaining awk scripts are POSIXly correct (or should be). -------- diffstat follows -------- /trunk/configure | 5 2 3 0 ++--- /trunk/Makefile.in | 2 0 2 0 -- /trunk/scripts/build/kernel/linux.sh | 2 1 1 0 +- /trunk/scripts/build/internals.sh | 1 0 1 0 - /trunk/scripts/build/mpfr.sh | 2 1 1 0 +- /trunk/scripts/functions | 4 2 2 0 ++-- /trunk/scripts/saveSample.sh.in | 4 2 2 0 ++-- 7 files changed, 8 insertions(+), 12 deletions(-)
2009-04-19Simplify the mirror settings.Yann E. MORIN"1-4/+3
-------- diffstat follows -------- /trunk/scripts/functions | 7 3 4 0 ++--- /trunk/config/global/download.in | 60 14 46 0 +++++++++++----------------------------------- 2 files changed, 17 insertions(+), 50 deletions(-)
2009-04-19Get rid of the proxy settings, once and for all.Yann E. MORIN"1-100/+0
They have nothing to do in here, just let the user configure his/her system appropriately. -------- diffstat follows -------- /trunk/scripts/build/libc/eglibc.sh | 1 0 1 0 - /trunk/scripts/functions | 100 0 100 0 ----------------------------- /trunk/config/global/download.in | 148 0 148 0 ------------------------------------------- 3 files changed, 249 deletions(-)
2009-04-06Use "${awk}", not gawk.Yann E. MORIN"1-2/+2
/trunk/scripts/build/kernel/linux.sh | 2 1 1 0 +- /trunk/scripts/build/mpfr.sh | 2 1 1 0 +- /trunk/scripts/functions | 4 2 2 0 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)
2009-03-27Only create the state dir if asked for a restartable build:Yann E. MORIN"1-3/+12
- introduce the config dir, where components can store their config files - move the munged uClibc config file to the config dir - now, the state dir really is an indication that a build can be restarted Thanks to Groleo Marius <groleo@gmail.com> for spotting the inconsistency of the state dir usage, and suggesting this change. /trunk/scripts/build/libc/uClibc.sh | 6 3 3 0 +++--- /trunk/scripts/crosstool-NG.sh.in | 9 7 2 0 +++++++-- /trunk/scripts/functions | 15 12 3 0 ++++++++++++--- 3 files changed, 22 insertions(+), 8 deletions(-)