gitin
gitin copied to clipboard
Issues with installing gitin
When installing, it errors out:
~ > go get -u github.com/isacikgoz/gitin
# github.com/libgit2/git2go
go/src/github.com/libgit2/git2go/git_dynamic.go:10:3: error: #error "Invalid libgit2 version; this git2go supports libgit2 v0.27"
10 | # error "Invalid libgit2 version; this git2go supports libgit2 v0.27"
| ^~~~~
Hey @thecsw , thanks for the feedback I will be looking into this once I come back from vacation. Meanwhile, you can use precompiled version from releases page.
@isacikgoz Great, thanks! Will be looking forward to it. For now, I'll grab on of the binaries
Yes. I am attempting to port this to FreeBSD, and am receiving the same error.
Hello @thecsw and @jhelfman,
I added git package into project to reduce complexity of dependencies therefore it is not dependent to isacikgoz/libgit2api anymore. I also switched the git2go dependency to gopkg.in/libgit2/git2go.v27. With this you may able to build gitin with 2 different methods.
- You may individually build/install/get libgit2.v27 and use dynamic linking. (you can find docs to how to build libgit2 here or more detailed ones on the internet)
- You can statically link via running/building with
--tags staticparameter. (e.g.go build --tags static) To do this, sincegitinuses go modules, you need to do a hack:- You need to copy the build folder which is inside the
$GOPATH/src/gopkg.in/libgit2/git2go.v27/vendorto$GOPATH/pkg/mod/gopkg.in/libgit2/[email protected]/vendor - Now you can use
--tags staticflag to do static builds. - This issue may not be an issue if I didn't use go modules. (I will look for a more appropriate solution to this issue.)
- You need to copy the build folder which is inside the
I am able to build with the both alternatives. You may also want to try.
Thanks for all the feedback, and I am looking forward to hear more feedback from you.
I'm still trying to figure out how to build this based on the information you've supplied, but no luck as of yet. Will get back to you if and when I do. In the meanwhile, simplifying the build would be excellent.
You are right @jhelfman It was as easy as running a simple make before go modules. I will be working on this issue.
Thank you, and I appreciate your commitment. Is there a commit I can build against in the meanwhile that would build successfully with ‘make’ until it is worked out? This is actually my first go port, and had no idea they were painful until now. :)
Any update on this?
I got some stuff I would like to work on to improve gitin, but can't run it locally. Getting the same errors 😕
Sorry for the massive delay on this! I updated the README.md and Makefile. Now it is much easier to build gitin. If you run into troubles feel free to open new issues about it.
@isacikgoz Might be time to close this, eh?
Hah! Thank you, crazy it’s been more than four years. Take care!