Forums

Skip to content

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

GHC status on ARM64

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
6 posts • Page 1 of 1
Author
Message
fredolic
n00b
n00b
Posts: 18
Joined: Mon Jul 11, 2005 7:27 am

GHC status on ARM64

  • Quote

Post by fredolic » Sun May 29, 2022 8:42 pm

Dear all,

I would like to know what is the status of GHC on ARM64 in Gentoo. I need it to build pandoc. As far as I know there needs to be a binary ghc compiler or either I need to bootstrap it myself (but that would still require some sort of binary to start with). The machine is an ARM64 based M1 Apple silicon chip, so RAM and CPU shouldn't be an issue to be able to compile it. And in fact, I would like to avoid cross-compiling because this is the fastest machine that I have available for such a task.

I can't compiler GHC-9.0.1 neither GHC-9.0.1-r1 with USE binary, ghcbootstrap, or ghcmakebinary, or any of their combinations.


Does anyone have any clue on how to proceed?

Thank you very much.
Top
NeddySeagoon
Administrator
Administrator
User avatar
Posts: 56078
Joined: Sat Jul 05, 2003 9:37 am
Location: 56N 3W

  • Quote

Post by NeddySeagoon » Sun May 29, 2022 10:39 pm

fredolic,

Since I tried this a few years ago on a Raspberry Pi 3, it looks like things are much improved.

Yo can get a Debian arm64 GHC.
It installs into /usr/local which is very user friendly.
After keywording ghc,

Code: Select all

USE=ghcbootstrap emerge ghc -av
will try to build 9.0.1 for you.

Its complaining about my llvm-14.0.3 but its still going.

Code: Select all

You are using an unsupported version of LLVM!
Currently only 9 to 13 is supported. System LLVM version: 14.0.3
I'm bothered that Debian is ahead of Gentoo, so when you get ghc-9.0.1, you may not like it.

-- edit --

Its midnight here and its still going.

-- more edit --

Code: Select all

Pi4_GCC-12 ~ # genlop -c

 Currently merging 1 out of 1

 * dev-lang/ghc-9.0.1-r1 

       current merge time: 9 hours, 47 minutes and 53 seconds.
       ETA: unknown.
That's with -j32 on a 3GHz system too.

Its buiiding ghc-9.0.1 now but ...
You are using an unsupported version of LLVM!

Code: Select all

Currently only 9 is supported. System LLVM version: 14.0.3
It built eventually ...

Code: Select all

     Mon May 30 10:10:45 2022 >>> dev-lang/ghc-9.0.1-r1
       merge time: 11 hours, 48 minutes and 11 seconds.
Its in my arm64 binhost. Thats built for 64 bit Raspberry Pi
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Top
fredolic
n00b
n00b
Posts: 18
Joined: Mon Jul 11, 2005 7:27 am

  • Quote

Post by fredolic » Mon May 30, 2022 1:07 pm

NeddySeagoon,

Thank you very much for your input. It worked very well, indeed. I was able to very easily install the ghc from Debian and from that emerge it.

On another one, I am sorry to hear about the time is taken to merge.... because I used `time` to measure it for my case (Mac Studio Max, 8 performance cores, 3.2Ghz, 32 GB RAM).

Code: Select all

real    41m49,341s
user    147m28,659s
sys     4m21,195s
Anyway, based on that I would like to be of use to the ARM64 gentoo community in the future.
Top
fredolic
n00b
n00b
Posts: 18
Joined: Mon Jul 11, 2005 7:27 am

  • Quote

Post by fredolic » Mon May 30, 2022 1:09 pm

Let me add that I needed to install numactl before.
Top
fredolic
n00b
n00b
Posts: 18
Joined: Mon Jul 11, 2005 7:27 am

  • Quote

Post by fredolic » Mon May 30, 2022 1:29 pm

I am afraid, however, that even if ghc is compiled, the issues is not yet fully resolved. As I mentioned, the idea is to install pandoc. And the problem now is that emerge is not able to move forward, and is stuck on some sort of cabal problem:

Code: Select all

<command line>: cannot satisfy -package Cabal-
This error message happens when installing either dev-haskell/fail, dev-haskell/hashable, dev-haskell/binary or dev-haskell/haskell-updater.

I fear that in order to solve it one should have dev-haskell/cabal, but this has, as dependencies, the aforementioned packages.

So any suggestion on how to move on?

Thank you.
Top
NeddySeagoon
Administrator
Administrator
User avatar
Posts: 56078
Joined: Sat Jul 05, 2003 9:37 am
Location: 56N 3W

  • Quote

Post by NeddySeagoon » Tue May 31, 2022 6:24 pm

fredolic,

After a bit of poking about, there are two things,

All the Gentoo Haskell action happens in the Haskell overlay. So use that rather than the main ::gentoo repo.

The Haskell ecosystem seems to be a bit like the Gentoo ecosystem, in that some packages depend on earlier versions of themselves.
It looks like ghc, cabal and a few others are like that.

The only way out of that is to find binaries and install them, in say, /usr/local then use those binaries to emerge your own.
Debian looks like a good starting point, it worked for ghc.

To support arm64 and find out what needs to be done, join Libera IRC, register your nick and talk to the people in #gentoo-arm.
You will need to discuss your interests and skill set as there is no point in indicating things that do not interest you or do not match your skills.
Its all supposed to be fun. That's the only reason for doing it.
You can say I sent you if you want.

There is an email alias for at arm64@gentoo.org but its very quiet.
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Top
Post Reply
  • Print view

6 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