Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Architectures & Platforms Gentoo on ARM
  • Search

aarch64 crossdev setup for pi4b fails to build on stage1

Gentoo on all things ARM. Both 32 bit and 64 bit.
Tell about your hardware and CHOST.
Problems with crossdev targeting ARM hardware go here too.
Post Reply
  • Print view
Advanced search
3 posts • Page 1 of 1
Author
Message
acertig
n00b
n00b
Posts: 13
Joined: Tue Aug 16, 2022 5:21 am

aarch64 crossdev setup for pi4b fails to build on stage1

  • Quote

Post by acertig » Wed Dec 14, 2022 3:54 am

Trying to setup my main desktop amd64 as a binhost for my pi. Apparently when trying to build the stage1 it cant find libcc1 on lib64. However after some research I found out it was being placed into regular /lib. I don't really know how to proceed since it's looking for it in the wrong place? Apparently this was a bug that got fixed a couple years ago and none issues have been filed ever since.

Code: Select all

mv: cannot stat '/var/tmp/portage/cross-aarch64-unknown-linux-gnu/gcc-11.3.0/image/usr/lib64
/libcc1*': No such file or directory
Top
NeddySeagoon
Administrator
Administrator
User avatar
Posts: 56082
Joined: Sat Jul 05, 2003 9:37 am
Location: 56N 3W

  • Quote

Post by NeddySeagoon » Wed Dec 14, 2022 10:36 am

acertig,

Run crossdev to get the cross toolchain.

Code: Select all

crossdev -t aarch64-unknown-linux-gnu
This will get you an 'empty' target root filesystem /usr/aarch64-unknown-linux-gnu/ on the build box.
Fix the profile symlink in /usr/aarch64-unknown-linux-gnu/etc/portage to point to the profile of you choosing for the Pi. The default embedded profile is not useful.
Set the USE flags for the Pi in /usr/aarch64-unknown-linux-gnu/etc/portage/make.conf
Execute

Code: Select all

emerge-wrapper --init -t aarch64-unknown-linux-gnu

Code: Select all

aarch64-unknown-linux-gnu-emerge -av @system --keep-going
will now try to cross compile the system set and install it into /usr/aarch64-unknown-linux-gnu/
It will also save binary packages to suit the Pi. A few packages are expected to fail.

Code: Select all

# aarch64-unknown-linux-gnu-emerge -pv @system

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild  N     ] sys-apps/gentoo-functions-0.17::gentoo to /usr/aarch64-unknown-linux-gnu/ 0 KiB
[ebuild  N     ] sys-libs/timezone-data-2022g::gentoo to /usr/aarch64-unknown-linux-gnu/ USE="-leaps-timezone -nls -zic-slim" 0 KiB
[ebuild  N     ] virtual/libiconv-0-r2::gentoo to /usr/aarch64-unknown-linux-gnu/ 0 KiB
...
Notice the install location.

If you want a 32 bit Pi install, change the tuple to suit.

I have a 64 bit binhost for Pi3 and Pi4.
As of last night, its also available over https but there is no auto redirect.

Its also possible to populate the target root using the target stage3.
If you do that, preserve the make.conf left by crossdev and the target stage3 will install a target make.conf, which is not what you want for cross compiling.
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Top
acertig
n00b
n00b
Posts: 13
Joined: Tue Aug 16, 2022 5:21 am

  • Quote

Post by acertig » Wed Dec 14, 2022 8:49 pm

lots of packages did refuse to compile but they do not amount to even half of the @system set
Top
Post Reply
  • Print view

3 posts • Page 1 of 1

Return to “Gentoo on ARM”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic