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

Compiling on fedora 25 #123

Closed
Slaedr opened this issue Dec 7, 2016 · 2 comments
Closed

Compiling on fedora 25 #123

Slaedr opened this issue Dec 7, 2016 · 2 comments

Comments

@Slaedr
Copy link

Slaedr commented Dec 7, 2016

Hi. First, thanks for this wonderful tool; I've been using it on Ubuntu 16.04. I am now trying to compile it on Fedora 25. There are two (perhaps related, I don't know) issues:

  1. The json-c package in fedora is located in json-c/ directory rather than json directory, and library file is called json-c rather than json.
    Solution: I changed to CMake module file for that, and it worked. Next, in file libgrive/src/protocol/Json.cc, I made a similar change in the include directives.Perhaps a check could be added to both places and depending on the system (maybe use uname -r ? I'm not familiar with that kind of thing) include json-c/* rather than json.*

  2. I get a runtime exception while running grive for the first time with -a. After I enter the authentication code, I get

Reading local directories
Synchronizing folders
exception: /home/akashi/Downloads/grive-master/libgrive/src/protocol/AuthAgent.cc(174): Throw in function long int gr::AuthAgent::CheckHttpResponse(long int, const string&, const gr::http::Header&)
Dynamic exception type: boost::exception_detail::clone_implgr::http::Error
[gr::expt::BacktraceTag*] = #0 0x511a04 :0 gr::Exception::Exception()
#1 0x4f443b :0 gr::http::Error::Error()
#2 0x4fab69 :0 gr::AuthAgent::CheckHttpResponse(long, std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&, gr::http::Header const&)
#3 0x4fa614 :0 gr::AuthAgent::Get(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&, gr::DataStream*, gr::http::Header const&)
#4 0x4dfbd2 :0 gr::v1::Drive::SyncFolders()
#5 0x4e0146 :0 gr::v1::Drive::DetectChanges()
#6 0x4c942f :0 Main(int, char**)
#7 0x4c99a3 :0 main
#8 0x7f22ef5a7401 /lib64/libc.so.6 __libc_start_main
#9 0x4c834a :0 _start

[gr::http::HttpResponseTag*] = 400
[gr::http::UrlTag*] = https://docs.google.com/feeds/default/private/full/-/folder?max-results=50&showroot=true
[gr::http::HeaderTag*] = Authorization: Bearer ya29.Ci-tA1WcJeKhfjdhsfjkdhsf898439r849hjkdsnhfjkdsfh8932f8wDtRKw7TDFT-Cmbkhu3dfd845vxqMoRCf-g
GData-Version: 3.0

Could you please help me if you have an idea why I might get that?

I don't know whether it's because I changed the Json.cc file or the CMake module file for json; I don't understand the error at all.

@vitalif
Copy link
Owner

vitalif commented Dec 12, 2016

It seems you're using a really old version of grive, less than 0.4. Current version don't use doclist API (docs.google.com) and don't use JSON-C at all (YAJL is used instead). Did you clone it from github.com/grive/grive ? Please use this repository, it's newer.

@Slaedr
Copy link
Author

Slaedr commented Dec 13, 2016

You're right, I re-cloned the repo and it compiles and runs fine on Fedora 25. I must have somehow gotten the older files earlier. Thank you very much, and sorry for wasting your time.

@Slaedr Slaedr closed this as completed Dec 13, 2016
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

No branches or pull requests

2 participants