mergestat / homebrew-mergestat

Brew Formula for the MergeStat CLI
https://github.com/mergestat/mergestat-lite
0 stars 1 forks source link

Getting Error while doing Installation & configuration of mergestat using brew #21

Open anirbandey-cg-devops opened 2 years ago

anirbandey-cg-devops commented 2 years ago

Hi, we are trying to do Installation & configuration of mergestat using brew but getting the below error /home/.cache/Homebrew/go_mod_cache/pkg/mod/github.com/libgit2/git2go/v33@v33.0.7/Build_system_dynamic.go:12:3: error: #error “Invalid libgit2 version; this git2go supports libgit2 between v1.3.0 and v1.3.0”

error “Invalid libgit2 version; this git2go supports libgit2 between v1.3.0 and v1.3.0” ^~~~~

github.com/libgit2/git2go/v33 1 /home/.cache/Homebrew/go_mod_cache/pkg/mod/github.com/libgit2/git2go/v33@v33.0.7/Build_system_static.go:12:3: error: #error “Invalid libgit2 version; this git2go supports libgit2 between v1.3.0 and v1.3.0”

error “Invalid libgit2 version; this git2go supports libgit2 between v1.3.0 and v1.3.0” ^~~~~ Makefile:16: recipe for target ‘.build/libmergestat.so’ failed make: [.build/libmergestat.so] Error 2 make: Waiting for unfinished jobs… Makefile:22: recipe for target ‘.build/mergestat’ failed make: *** [.build/mergestat] Error 2 If reporting this issue please do so at (not Homebrew/brew or Homebrew/core):

GitHub

Issues · mergestat/homebrew-mergestat 1 Brew Formula for the MergeStat CLI. Contribute to mergestat/homebrew-mergestat development by creating an account on GitHub.

For that we have installed libgit2-1.4.2 ,still the above error is coming. We are installing this in T2 macro ubuntu instance

patrickdevivo commented 2 years ago

Thanks for opening this @anirbandey-cg-devops - this is definitely an issue. I think the problem seems to be that libgit2, a build dependency for mergestat has been updated and we do not yet support/use the latest version (1.4.2). Homebrew appears to have no way of pinning dependencies to specific versions, so running brew install mergestat (after tapping this repo) cause the build error you are seeing.

For now, as a workaround, could you try using a binary from one of our published releases? https://github.com/mergestat/mergestat/releases

I will look into this and see if there's a short and long term solution, as we've run into this issue before

anirbandey-cg-devops commented 2 years ago

Hi #patrickdevivo even if we have installed libgit2-1.3.0.tar.gz, the problem is not getting resolved & it is showing as libgit2-1.4.2. As a workaround suggested by you we will try installing a binary mergestat-0.5.4.tar.gz.Lets see!

anirbandey-cg-devops commented 2 years ago

After extracting mergestat-0.5.4.zip, I am getting the below files.Could you please tell how to install mergestat from here on?

drwxrwxr-x 10 4096 Mar 7 17:46 ./ drwxr-xr-x 7 121 4096 Mar 7 17:45 ../ -rw-rw-r-- 1 106 Feb 15 21:43 .gitattributes drwxrwxr-x 3 4096 Feb 15 21:43 .github/ -rw-rw-r-- 1 1307 Feb 15 21:43 .gitignore -rw-rw-r-- 1 258 Feb 15 21:43 .mailmap drwxrwxr-x 2 4096 Feb 15 21:43 .vscode/ -rw-rw-r-- 1 17 Feb 15 21:43 CODEOWNERS -rw-rw-r-- 1 398 Feb 15 21:43 Dockerfile -rw-rw-r-- 1 1076 Feb 15 21:43 LICENSE -rw-rw-r-- 1 2780 Feb 15 21:43 Makefile -rw-rw-r-- 1 2202 Feb 15 21:43 README.md drwxrwxr-x 2 4096 Mar 7 17:46 build/ drwxrwxr-x 3 4096 Feb 15 21:43 cmd/ -rw-rw-r-- 1 58 Feb 15 21:43 codecov.yml drwxrwxr-x 2 4096 Feb 15 21:43 docs/ drwxrwxr-x 5 4096 Feb 15 21:43 extensions/ -rw-rw-r-- 1 3346 Feb 15 21:43 go.mod -rw-rw-r-- 1 98413 Feb 15 21:43 go.sum -rw-rw-r-- 1 95 Feb 15 21:43 mergestat.go drwxrwxr-x 8 4096 Feb 15 21:43 pkg/ drwxrwxr-x 2 4096 Feb 15 21:43 scripts/ -rw-rw-r-- 1 1326 Feb 15 21:43 shared.go @/mergestat-0.5.4$ pwd /home/mergestat-0.5.4

anirbandey-cg-devops commented 2 years ago

Also we were trying to install the following :- -rwxr-xr-x 1 capg capg 231 Feb 15 21:43 install_libgit2.sh* @ip-:~/mergestat-0.5.4/scripts$ And getting the below error 👎 Scanning dependencies of target git2 [100%] Linking C static library ../libgit2.a [100%] Built target git2 Install the project... -- Install configuration: "Debug" -- Installing: /usr/local/lib/pkgconfig/libgit2.pc CMake Error at src/cmake_install.cmake:41 (file): file INSTALL cannot copy file "/home/capg/libgit2/build/libgit2.pc" to "/usr/local/lib/pkgconfig/libgit2.pc". Call Stack (most recent call first): cmake_install.cmake:42 (include)

patrickdevivo commented 2 years ago

hi @anirbandey-cg-devops it looks like you downloaded the zip of the source code, instead try downloading mergestat-macos-amd64.tar.gz or mergestat-linux-amd64.tar.gz (depending on if you're on mac or linux) and then extract the mergestat binary (for example: tar -xzvf mergestat-macos-amd64.tar.gz) and then test by running ./mergestat.

You can move the mergestat file to somewhere in your $PATH to "install" it as well. Hopefully we can address this homebrew issue soon though

anirbandey-cg-devops commented 2 years ago

Initially we downloaded [mergestat-linux-amd64.tar.gz only and extracted the binary but didn't run ./mergestat.There was one mergestat.so file also got generated.

anirbandey-cg-devops commented 2 years ago

Hi Patrick while running this i am getting this error :- 9:53 @ip:~$ ./mergestat ./mergestat: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.28' not found (required by ./mergestat)

anirbandey-cg-devops commented 2 years ago

@ip-~$ ldd --version ldd (Ubuntu GLIBC 2.27-3ubuntu1.5) 2.27 Copyright (C) 2018 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Written by Roland McGrath and Ulrich Drepper.

anirbandey-cg-devops commented 2 years ago

GLIBC 2.27is the latest one available in the market