Skip to content
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

macports: avoid dylib/link confusion #28

Closed
wants to merge 1 commit into from

Conversation

rurban
Copy link

@rurban rurban commented Jul 6, 2016

use true bundle/dylib extensions, avoid mixup, avoid hardcoded .so,
add -L/opt/local/lib -I/opt/local/include search paths for macports,
use libglfw.dylib, not libglfw3.dylib

not necesserily to be merged, but this is what I needed

use true bundle/dylib extensions, avoid mixup, avoid hardcoded .so,
add -L/opt/local/lib -I/opt/local/include search paths for macports,
use libglfw.dylib, not libglfw3.dylib
@eriksvedang
Copy link
Collaborator

Nice, making it work well with macports would be great. I get a lot of errors when running the tests after this patch though. I think it has to do with the .bundle suffix. Run the tests with CARP_DEV=1 carp.

@daveyarwood
Copy link

@rurban Your instructions in INSTALL.md pointed me in the right direction to build Carp successfully! 🎉

I use Homebrew, not Macports, so my libffi is in a slightly different directory. What I ran was:

git clone https://github.com/eriksvedang/Carp.git
cd Carp
cmake . -DLIBFFI_INCLUDE_PATH=/usr/local/opt/libffi/lib/libffi-3.0.13/include/ -DLIBFFI_LIBRARY_PATH=/usr/local/opt/libffi/lib/
make

(if (linux?) (def *LIBNAME* "libglfw.so") "")
;(if (osx?) (def *LIBNAME* "libglfw3.dylib") "")
;(if (linux?) (def *LIBNAME* "libglfw.so") "")
(def *LIBNAME* (str (if (windows?) "" "lib") "glfw" (:dylib-extension platform-specifics))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I find this a lot harder to reason about.

Where is the '3' needed for 'libglfw3.dylib' now coming from?

I would much prefer an if for each os, as previously done.

@chrisosaurus
Copy link
Contributor

since @daveyarwood was helped by install instructions I think it is worth including those too.

@eriksvedang
Copy link
Collaborator

I (manually) added the changes suggested by @mkfifo and will now close this. Added you as a contributor to README.md, @rurban . Thanks for the help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants