Summary: | lang/ghc: fix build on powerpc64 elfv1 | ||||||
---|---|---|---|---|---|---|---|
Product: | Ports & Packages | Reporter: | Piotr Kubaj <pkubaj> | ||||
Component: | Individual Port(s) | Assignee: | freebsd-haskell (Nobody) <haskell> | ||||
Status: | Closed FIXED | ||||||
Severity: | Affects Only Me | CC: | arrowd, haskell, mikael, pkubaj | ||||
Priority: | --- | Flags: | arrowd:
maintainer-feedback+
|
||||
Version: | Latest | ||||||
Hardware: | Any | ||||||
OS: | Any | ||||||
Attachments: |
|
Description
Piotr Kubaj
2019-07-13 22:16:07 UTC
Just to explain more no. 2 - ELF_V1 doesn't seem to be properly defined. (In reply to Piotr Kubaj from comment #1) > Just to explain more no. 2 - ELF_V1 doesn't seem to be properly defined. Are you sure elf_v1 is not passed as a compiler flag (it's the case for elfv2), can you put some code in libraries/ghci/GHCi/InfoTable.hsc and look where the build fails? #if defined(ELF_V1) #error "ELF_V1 system" ... #if defined(ELF_V2) #error "ELF_V2 system" if you don't get an error then we should put #if defined(_CALL_ELF) && (_CALL_ELF == 1) instead. (In reply to mikael.urankar from comment #2) > elfv2), can you put some code in libraries/ghci/GHCi/InfoTable.hsc I meant rts/StgCRun.c (In reply to mikael.urankar from comment #3) Putting error doesn't break the build. -+#if defined(ELF_V1) ++#if defined(_CALL_ELF) && (_CALL_ELF == 1) ^^ This allows to build it. (In reply to Piotr Kubaj from comment #4) > (In reply to mikael.urankar from comment #3) > Putting error doesn't break the build. > > -+#if defined(ELF_V1) > ++#if defined(_CALL_ELF) && (_CALL_ELF == 1) > ^^ This allows to build it. Ok, can you commit the fix? (In reply to mikael.urankar from comment #5) Not until I have both of following: 1. Maintainer approval. 2. Then also mentor approval. Note that dtrace fix is also necessary. If Mikaёl is fine with this patch, so do I. (In reply to Gleb Popov from comment #7) > If Mikaёl is fine with this patch, so do I. It's fine for me. (In reply to Piotr Kubaj from comment #4) > (In reply to mikael.urankar from comment #3) > Putting error doesn't break the build. > > -+#if defined(ELF_V1) > ++#if defined(_CALL_ELF) && (_CALL_ELF == 1) > ^^ This allows to build it. can you do the same for ELF_V2? : #if defined(_CALL_ELF) && (_CALL_ELF == 2) Created attachment 205890 [details]
patch
OK?
(In reply to Piotr Kubaj from comment #10) > Created attachment 205890 [details] > patch > > OK? yes Comment on attachment 205890 [details]
patch
You're free to commit, then. Thanks!
What's the status of this? (In reply to Gleb Popov from comment #13) Waiting for mentor's review: https://reviews.freebsd.org/D20995 A commit references this bug: Author: pkubaj Date: Thu Aug 1 18:58:15 UTC 2019 New revision: 507820 URL: https://svnweb.freebsd.org/changeset/ports/507820 Log: lang/ghc: fix build on powerpc64 elfv1 Dtrace doesn't seem to work on elfv1 powerpc64 (at least on 12.0-RELEASE). Also properly detect when running on elfv1 and elfv2. PR: 239193 Approved by: arrowd (maintainer), tcberner (mentor) Differential Revision: https://reviews.freebsd.org/D20995 Changes: head/lang/ghc/Makefile head/lang/ghc/files/patch-ppc64 |