aboutsummaryrefslogtreecommitdiff
path: root/scripts/build/libc/newlib.sh
Commit message (Collapse)AuthorAgeFilesLines
* Disable implicit-function-declaration error for newlibNik Konyuchenko2024-05-181-0/+3
| | | | | | | | | GCC14 will treat implicit-function-declaration as an error by default. See https://gcc.gnu.org/gcc-14/porting_to.html for details. Some libc function like __trap34 are defined in assembly and break this GCC diagnostic. Signed-off-by: Nik Konyuchenko <spaun2002mobile@gmail.com>
* Fold libc_start_files into libcAlexey Neyman2022-02-111-4/+3
| | | | | | | | | | | | | | | | | | | | | | After 557b9d4, libc_start_files and libc_main steps are performed one after another. It doesn't make sense, especially since some of the libcs (glibc, uClibc-ng) go to great lengths to first install start files in the first step, libc_start_files, only to remove them immediately in the second step, libc_main. Current build steps also break in the xtensa newlib configurations, as it needs to install the custom xtensa headers before building the libgcc and after 557b9d4, the headers are not installed before libgcc is built in pass-1. Therefore, finish what 557b9d4 mentioned but did not do: move header installation into a new step, libc_headers, and combine libc_start_files and libc_main into a single step. This also allows to combine the core pass-1/pass-2 steps, to be done in a subsequent commit. Signed-off-by: Alexey Neyman <stilor@att.net>
* Merge pull request #1274 from maxmorozov/masterAlexey Neyman2020-01-211-1/+3
|\ | | | | CT_LIBC_NEWLIB_REGISTER_FINI is processed correctly
| * CT_LIBC_NEWLIB_FSEEK_OPTIMIZATION and CT_LIBC_NEWLIB_FVWRITE_IN_STREAMIO are ↵Morozov Max2019-11-041-0/+2
| | | | | | | | took into account now
| * CT_LIBC_NEWLIB_REGISTER_FINI is processed correctlyMorozov Max2019-11-041-1/+1
| |
* | Add newlib retargetable locking configurationStephanos Ioannidis2019-12-201-0/+1
|/ | | | | | | This commit adds support for the newlib configuration option '--enable-newlib-retargetable-locking'. Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
* Rename JOBSFLAGS -> CT_JOBSFLAGSAlexey Neyman2019-04-041-1/+1
| | | | | | ... so that it is saved/restored when restarting the build. Signed-off-by: Alexey Neyman <stilor@att.net>
* Add moxiebox as a choice for libcAlexey Neyman2018-12-011-16/+6
| | | | | | | | | | | | | | | | | This required some rework of the libc selection, as moxiebox is a layer on top of another libc - newlib. Also, moxiebox'es host VM (`sandbox`) needs a libcrypto on the host. We will not have it if we're cross-compiling a canadian cross. Fortunately, all moxiebox needs from libcrypto is SHA256, and it already includes a standalone implementation of SHA256 in its runtime. Provide a little wrapper that allows moxiebox use that implementation for the host binary, too. Also, automate collecting/printing the list of all packages in a given category (e.g. LIBC or COMP_TOOLS), generate a list of all Kconfig symbols for a given category. Signed-off-by: Alexey Neyman <stilor@att.net>
* Merge pull request #984 from slash3g/masterAlexey Neyman2018-09-251-4/+4
|\ | | | | Properly handle newlib configuration flags
| * Properly handle newlib configuration flagsDaniele Baracchi2018-06-111-4/+4
| |
* | Merge pull request #990 from antmak/fix_newlib_multilib_optAlexey Neyman2018-09-211-1/+1
|\ \ | |/ |/| Fix a wrong name for the newlib's multilib option
| * Fix a wrong name for the newlib's multilib optionAnton Maklakov2018-06-151-1/+1
| |
* | Avoid adding arch/cpu/tune flags for target to GCC buildAlexey Neyman2018-06-051-1/+1
|/ | | | | | ... as it may need to override them for building runtime-selectable code. Signed-off-by: Alexey Neyman <stilor@att.net>
* Separate the notions of package name/labelAlexey Neyman2017-07-081-1/+0
| | | | | | Also, remove resolved TBDs. Signed-off-by: Alexey Neyman <stilor@att.net>
* Kconfigize choice/menu itemsAlexey Neyman2017-07-081-1/+1
| | | | | | Also, add a poor man's upgrade script. Signed-off-by: Alexey Neyman <stilor@att.net>
* Fix the references to old config variablesAlexey Neyman2017-07-081-29/+6
| | | | Signed-off-by: Alexey Neyman <stilor@att.net>
* Run all configure scripts using ${CONFIG_SHELL}Alexey Neyman2017-01-251-0/+1
| | | | | | ... as its help message says in menuconfig. Signed-off-by: Alexey Neyman <stilor@att.net>
* Merge pull request #526 from stilor/double-includeAlexey Neyman2017-01-131-7/+1
|\ | | | | Avoid creating include/include
| * AVR32 support has been retired.Alexey Neyman2017-01-121-4/+0
| | | | | | | | | | | | Scripts no longer download avr-headers. Signed-off-by: Alexey Neyman <stilor@att.net>
| * install_root has no effect on newlib install.Alexey Neyman2017-01-121-1/+1
| | | | | | | | | | | | | | And never had, at least since newlib 1.17 (first version added to crosstool-ng). Apparently, copy-pasted from glibc.sh. Signed-off-by: Alexey Neyman <stilor@att.net>
| * Remove 2nd copy of the option.Alexey Neyman2017-01-121-2/+0
| | | | | | | | | | | | Added above, as part of the list. Signed-off-by: Alexey Neyman <stilor@att.net>
* | Unify fetching Linaro components.Alexey Neyman2017-01-121-9/+12
|/ | | | | | Add CT_GetLinaro, use it from gcc/binutils/gdb/glibc/newlib. Signed-off-by: Alexey Neyman <stilor@att.net>
* Support building Newlib with Link Time OptimisationAlastair D'Silva2017-01-101-10/+13
| | | | Signed-off-by: Alastair D'Silva <alastair@d-silva.org>
* Add more newlib optionsAlastair D'Silva2017-01-101-16/+33
|
* Partially revert 6f8e89cb5ca061e899bf3feaaf3fecf30d366c3e.Alexey Neyman2016-11-201-5/+5
| | | | | | | | | | | | | | | | | | The referenced commit replaced 'make' with '${make}' everywhere. This is wrong for at least the utilities that we may build as companion tools (make, libtool): this will always invoke the version detected by configure by supplying the absolute path. In other words, the wrappers in .build/tools/bin are not fallbacks - they are either temporary (in case a respective companion tool is built) or permanent redirectors. This is the reason why the PATH= has .build/*/buildtools/bin at higher precedence than .build/tools/bin; the latter has the versions detected by configure and the former has the versions built as companion tools. Revert the rest of the gang (grep/sed/...) for consistency. After all, we may decide to supply some of them as well (awk, for instance). Signed-off-by: Alexey Neyman <stilor@att.net>
* libc/*.sh: Deprecate libc_check_config step.Alexey Neyman2016-08-231-4/+0
| | | | | | | | | | | | | | | | | | This step was only used in uClibc. However, with upcoming multilib, the config management will have to be done for each variant differently, anyway. uClibc was the only user of libc_check_config step, as well as CT_CONFIG_DIR directory. Retire these. Two other clean-ups in uClibc.sh: - KERNEL_HEADERS check seems to be bogus, this config option is not present even in 0.9.30 - which is not supported already. - SHARED_LIB_LOADER_PREFIX was renamed to MULTILIB_DIR in 0.9.31, according to ChangeLog - and MULTILIB_DIR is passed from command line instead. Signed-off-by: Alexey Neyman <stilor@att.net>
* newlib: add option to enable nano formatted ioBryan Hundven2016-03-081-0/+3
| | | | Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
* newlib: add option to enable nano mallocBryan Hundven2016-03-081-0/+3
| | | | Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
* newlib: disable multilib if it is not enabledBryan Hundven2016-03-081-0/+5
| | | | Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
* scripts: Update usage of CT_GetCustomBryan Hundven2015-12-081-8/+2
| | | | | | | This commit updates the build scripts to match the new usage of CT_GetCustom from the previous change. Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
* consistency: Use exported variables of required toolsBryan Hundven2015-11-171-4/+4
| | | | | | | | | | | | | | | | | | | | | | We check for apps: * make * sed * grep * awk * libtool/libtoolize * install * patch * and more ...during configure. Our scripts should be consistent about using the variables that define where the found tool was found. Of course, we do hard-link these tools in buildtools, but that should be a backup for the components we are building. Our scripts should always use the tools we find. Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
* xtensa: add support for the configurable Xtensa architecture.Chris Zankel2015-11-131-0/+9
| | | | | | | | | | | | | | | The Xtensa processor architecture is a configurable, extensible, and synthesizable 32-bit RISC processor core. Processor and SOC vendors can select from various processor options and even create customized instructions in addition to a base ISA to tailor the processor for a particular application. Because of the configurability, the build process requires one additional step for gcc, binutils, and gdb to update the default configuration. These configurations are packed into an 'overlay' tar image, and are simply untarred on top of the default configuration during the build. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
* gcc: Support only the latest branch releases of gccBryan Hundven2015-10-311-19/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change, as per #222, reduces the number of supported releases of gcc to the latest branch releases. I noticed while doing this work that gcc-4.5.4 was never added, so I moved patches for gcc-4.5.3 to 4.5.4 and updated the bfin-unknown-linux-uclibc example. Also, 120-siginfo.patch was fixed upstream in the 4.5.4 release, so this patch is omitted. I also bumped the avr sample to 4.9.3 from 4.9.2. With the addition of gcc-5.x, the gcc release team now releases the major.minor.0 versions, while updates to the branch are available in svn/git. We'll address that when we get to issue #219. This change just removes CC_GCC_5_1 and moves CC_GCC_5_2 to CC_GCC_5, and removes CC_GCC_5_1_or_later and moves CC_GCC_5_2_or_later to CC_GCC_5_or_later. This is the first of two part changes, as mentioned in #222. This change is slated for release in 1.22.0. The next change will be slated for 1.23.0, and will limit gcc versions to what is on https://gcc.gnu.org under "Release Series and Status", which is currently 4.9.3 and 5.2.0, although I will also support the previous supported version. In this example that would be 4.8.5. Last, but not least, this change also retires AVR32 support. Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
* Added additional newlib specific target flags with new optionJasmin Jessich2015-09-141-1/+4
| | | | | | LIBC_NEWLIB_TARGET_CFLAGS. Signed-off-by: Jasmin Jessich <jasmin@anw.at>
* avr-libc: add support for avr-libc C libraryErico Nunes2015-06-211-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the avr-libc C library. According to the project page at http://www.nongnu.org/avr-libc , the avr-libc package provides a subset of the standard C library for Atmel AVR 8-bit RISC microcontrollers. In addition, the library provides the basic startup code needed by most applications. Support for this library in crosstool-ng is only enabled for the AVR 8-bit target. The avr-libc manual and most distributions build the AVR 8-bit gcc toolchain with the "avr" (non-canonical) target. Some experimentation also led to the conclusion that other (canonical) targets are not very well supported, so we force the "avr" target for crosstool-ng as well. The manual also recommends building avr-libc after the final gcc build. To accomplish this with crosstool-ng, a new do_libc_post_cc step is added, in which currently only avr-libc performs its build, and is a no-op for the other libc options. Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
* scripts/*/*.sh: prioritize http downloadsBryan Hundven2015-02-011-1/+2
| | | | | | | | | | | | | Prirotize http downloads before ftp downloads. By having http download first, those using proxy will work with the current download mechnism. This tells me that that mechnism needs to be updated. (proxy support and/or kconfig toggles) closes #3 Signed-off-by: Bryan Hundven <bryanhundven@gmail.com>
* libc: newlib: Add NewLib 2.2.0, Linaro NewLib 2.2.0-2015.01 and 2.1.0-2014.09Cristoforo Cataldo2015-01-161-2/+9
| | | | | | | | | This commit allows to choose, download and build latest NewLib: - newlib-2.2.0 - newlib-linaro-2.2.0-2015.01 - newlib-linaro-2.1.0-2014.09 Signed-off-by: Cristoforo Cataldo <cristoforo.cataldo@gmail.com>
* libc/newlib: Add do_libc_start_files to copy headers to CT_HEADERS_DIRDavid Holsgrove2015-01-021-4/+4
| | | | | | | Require access to newlibs headers in gcc.sh, matching other libc components. Resolves issue with headers not found. Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com>
* newlib: fix extract process for custom versionTrevor Woerner2014-02-251-1/+1
| | | | | | | | | | | | | newlib: fix extract process for custom version If the user specifies the use of a custom newlib version, the logic in the extract function was reversed, so this step would fail. Signed-off-by: Trevor Woerner <trevor.woerner@linaro.org> [yann.morin.1998@free.fr: keep leading indentation] Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Message-Id: <c727adf1b7bd2c1e891d.1393353347@openSUSE-i7> Patchwork-Id: 324060
* libc/newlib: fix variables for avr32 headersYann E. MORIN"2013-12-311-6/+10
| | | | | | | Some of the avr32headers related variables are used in different functions, so have to be declared globally, not locally. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
* libc/newlib: add HTTP mirrorMichael Hope2013-08-011-1/+2
| | | | | | | | | | | Add well-known HTTP mirror as a fallback. This lets crosstool-ng work when behind a HTTP/HTTPS only proxy. Signed-off-by: Michael Hope <michaelh@juju.net.nz> [yann.morin.1998@free.fr: split patch in two] Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Message-Id: <aeb4a850d0786ee62dc2.1375559989@wanda> Patchwork-Id: 264436
* arch/avr32: Fix download of header filesMartin Guy2013-03-311-9/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes the download of the avr32 headers in crosstool-ng by fetching them directly from Atmel's web site instead of the now-broken URL given by the original author of the avr32-header-fetching modification, who fetched them from a copy on his own, now-defunct server. It also adds the necessary logic to extract from a zip file, as that is how the headers are packaged. To configure it for avr32 after launching ct-ng menuconfig in an empty directory: Paths and misc options -> Shell to use as CONFIG_SHELL = sh Target options -> Target Architecture = avr32 Toolchain options -> Tuple's alias = avr32 Binary utilities -> binutils version = 2.18a C compiler gcc version = 4.2.2 C-library newlib version = 1.17.0 Enable IOs on long long = yes Enable IOs on floats and doubles = yes Disable the syscalls supplied with newlib = yes CONFIG_SHELL is necessary to get round the "fragment: command not found" bug when binutils-2.18 is configured using bash. Prepared against crosstool-ng mercurial trunk on 31 March 2012. Signed-off-by: Martin Guy <martinwguy@gmail.com> [yann.morin.1998@free.fr: update bundles sample accordingly] Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Message-Id: <CAL4-wQrg_NQ7jm-NCADqeyQr9twyhtx42OUGNThP6gWeqZc=kw@mail.gmail.com> Patchwork-Id: 232612
* libc/newlib: update fetch locationTrevor Woerner2013-03-031-1/+1
| | | | | | | | | | | The menu system provides an option to allow a user to request newlib version 2.0.0. newlib-2.0.0, however, is not available at the download location currently being used. It is, however, available (as are other supported versions of newlib) at an alternate location. Signed-off-by: Trevor Woerner <twoerner@gmail.com> Message-Id: <75ab5151c7f5dc9086e3.1362334313@suse64> Patchwork-Id: 224561
* libc: get rid of libc_finishYann E. MORIN"2013-01-101-4/+0
| | | | | | | At long last, we no longer have any libc that requries a libc_finish. Yeah! Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
* libc/newlib: install AVR32 headers during the start-files-and-headers phaseYann E. MORIN"2013-01-101-9/+11
| | | | Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
* libc/newlib: remove getting from CVSYann E. MORIN"2012-10-301-21/+7
| | | | | | | We now have the ability to use a custom local directory/tarball, so it no longer makes sense to have the ability to use the CVS repository. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
* libc/newlib: Add CUSTOM version and CUSTOM_LOCATION config options and GetCustomDavid Holsgrove2012-10-111-1/+10
| | | | | | | | | | | CUSTOM_LOCATION config options only presented in menuconfig if component CUSTOM version selected. Signed-off-by: "David Holsgrove" <david.holsgrove@xilinx.com> [yann.morin.1998@free.fr: fix indentation] Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Message-Id: <d02252752d4dc5e68ae3.1349931202@localhost.localdomain> PatchWork-Id: 190795
* libc/newlib: build newlib in the proper stepYann E. MORIN"2011-07-171-4/+4
| | | | | | | | | | | Currently, newlib is built in the start_file step, which is wrong, but was needed when the baremetal integration was... well, 'unfinished'. Now that we build the baremetal compiler from the final cc step, and a proper core gcc in pass-1 and pass-2, we can move the newlib build to the step do_libc, where it belongs. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
* libc/newlib: build manual for newlibYann E. MORIN"2011-12-151-0/+15
| | | | | | Signed-off-by: Zhenqiang Chen <zhenqiang.chen@linaro.org> [yann.morin.1998@anciens.enib.fr: copy with a single call to 'cp'] Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
* libc/newlib: remove hard-coded "-O"Zhenqiang Chen2011-11-281-1/+1
| | | | | | | | With hard-coded "-O", users can not customize CFLAGS_FOR_TARGET by CT_TARGET_CFLAGS. If "-O" is needed, users can input it in CT_TARGET_CFLAGS. By default, "-Os" is enabled. Signed-off-by: Zhenqiang Chen <zhenqiang.chen@linaro.org>