Commit graph

113 commits

Author SHA1 Message Date
Solomon Peachy
62098a0cc9 toolchain: To build GCC for hosted targets, we need -std=gnu++11 for stage2.
But for stage1 (and non-hosted targets) we can stick with -std=gnu++03.

This keeps everyone happy with no apparent regerssions on older
host compilers.

Change-Id: I1300574557bc8d4d13e5cf07d4ae85645998f071
2021-06-04 10:05:05 -04:00
Aidan MacDonald
49dfc8be27 rockboxdev.sh fixes for hosted MIPS toolchain
Add --with-sysroot= to the configure args of glib and dbus because
otherwise they get confused and try to use host system dependencies.

Also fix the broken restart logic so you can actually restart a build.

Change-Id: Ib456c04845d80cc923dcc6b83e57f67a0868104b
2021-06-04 13:06:57 +00:00
Solomon Peachy
18288fcce6 toolchains: Fix gcc 4,9.4 compilation using GCC11.
Basically it defaults to using C++17, which breaks the GCC compilation.
Instead, explicitly specify -std=c++03, which should work everywhere.

Change-Id: I821591dbbac4fab4b1d930702ed66c7c767b5c92
2021-06-04 08:38:35 -04:00
Aidan MacDonald
aacb0811d9 Rename symbols of FiiO M3K Linux-based port
Mainly a straight replacement of FIIO_M3K -> FIIO_M3K_LINUX.

Change-Id: Id07c84f8150991d1b6851540c2c3f8f67e3f12c2
2021-02-27 23:53:28 +00:00
Wolfram Sang
422aa56243 rockboxdev: fix issues with relative paths for commandline options
I wanted to build into a 'toolchain' directory like this:

$ tools/rockboxdev.sh --dlwhere=toolchain --builddir=toolchain/build --prefix=toolchain/bin

This failed twice:

a) the extraction stage could not uncompress because of the relative
paths, so convert them to absolute paths in the script to fix the issue.

b) patches could not be applied because 'rockboxdevdir' was assigned a
string with the directory twice and '\n' in the middle. Using readlink,
this now works.

Change-Id: I9c7c30812e1fb4b58db7e6561d73678f34714c91
2021-02-05 17:29:05 +00:00
Wolfram Sang
a67c6934c1 rockboxdev: better error message for unknown compression
I hit this error and its message confused me because I interpreted it as
"bzip2 executable could not be found". The message was also outdated
because xz is supported meanwhile. Update the message to something
hopefully more helpful.

Change-Id: Ide2f8809dc0f8159d7d04fa22c29607dd6b35792
2021-02-05 17:29:05 +00:00
Wolfram Sang
e23d45536e rockboxdev: fix summary output of options
'--download' is now named '--dlwhere' and 'target' was missing the '='

Change-Id: I5f295fac8ddfb9139b00e9b6b7b5dfa625ac05cf
2021-02-05 17:29:05 +00:00
Solomon Peachy
497618e51e Add libraries to native MIPS toolchain to enable bluetooth support
libffi, zlib, glib, expat, and dbus

Change-Id: I9453b3cabe91fd3dc992e065729d61d7e005091e
2020-11-19 12:33:01 -05:00
Solomon Peachy
b4865b05b0 Build: Bump all toolchains to GCC 4.9.4 + Binutils 2.26.1
GCC 4.9.4 was already used for MIPS and all hosted targets; this enables
it across the board for everything (ie m68k and arm native)

Other changes:

 * Use '-Os' as the default optiomization for all targets
   (was only disabled for arm native)
 * Enable -funit-at-a-time and -Wextra
 * Drop all obsolete toolchain patches
 * Update ARM multilib/exception patch
 * Bump toolchain libs (gmp, mpfr, mpc) to recommended versions, and
   add 'isl' to enable better optimization & vectorization opportunities.

   (Will revisit optimization for the codecs and plugins at a later date)

Confirmed working:

 * armv4t     (ipodmini2g and many other PP502x targets)
 * arm >= v5  (sansaclipplus, ipod6g, ipodnano2g, sansafuzeplus)
 * m68k (ihp100)

Change-Id: If9ed405ae0f289d9adea46d4cf46bfefc2f4250d
2020-10-13 16:27:07 +00:00
Dominik Riebeling
adce547e13 rockboxdev: Make it work on macOS.
macOS doesn't know about nproc; sysctl is the tool to be used on macOS.

Change-Id: Ic7dcf9be51d7ef7b52394ebb2a4df1dc3e31097b
2020-08-07 22:18:41 +02:00
Solomon Peachy
092c340a20 [1/4] Remove SH support and all archos targets
This removes all code specific to SH targets

Change-Id: I7980523785d2596e65c06430f4638eec74a06061
2020-07-24 21:20:13 +00:00
Solomon Peachy
ab1cf209ec build: We don't want '-r' in MAKEFLAGS for toolchain builds.
Change-Id: Id1a96fb2274572ae7520a146b13f044f68e0c3aa
2020-07-12 22:24:32 -04:00
Solomon Peachy
08c6f9104c build: add '-fcommon' to the toolchain build flags.
This allows binutils 2.16 to build successfully with GCC10.

Change-Id: Iddcd4156720f4fa05936ea459991866fc6e1524d
2020-07-02 20:04:10 +00:00
Solomon Peachy
b1d7d897d3 rockboxdev: Remove the ability to build the special cy-ng ypr0 toolchain
We don't actually use it any more; let's not confuse folks with it.

Change-Id: Ic8fbe9bc95495b0969249dc774c5adf2126a2b98
2020-04-13 00:39:01 +02:00
Solomon Peachy
00c0d2012f rockboxdev: Store toolchain patches in-tree, instead of downloading them
This frees us from having to keep the web site in sync.

Note that only currently-referenced patches were kept.

Change-Id: I50da1b75baeac214cf142c8b76a05a8c56b4c1d4
2020-04-04 21:56:30 +02:00
Solomon Peachy
74ab8d1490 toolchain: Parallelize the toolchain build if possible
Let's actually use those newfangled multicore processors!

Change-Id: Idfc21f10d634b969c49e7f22ab723e48951db0f0
2020-04-03 09:04:20 +02:00
Michael Giacomelli
3e91ad5df2 Fix download link for the MIPS toolchain. 2018-07-28 10:56:31 -04:00
Solomon Peachy
0662793ca0 Add cleaned-up xDuoo X3 support
Cleaned up, rebased, and forward-ported from the xvortex fork.

(original credit to vsoftster@gmail.com)

Change-Id: Ibcc023a0271ea81e901450a88317708c2683236d
Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
2018-07-28 10:56:31 -04:00
Amaury Pouly
b3e2bd619b Update MIPS toolchain to GCC 4.9.4 and binutils 2.26.1, update configure
Change-Id: I4d3dad4521bdf0b0d6ee5d1635ddbf57483d2b42
2018-07-28 10:56:31 -04:00
Marcin Bukat
beef52c5f0 mipsel-rockbox-linux toolchain build fix
If we use mips-rockbox-linux target resulting toolchain is
big endian. If we use mipsel-rockbox-linux build fail since
linux doesn't have separate archs for BE and LE mips. So we
tweak arch passed to linux-headers stage to fix this.

Change-Id: Iccae529998d1cd8f3429fa3b2ca4f030122f23bb
2018-06-12 10:31:03 +02:00
Amaury Pouly
1b2faea677 Add generic linux MIPS toolchain
Change-Id: I9f8927e348421bd8592d62eb61f6acf324d5f3a4
2018-06-12 10:31:03 +02:00
Amaury Pouly
142f80f07d Modernize toolchain script and add generic arm toolchain
I did some cleanup of redudant stuff, simplify some logic, also switch to bash
because sh in the pain when ones want to locally define variables for functions
calls. I also added support to download more stuff like alsa-lib and more recent
gccs that use a different naming convention, as well as linux kernels.

I also add some build to build linux toolchains without ct-ng. The biggest problem
with ct-ng is that they regularly drop support for old stuff and as a result it
rots really quickly for old toolchains. I add a new toolchain for generic linux arm
with the minimum requirements, it works fine on Sony NWZ and also on YP-R0.

Finally, rockboxdev.sh now understand options on its command line (see --help).
Notably --target to give the list of targets (useful for noninteractive scripts),
--restart to restart at a step, --makeflags and others (instead of the environment
variables)

