{"action":"created","issue":{"url":"https://api.github.com/repos/cloudson/gitql/issues/30","repository_url":"https://api.github.com/repos/cloudson/gitql","labels_url":"https://api.github.com/repos/cloudson/gitql/issues/30/labels{/name}","comments_url":"https://api.github.com/repos/cloudson/gitql/issues/30/comments","events_url":"https://api.github.com/repos/cloudson/gitql/issues/30/events","html_url":"https://github.com/cloudson/gitql/issues/30","id":195613995,"number":30,"title":"building from src on OS/X (and/or installing)","user":{"login":"yarko","id":36553,"avatar_url":"https://avatars.githubusercontent.com/u/36553?v=3","gravatar_id":"","url":"https://api.github.com/users/yarko","html_url":"https://github.com/yarko","followers_url":"https://api.github.com/users/yarko/followers","following_url":"https://api.github.com/users/yarko/following{/other_user}","gists_url":"https://api.github.com/users/yarko/gists{/gist_id}","starred_url":"https://api.github.com/users/yarko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yarko/subscriptions","organizations_url":"https://api.github.com/users/yarko/orgs","repos_url":"https://api.github.com/users/yarko/repos","events_url":"https://api.github.com/users/yarko/events{/privacy}","received_events_url":"https://api.github.com/users/yarko/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-12-14T18:52:06Z","updated_at":"2016-12-15T20:23:53Z","closed_at":null,"body":"After `make`ing on Mac, fails with *.dyld thus:\r\n\r\n```\r\n$ ./gitql 'select author, message, hash from commits where \"travis\" in message'\r\ndyld: Library not loaded: libgit2.21.dylib\r\n  Referenced from: ${GOPATH}/src/github.com/cloudson/gitql/./gitql\r\n  Reason: image not found\r\nAbort trap: 6\r\n```\r\n\r\nAccording to [apple developer docs](https://developer.apple.com/library/content/documentation/DeveloperTools/Conceptual/DynamicLibraries/100-Articles/UsingDynamicLibraries.html),\r\nyou should be able to set any of \r\n`LD_LIBRARY_PATH`,\r\n`DYLD_LIBRARY_PATH`, or \r\n`DYLD_FALLBACK_LIBRARY_PATH`.\r\n\r\nbut for me (on Sierra 10.12.1), only the last two work.\r\n\r\nAn alternative _not_ requiring an environment variable is to install the libraries (link them)\r\nin `/usr/local/lib`.\r\n\r\nRunning this post-installation script from the same directory as `make`, on Mac works for me. I'll leave it to you to edit the `echo` out.\r\n\r\n```\r\nfor i in  $(PWD)/libgit2/install/lib/lib*\r\ndo\r\n    targ=\"$(basename $i)\"\r\n    bn=$targ\r\n    dn=\"$(dirname $i)\"\r\n    [ -L \"$i\" ] && targ=\"$(readlink $i)\"\r\n    echo \"ln -s $dn/$targ /usr/local/lib/$bn\"\r\ndone\r\n```\r\n\r\nNote:  If you ever run `make clean` from the build directory, your installed commands will stop working, so it may be wiser to copy the two main `*.dyld` files into /usr/local/bin, and link everything else back to them.   Doing that could look something like this:\r\n\r\n```\r\nfor i in  $(PWD)/libgit2/install/lib/lib*\r\ndo\r\n    [ -L \"$i\" ] && echo \"ln -s /usr/local/lib/$(readlink $i) /usr/local/lib/${sr}\" \\\r\n                    || echo \"cp $i /usr/local/lib\"\r\ndone\r\n```"},"comment":{"url":"https://api.github.com/repos/cloudson/gitql/issues/comments/267434114","html_url":"https://github.com/cloudson/gitql/issues/30#issuecomment-267434114","issue_url":"https://api.github.com/repos/cloudson/gitql/issues/30","id":267434114,"user":{"login":"luizperes","id":6173065,"avatar_url":"https://avatars.githubusercontent.com/u/6173065?v=3","gravatar_id":"","url":"https://api.github.com/users/luizperes","html_url":"https://github.com/luizperes","followers_url":"https://api.github.com/users/luizperes/followers","following_url":"https://api.github.com/users/luizperes/following{/other_user}","gists_url":"https://api.github.com/users/luizperes/gists{/gist_id}","starred_url":"https://api.github.com/users/luizperes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luizperes/subscriptions","organizations_url":"https://api.github.com/users/luizperes/orgs","repos_url":"https://api.github.com/users/luizperes/repos","events_url":"https://api.github.com/users/luizperes/events{/privacy}","received_events_url":"https://api.github.com/users/luizperes/received_events","type":"User","site_admin":false},"created_at":"2016-12-15T20:23:53Z","updated_at":"2016-12-15T20:23:53Z","body":"It looks neat @cloudson! I will check that on my Mac and reply you back!"}}
{"actor":{"display_login":"luizperes"}}