Git Product home page Git Product logo

Comments (4)

samcday avatar samcday commented on June 4, 2024

Interesting! Looks like the compiler doesn't like how I'm casting a pointer to int (used to build the object graph). I'm guessing you have a 64-bit compiler going here.

Simple fix, I just have to use size_t instead of int, I'll sort that out now and let you know shortly.

from node-gitteh.

samcday avatar samcday commented on June 4, 2024

I think I've sorted this out, although I'm not sure if there's any other 64bit issues. I'm currently downloading a 64-bit Ubuntu, so I can try compiling the whole thing myself.

In the meantime though, if you want to checkout the latest master branch from the repo here, it includes the fixes I mentioned previously. Hopefully there's no other issues!

from node-gitteh.

TooTallNate avatar TooTallNate commented on June 4, 2024

Ya that helps, but now it fails further down the build. The error says "void value not ignored as it ought to be". Below is a patch of what I had to do to get it to compile. Now I can start messing with the examples :)

From 07ca35081025a1d45c9b094ea969a8fb34025e66 Mon Sep 17 00:00:00 2001
From: Nathan Rajlich <[email protected]>
Date: Fri, 18 Mar 2011 20:59:13 -0700
Subject: [PATCH] Fix compiler error: "void value not ignored as it ought to be".

---
 src/rev_walker.cc |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/src/rev_walker.cc b/src/rev_walker.cc
index 67c9a9f..c831a68 100644
--- a/src/rev_walker.cc
+++ b/src/rev_walker.cc
@@ -422,10 +422,8 @@ Handle<Value> RevWalker::Sort(const Arguments& args) {
    else {

        walker->repo_->lockRepository();
-       int result = git_revwalk_sorting(walker->walker_, sorting);
+       git_revwalk_sorting(walker->walker_, sorting);
        walker->repo_->unlockRepository();
-       if(result != GIT_SUCCESS)
-           THROW_GIT_ERROR("Couldn't sort rev walker.", result);

        return Undefined();
    }
@@ -435,7 +433,7 @@ int RevWalker::EIO_Sort(eio_req *req) {
    sort_request *reqData = static_cast<sort_request*>(req->data);

    reqData->walker->repo_->lockRepository();
-   reqData->error = git_revwalk_sorting(reqData->walker->walker_, reqData->sorting);
+   git_revwalk_sorting(reqData->walker->walker_, reqData->sorting);
    reqData->walker->repo_->unlockRepository();

    return 0;
-- 
1.7.3.5

from node-gitteh.

samcday avatar samcday commented on June 4, 2024

Hey man, glad it's compiling now!

That return-value issue must mean you're not running libgit2 0.10.0 (you sure you're not on the devel branch of libgit2 or something?). They changed git_revwalk_sorting return an error code in the latest version.

Anyway I'll be adding libgit2 as a git submodule shortly, so it should eliminate any versioning issues, libgit2 is moving so fast.

Thanks for taking a look at gitteh anyway! :)

from node-gitteh.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.