Change-Id: I869760c1faeb00ab381796a4cda82ffbc9637123
2017-09-04 15:06:48 +02:00
Amaury Pouly
906a95ccbf rockoxdev.sh: fix compilation of ARM toolchain
This will breaks mips but mips is already super hard to build anyway.

Change-Id: Ia481a22440758fe72a87e2808f4fb8d31c49cb53
2016-12-04 15:11:58 +01:00
Frank Gevaerts
78f4f7b621 Make crosstool-ng build with gnu make 4.0
Change-Id: Id3a5a310e6fa53e690c92f420994875cb1bfff43
2014-07-30 14:29:27 +02:00
Frank Gevaerts
110e094db5 Switch back to kernel.org.
kernel.org is back, and nic.funet.fi is being difficult, so it's time
to switch back.

Change-Id: If981dedd0cb7bb64de7563de6657f63ebb931a6f
2013-10-20 21:14:57 +02:00
Michael Rodger
6845f6c396 Include 60s timeout for wget commands in rockboxdev.sh
Added a 60s timeout to the script to avoid having to wait for ages when a download stalls.

Change-Id: I97f0aafe4eac0fb3cfc83805c99d19f1ef02b9f9
Reviewed-on: http://gerrit.rockbox.org/636
Reviewed-by: Kevin Zheng <kevinz5000@gmail.com>
Tested-by: Michael Rodger <rockbox@atinyhedgehog.za.net>
Reviewed-by: Amaury Pouly <amaury.pouly@gmail.com>
2013-10-19 13:06:04 +02:00
Nils Wallménius
084c75e5f9 Fix building of sh, arm and m68k toolchains with new texinfo
Recent versions of texinfo breaks various binutils and GCC
builds. For GCC setting MAKEINFO=missing at configure time works
but not for binutils where patches are used to fix parsing errors.
This also makes rockboxdev.sh handle applying multiple patches.

Change-Id: Ia8e6dc7662ab725490e4b4428676d235f0bd38bb
Reviewed-on: http://gerrit.rockbox.org/471
Reviewed-by: Nils Wallménius <nils@rockbox.org>
2013-06-15 21:01:26 +02:00
Marcin Bukat
5dec7af1ec Revert "SH gcc 4.6.3 with link-time optimization, for Archos targets"
This was commited by accident, sorry.
2012-10-24 14:05:39 +02:00
Boris Gjenero
c975de1534 SH gcc 4.6.3 with link-time optimization, for Archos targets
This is work from FS#12431 synced to current HEAD and slightly
tweaked (gcc 4.6.2 -> 4.6.3, binutils 2.21.1 -> 2.22)

Change-Id: I76af91e80ac2a9c16a776c7f0a33cc51603bbf9b
2012-10-24 14:02:41 +02:00
Peter D'Hoye
63a48fa9b0 more tools checks to be done before starting toolchain builds 2012-05-19 01:45:23 +02:00
Peter D'Hoye
0587e85e23 add aditional required tools to the check 2012-05-19 01:01:22 +02:00
Dominik Riebeling
975332d608 Disable built-in make rules for binutils 2.16.1.
If make provides a built-in rule for .m files (seen on Fedora 16, reported on
the net for OS X) it breaks binutils 2.16.1. Disable built-in rules to avoid
this.

Change-Id: I2e76c52661e47edf81706ed5c8c30f5e6cab8546
2012-03-04 10:40:15 +01:00
Thomas Martitz
2ec443df12 Remove bash-specific syntax from rockboxdev.sh
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31422 a1c6a512-1295-4272-9138-f99709370657
2011-12-24 15:40:11 +00:00
Thomas Martitz
461e2c72ad Actually call ct-ng (i.e. fix left-over from testing).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31413 a1c6a512-1295-4272-9138-f99709370657
2011-12-23 13:54:00 +00:00
Thomas Martitz
6296045e2a Add crosstool-NG build to rockboxdev.sh.
rockboxdev.sh can now build toolchains using ct-ng (and build ct-ng before
if required). It downloads the appropriate config for ct-ng and lets it do its job.

Used for the upcoming YP-R0 target, which requires a full toolchain including libc.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31412 a1c6a512-1295-4272-9138-f99709370657
2011-12-23 13:49:43 +00:00
Nick Peskett
476f4a7baf I think 'e' for arm (rather than 'a') is a typo
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31362 a1c6a512-1295-4272-9138-f99709370657
2011-12-19 14:02:36 +00:00
Thomas Martitz
84b527410a Remove deprecated arm toolchain from rockboxdev.sh. Replace with arm-eabi.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31361 a1c6a512-1295-4272-9138-f99709370657
2011-12-19 13:11:16 +00:00
Björn Stenberg
5adf7d315d sunet mirror was bad. let's try funet.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30612 a1c6a512-1295-4272-9138-f99709370657
2011-09-27 19:19:28 +00:00
Björn Stenberg
291c6be8e4 Use another GNU mirror while kernel.org is down.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30605 a1c6a512-1295-4272-9138-f99709370657
2011-09-26 06:48:53 +00:00
Nils Wallménius
ee7cbf6d4a FS#12121 by Sean Bartell, disables -Werror on binutils builds to fix them when using gcc 4.6.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29928 a1c6a512-1295-4272-9138-f99709370657
2011-05-27 15:13:29 +00:00
Dominik Riebeling
37feed5287 Make m68k-elf 4.5.2 toolchain build on OS X 10.6.
OS X requires slightly different compiler options due to functions deprecated
in 10.6 (as done in r28179 for arm-eabi-elf).



git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29051 a1c6a512-1295-4272-9138-f99709370657
2011-01-13 20:12:36 +00:00
Nils Wallménius
4ca7c9c2c6 rockboxdev.sh: coldfire toolchain upgrade, now using gcc 4.5.2 and binutils 2.20.1. The configure switch will come as soon as a few buildclients are updated.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29039 a1c6a512-1295-4272-9138-f99709370657
2011-01-12 21:39:02 +00:00
Nils Wallménius
a335afadaa rockboxdev.sh: switch back to using the kernel.org mirrors as the gnu.org mirrors were unreliable and inconsistent. Hardcode the mpc url as mpc is not on the kernel.org mirrors. Sorry for the noise.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29024 a1c6a512-1295-4272-9138-f99709370657
2011-01-10 19:13:33 +00:00
Nils Wallménius
daa3c36248 rockboxdev.sh: Hardcode gcc mirror for now as the gnu mirrors have a different dir layout and are missing the infrastructure dir which was the whole reason for the switch. Fix spurious trailing slash
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28981 a1c6a512-1295-4272-9138-f99709370657
2011-01-06 23:51:15 +00:00
Nils Wallménius
50b151adcb rockboxdev.sh:
Prepare for compiler upgrade by adding support for building the mpc lib that gcc 4.5 needs. Switch mirror so that we can use the "infrastructure" dir set up with all the libs gcc depends on in the correct versions. Use these versions (meaning 4.3.2 of gmp is used instead of 5.0.1 now but should be functionally equivalent).
Fix a small typo while at it.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28974 a1c6a512-1295-4272-9138-f99709370657
2011-01-06 14:56:36 +00:00
Torne Wuff
a02fada130 rockboxdev.sh: Fix build failure on cygwin by not trying to remove the current directory
On Windows you can't delete a directory that's in use, so deleting $builddir while inside it fails. The script now leaves the individual tool build directory then just deletes that (and the corresponding source)


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28314 a1c6a512-1295-4272-9138-f99709370657
2010-10-19 21:31:35 +00:00
Dominik Riebeling
7b52f97912 Make eabi toolchain build on OS X 10.6.
OS X requires slightly different compiler options due to functions deprecated
in 10.6 (FS#11643).


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28179 a1c6a512-1295-4272-9138-f99709370657
2010-09-27 20:42:30 +00:00
Frank Gevaerts
d298fa857e Add missing quote, and use the right word
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27376 a1c6a512-1295-4272-9138-f99709370657
2010-07-10 20:17:26 +00:00
Michael Giacomelli
6206f4083f Update the text in rockboxdev.sh to make it clear that EABI should be used on ARM
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27374 a1c6a512-1295-4272-9138-f99709370657
2010-07-10 15:52:53 +00:00
Jonas Häggqvist
83c19efa7e Don't explicitly set -j for make. Inform the user that he can set MAKEFLAGS instead.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26822 a1c6a512-1295-4272-9138-f99709370657
2010-06-12 21:08:45 +00:00