Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • GHC GHC
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 5,254
    • Issues 5,254
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 562
    • Merge requests 562
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Glasgow Haskell CompilerGlasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #8139
Closed
Open
Issue created Aug 17, 2013 by darinmorrison@trac-darinmorrison

ghc 7.6.3 and ghc HEAD fails to build on OS X 10.9

ghc 7.6.3 does not compile on OS X 10.9 (as of DP5).

There are a few issues that seem to be causing this:

  1. gcc is no longer available and the clang compatibility patches of #7678 (closed) are not included in 7.6.3.

  2. There is some sort of bug that causes mkdirhier.sh to fail in some cases.

  3. There is another bug when compiling RtsProbes.d with DTrace. The problem seems to be triggered by the inclusion of stdint.h. #undef-ing HAVE_STDINT_H only for the compilation of RtsProbes.d (which then includes inttypes.h instead) seems to work for some reason. A better solution may be possible from someone who understands the DTrace machinery better.

The issue has has been discussed here:

https://github.com/mxcl/homebrew/issues/20546

I have come up with a tentative patch that fixes problems (2) and (3) here (and also pasted below):

https://github.com/darinmorrison/homebrew/commit/611c76f6d6701c482559a64fe262f85b4dfda96f

diff --git a/includes/HsFFI.h b/includes/HsFFI.h
index dceabab..bc5e423 100644
--- a/includes/HsFFI.h
+++ b/includes/HsFFI.h
@@ -21,7 +21,7 @@ extern "C" {
 #include "stg/Types.h"
 
 /* get limits for integral types */
-#ifdef HAVE_STDINT_H
+#if defined HAVE_STDINT_H && !defined RTS_PROBES_D
 /* ISO C 99 says:
  * "C++ implementations should define these macros only when
  * __STDC_LIMIT_MACROS is defined before <stdint.h> is included."
diff --git a/rts/RtsProbes.d b/rts/RtsProbes.d
index 40665ac..8963ca7 100644
--- a/rts/RtsProbes.d
+++ b/rts/RtsProbes.d
@@ -6,6 +6,8 @@
  *
  * ---------------------------------------------------------------------------*/
 
+#define RTS_PROBES_D
+
 #include "HsFFI.h"
 #include "rts/EventLogFormat.h"
 
diff --git a/utils/mkdirhier/mkdirhier.sh b/utils/mkdirhier/mkdirhier.sh
index 4c5d5f7..80762f4 100644
--- a/utils/mkdirhier/mkdirhier.sh
+++ b/utils/mkdirhier/mkdirhier.sh
@@ -1,4 +1,4 @@
 #!/bin/sh
 
-mkdir -p ${1+"$@"}
+mkdir -p ${1+"./$@"}
 
Trac metadata
Trac field Value
Version 7.6.3
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system Unknown/Multiple
Architecture
Edited Mar 09, 2019 by darinmorrison
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking