-
-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't build X11 due to ld linking error on OSX 10.9.2 #24
Comments
That error typically means that you do not have some key libraries installed; in this case, Xss. I'm not sure what you need to do to get it (I've never really understood how package management works for Macs), so I can't give you much more help than that, sorry. I don't really think at the moment that this is a problem with the Haskell bindings. |
I hit the same issue here while trying out arbtt. Perhaps the X11 package description should state that it won't build on mac/windows. |
Is there really no way to install the Xss library on OSX? (I believe this is the X screensaver library.) If not, I suppose we could try to support a cabal flag or similar that would rip the screensaver support out. But I'd really, really prefer not to do that: letting the API of a package depend on flags is very bad practice, not least because there's no way for downstream packages to depend on particular build flags. |
I have succeeded to install X11 on OS X:
|
Thanks @adamse, it works for me! |
The same, thank you @adamse ! |
@adamse thanks dude! |
I can't see when this issue was closed [oh: 2014/4/21], but I respectfully disagree that it's resolved. The X11 package on hackage gives the impression of being cross-platform, so its description should include or point to any special steps required to install it. |
I agree that instructions should be given on how to install on Mac OS. I had to do a bunch of Web searching to reach this page with the workaround someone contributed. |
What would be the best place to put installation instructions for OS X? In the readme? In a separate |
Worked for me on OS X Yosemite, thanks! |
Another data point, for me
|
I needed this too (building for Yosemite) |
I would also add that the above is correct when using bash, commands are different when using tcsh. |
LIBRARY_PATH=/opt/X11/lib:$LIBRARY_PATH cabal install X11 that worked for me thanks! |
I just ran into this, and @nkpart's incantation worked for me - thanks. @adamse I think the best place to put OSX-specific instructions would be in all of the places that installation instructions relevant to any other platform go. I would probably start on the page on the xmonad site here where it references "Notes for Debian / Ubuntu", "Notes for Ubuntu", etc., like "Notes for OSX"? |
I have just pushed a branch named
Even having an answer to (1) without (2) would be a great help -- I can make a more careful pass at picking relevant packages if it looks like this idea has any chance of working at all. |
@dmwit if no one will give you a feedback, please ping me at the end of next week, I'll try to provide info you asked. |
Hi Daniel Thanks for this (and for yeganesh!). I launched a fresh shell without any
Now, if I leave the following...
in my Lemme know if there's anything further that I can do... |
Gehrddammit, it looks like my email reply mussed up the formatting. |
Okay, so essentially no change, which sucks since it means this approach is almost certainly not going to work. ...but I'm not going to put a hard-coded path like Note to future self: it looks like one of the results of running |
Just to clarify: I'm not suggesting that the relevant paths be added into the X11 cabal file, I'm suggesting that the project take every opportunity to tell those using OSX to add the paths to their |
The correct answer here is that, since configure found the libraries in /usr/X11/lib, it should be adding -L/usr/X11/lib to LDFLAGS. |
@geekosaur I believe my comment about |
(Just be mindful that OSX, in its infinite wisdom, symlinks |
It's right in the configure log in the initial report:
Since configure has determined that (and this is correct on OS X, at least from 10.7 on), configure should be telling the rest of the build. |
@larryhynes, while that is true, it's not really relevant; |
Works on El Capitan. Thanks |
link add |
For building with stack on OS X, install XQuartz and put the following in your extra-lib-dirs:
- /opt/X11/lib
extra-include-dirs:
- /opt/X11/include |
Ran into this today trying to install xmonad on OS X for the 1st time (though I've used xmonad on other operating systems like Linux in the past but just used the package manager to install it rather than cabal-install). Thanks to @adamse for the fix to the -lXss issue! That combined with https://wiki.haskell.org/Xmonad/Using_xmonad_on_Apple_OSX#Modern_installation_instructions helped me get xmonad working on OS X High Sierra. |
error:
ld: library not found for -lXss
full log below
The text was updated successfully, but these errors were encountered: