LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 10-23-2020, 05:04 PM   #1
kayjoyka
LQ Newbie
 
Registered: Oct 2020
Posts: 1

Rep: Reputation: Disabled
Why can't I install GCC 9.3.0 from source?


Hi,
I'm currently making an embedded Linux system that's meant to run on a Raspberry Pi. I'm following the instructions in a book called CLFS - Embedded but unfortunately I'm stuck on the final installation of the GCC cross compiler. Upon configuring it and running make after a while I get this message:
Code:
/usr/bin/ld: libcommon.a(diagnostic.o): in function `diagnostic_action_after_output(diagnostic_context*, diagnostic_t)':
/home/kayjoyka/Pulpit/clfs/sources/gcc-build/gcc/../../gcc-9.3.0/gcc/diagnostic.c:536: undefined reference to `backtrace_full'
collect2: error: ld returned 1 exit status
make[2]: *** [../../gcc-9.3.0/gcc/c/Make-lang.in:85: cc1] Error 1
make[2]: Leaving directory '/home/kayjoyka/Pulpit/clfs/sources/gcc-build/gcc'
make[1]: *** [Makefile:4313: all-gcc] Error 2
make[1]: Leaving directory '/home/kayjoyka/Pulpit/clfs/sources/gcc-build'
make: *** [Makefile:945: all] Error 2
If I'm not mistaken the 'backtrace_full' that diagnostic.c is referring to here is part of backtrace.c from libbacktrace, but backtrace.h in which it is defined is included in diagnostic.c so why would this be happening? Am I doing something wrong?
 
Old 10-26-2020, 06:43 AM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,309

Rep: Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326Reputation: 2326
Hello, kayjoyka & welcome to LQ.

With LFS and especially CLFS, always post the exact page on which you are working, and your host distribution.

"Undefined Reference" errors are usually libraries. If your program version is too old, features may have been added to newer ones. A library, as you probably know, is a compiled collection of useful routines which programs can call to do stuff. They are memory efficient, because many programs can use the same library. But if they call something that isn't there, that throws the 'undefined reference' error.

I would run the version check script for the current book (in chapter 2?)

Last edited by business_kid; 10-26-2020 at 06:47 AM.
 
Old 10-26-2020, 09:02 AM   #3
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,151

Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
you don't need to cross compile for the pi you can compile (B)LFS completly on a pi ( tested on pi 3/4 ), crosscompiling just adds unnecessary complications.

raspian can easily be set up to build (B)LFS.

Just follow the LFS book as you would for a desktop build

Last edited by Keith Hedger; 10-26-2020 at 09:03 AM.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
step 5.10 gcc/limitx.h gcc/glimits.h gcc/limity.h no such file or directory iambrj Linux From Scratch 7 08-07-2018 11:22 AM
LXer: GCC 4.9 vs. GCC 5.1 vs. GCC 6.0 SVN Compiler Benchmarks LXer Syndicated Linux News 0 06-08-2015 01:00 PM
[SOLVED] SEGMENTATION FAULT using gcc 4.4.4 -O2 , works with gcc 4.1.0 -O2 or gcc 4.4.4 -O1 amir1981 Programming 36 07-26-2010 06:07 PM
Why couldn't the gcc(version4.3.3) be used to compile the gcc(version3.3.2)? snc Linux - Newbie 6 01-24-2010 11:26 AM
Why gcc is needed for an HBA card? How to upgrade gcc enayet_v Linux - Newbie 3 11-17-2007 04:57 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 09:12 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration