Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

Racket won’t build on Lion #5408

Closed
ELLIOTTCABLE opened this issue Apr 28, 2011 · 10 comments
Closed

Racket won’t build on Lion #5408

ELLIOTTCABLE opened this issue Apr 28, 2011 · 10 comments

Comments

@ELLIOTTCABLE
Copy link
Contributor

The plt-racket package (PLT-Scheme/Racket) won’t build for me. I’m on OS X Lion (Developer Preview 2), which I suspect to be related to the issue.

All of the relevant output is provided in this gist: https://gist.github.com/946268

(P.S. I’m not even sure if Racket itself is prepared to work on Lion; I’m posting this issue to get the ball rolling, and get others looking into it, as I’m far too much of a lisp noob to have any idea what to do. I found this post to the Racket mailing list, which might provide more information: http://lists.racket-lang.org/dev/archive/2011-April/006128.html)

(P.P.S. I give you permission to tell my mother that I am a mean person for running a Lion Developer Preview with the Lion Xcode build, and yet reporting a bug. Her phone number is +1 (907) 748-4862.)

@adamv
Copy link
Contributor

adamv commented Apr 28, 2011

Could try adding one or more of:

fails_with_llvm

ENV.x11

depends_on 'cairo'

in the appropriate places.

@ELLIOTTCABLE
Copy link
Contributor Author

Tried that; just finished building. Still fails, same error, with all three added.

@knl
Copy link
Contributor

knl commented May 7, 2011

Hi,
I had some build failures as well, on Snow Leopard, using the latest XCode. However, just specifying racket version 5.1.1 fixed the issue:


diff --git i/Library/Formula/plt-racket.rb w/Library/Formula/plt-racket.rb
index cb74556..d48fc39 100644
--- i/Library/Formula/plt-racket.rb
+++ w/Library/Formula/plt-racket.rb
@@ -2,9 +2,9 @@ require 'formula'
 
 class PltRacket < Formula
   # Use GitHub; tarball doesn't have everything needed for building on OS X
-  url 'git://github.com/plt/racket.git', :tag => 'v5.1'
+  url 'git://github.com/plt/racket.git', :tag => 'v5.1.1'
   homepage 'http://racket-lang.org/'
-  version '5.1'
+  version '5.1.1'
 
   # Don't strip symbols; need them for dynamic linking.
   skip_clean 'bin'

@ELLIOTTCABLE
Copy link
Contributor Author

No luck.

After applying that patch: https://gist.github.com/961100

Same as above, but adding fails_with_llvm: https://gist.github.com/961102

@ELLIOTTCABLE
Copy link
Contributor Author

After posting more issues to the Racket mailing list, we came up with a solution that works outside Homebrew for Mac OS X Lion DP3: http://lists.racket-lang.org/users/archive/2011-May/045392.html

Unfortunately, within Homebrew, the same fix doesn’t work. Apply the following if you’re following along at home and want to try it:

 Library/Formula/plt-racket.rb |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git i/Library/Formula/plt-racket.rb w/Library/Formula/plt-racket.rb
index d48fc39..4d3c218 100644
--- i/Library/Formula/plt-racket.rb
+++ w/Library/Formula/plt-racket.rb
@@ -6,12 +6,15 @@ class PltRacket < Formula
   homepage 'http://racket-lang.org/'
   version '5.1.1'

+  depends_on 'cairo'
+
   # Don't strip symbols; need them for dynamic linking.
   skip_clean 'bin'

   def install
     Dir.chdir 'src' do
       args = ["--disable-debug", "--disable-dependency-tracking",
+              "--disable-places", "--disable-futures", # temporary, to force it to build on Mac OS X Lion DP3
               "--enable-xonx",
               "--enable-shared",
               "--prefix=#{prefix}" ]

Here’s the Homebrew output from the above: https://gist.github.com/962212

@adamv
Copy link
Contributor

adamv commented Jun 9, 2011

Cairo is "keg-only", so the build system will probably need more help finding it.

@mxcl
Copy link
Contributor

mxcl commented Jul 21, 2011

Something is trying to dynamically load libcairo at runtime. The error is that it can't find it.

Lion provides one (possibly still too old) it’s in /usr/X11/lib, so it should be able to find that at least.

If the problem is that it wants the Homebrew one then you probably need to set the DYLIB_LIBRARY_PATH environment variable. (I probably got the variable name wrong there, I can’t remember it).

@wolverian
Copy link
Contributor

FWIW, the 5.1.2 tag builds on Lion. It's still dynamically looking for cairo, though.

@adamv
Copy link
Contributor

adamv commented Aug 22, 2011

Pushed 5.1.3 in 6c52429 - someone on Lion test this.

@adamv
Copy link
Contributor

adamv commented Aug 23, 2011

Closing this then...

@adamv adamv closed this as completed Aug 23, 2011
@Homebrew Homebrew locked and limited conversation to collaborators Feb 16, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants