Comments (4)
It turned out that, it seems to me, the following libraries need to be installed on the host (Ubuntu 16.04 in my case) before "./configure" for the gcc-src to be invoked:
libmpc-dev
libmpfr-dev
libisl-dev
After this, "./configure" completes without any error.
from raspi3-tutorial.
Yes, if you have the option to use your system's packaging manager you should do that instead of downloading the source directly. Packaged sources are often patched to the needs of that specific system.
from raspi3-tutorial.
Hi all,
My system is OSX 10.13.4 andI had a bunch of hurdles to go through to get everything working.
One of the major issues is that macports installs a libiconv which has different symbols from the Xcode 9.3 version. E.g.
vp-lion:/ % nm /usr/lib/libiconv.2.dylib | grep iconv
00000000000f1d80 S ___iconv_2VersionNumber
00000000000f1d50 S ___iconv_2VersionString
00000000000f3750 D __libiconv_version
0000000000002b15 T _iconv
0000000000002e33 T _iconv_canonicalize
0000000000002b37 T _iconv_close
000000000000188d T _iconv_open
0000000000002b44 T _iconvctl
0000000000002c40 T _iconvlist
0000000000014f10 T _libiconv_relocate
00000000000f3760 b _libiconv_relocate.initialized
0000000000014e57 T _libiconv_set_relocation_prefix
vp-lion:/ % nm /opt/local/lib/libiconv.2.dylib | grep iconv
00000000000f67d0 D __libiconv_version
000000000000374a T _iconv_canonicalize
0000000000002f72 T _libiconv
0000000000002f94 T _libiconv_close
0000000000001c5c T _libiconv_open
0000000000002fa1 T _libiconv_open_into
0000000000016c79 t _libiconv_relocate
0000000000016bc0 T _libiconv_set_relocation_prefix
000000000000345c T _libiconvctl
0000000000003558 T _libiconvlist
So to get everything working I had to follow this procedure:
a) download ONLY binutils and gcc. The others should be installed using a packages manager (e.g. macports).
Give priority to the libraries installed at /opt/local/lib over the system ones:
setenv LIBRARY_PATH /opt/local/lib:/usr/lib:/usr/local/lib
or if you use /bin/sh
export LIBRARY_PATH=/opt/local/lib:/usr/lib:/usr/local/lib
b) configure binutils with:
cd binutils*
sh configure --disable-nls --prefix=/usr/local/cross-compiler --target=aarch64-elf --enable-shared --enable-threads=posix --enable-libmpx --with-system-zlib --with-system-isl --enable-__cxa_atexit --disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch --disable-libssp --enable-plugin --disable-linker-build-id --enable-lto --enable-install-libiberty --with-linker-hash-style=gnu --with-gnu-ld --enable-gnu-indirect-function --disable-multilib --disable-werror --enable-checking=release --enable-default-pie --enable-default-ssp --enable-gnu-unique-object
(note the --with-system-isl option which allows you to use the installed version of isl and the --disable-nls which gets rid of the i13n code)
make -j4
(j4 means 4 cores)
sudo make install
if you get errors such as
clang: error: unsupported option '-print-multi-os-directory'
do not worry, ignore them
The installation places files at: /usr/local/cross-compiler
So be sure to add this directory in your path to execute the new commands
set path= ( /usr/local/cross-compiler/bin $path )
c) configure gcc with:
cd ../gcc* ;
sh --prefix=/usr/local/cross-compiler --target=aarch64-elf --enable-languages=c --enable-shared --enable-threads=posix --enable-libmpx --with-system-zlib --with-isl --enable-__cxa_atexit --disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch --disable-libssp --enable-plugin --disable-linker-build-id --enable-lto --enable-install-libiberty --with-linker-hash-style=gnu --with-gnu-ld --enable-gnu-indirect-function --disable-multilib --disable-werror --enable-checking=release --enable-default-pie --enable-default-ssp --enable-gnu-unique-object --with-gmp-include=/opt/local/include --with-gmp-lib=/opt/local/lib
(note the use of options --with-gmp-include=/opt/local/include --with-gmp-lib=/opt/local/lib to use the installed version of the gmp)
make -j4 all-gcc
sudo make install-gcc
You are done.
**vp
from raspi3-tutorial.
Thank you very much for your detailed description on OSX!
from raspi3-tutorial.
Related Issues (20)
- Reference document to understand code and commands in 0B_readsector HOT 1
- 0x1C2 no longer has 0xE or 0xC partition type HOT 2
- 0B ReadSector - Stable clock troubleshooting HOT 8
- Typos - bareminimum readme HOT 3
- Using sd_readblock() for reading directories HOT 9
- 0A PCScreenFont only works in QEMU HOT 7
- 0B_readsector stuck after EMMC: Sending command 33220010 arg 00000000 HOT 1
- Segmentation fault on execution of 09_framebuffer and 0A_pcscreenfont HOT 6
- Using U-boot to boot kernel8.img HOT 2
- about the uart HOT 4
- Emulating the raspi 3 on jetson nano failed with a black screen. HOT 1
- Explanation for mailboxes HOT 4
- How to tune the booting parameters of Lineage 16 for Raspi 3 to boot it with qemu / kvm on the Jetson nano... HOT 1
- 14_raspbooin64 HOT 5
- Please help to understand the load address 0x800000 in the linker file HOT 2
- uart0 tutorial issue HOT 1
- Why *EMMC_INTERRUPT=*EMMC_INTERRUPT; in sd.c? HOT 1
- How do you debugger with gdb-multiarch? HOT 6
- Why ptr+=4 or ptr+=3? HOT 7
- qemu emulation not working HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from raspi3-tutorial.