Defini-se Google Drive como: “Um aplicativo que instala uma pasta em seu computador que é semelhante às outras, exceto por uma grande diferença: a sincronização automática na nuvem.”

Como os usuários Linux oficialmente são privados deste recurso, então disponibilizo neste post  a minha receita de bolo:

Modo difícil:

Instale os requisitos conforme o comando a seguir:

# zypper install cmake libgcrypt-devel libjson-devel curl-devel libexpat-devel boost-devel

Efetue o download do código fonte:

$ git clone git://github.com/Grive/grive.git
Cloning into 'grive'...
remote: Counting objects: 2591, done.
remote: Compressing objects: 100% (865/865), done.
remote: Total 2591 (delta 1713), reused 2555 (delta 1681)
Receiving objects: 100% (2591/2591), 750.79 KiB | 74 KiB/s, done.
Resolving deltas: 100% (1713/1713), done.
$

Compile e instale os fontes :

$ cd grive
cabelo@lapdell01:/dados/neti/programas64/grive> mkdir build
cabelo@lapdell01:/dados/neti/programas64/grive> cd build/
cabelo@lapdell01:/dados/neti/programas64/grive/build> cmake ..
-- The C compiler identification is GNU 4.7.1
-- The CXX compiler identification is GNU 4.7.1
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found libgcrypt: -L/usr/lib64 -lgcrypt -lgpg-error
-- Found JSON-C: /usr/lib64/libjson.so
-- Found CURL: /usr/lib64/libcurl.so (found version "7.25.0")
-- Found EXPAT: /usr/lib64/libexpat.so (found version "2.1.0")
-- Boost version: 1.49.0
-- Found the following Boost libraries:
--   program_options
--   filesystem
--   system
-- Found libbfd: /usr/lib64/libbfd.a
-- Found CppUnit: /usr/lib64/libcppunit.so
-- Found libiberty: /usr/lib64/libiberty.a
-- Found ZLIB: /usr/lib64/libz.so (found version "1.2.7")
-- Building unitary tests along with the library and the binary
-- Configuring done
-- Generating done
-- Build files have been written to: /dados/neti/programas64/grive/build
cabelo@lapdell01:/dados/neti/programas64/grive/build> cd grive
make
Scanning dependencies of target grive
[  2%] Building CXX object libgrive/CMakeFiles/grive.dir/src/drive/Drive.cc.o
[  5%] Building CXX object libgrive/CMakeFiles/grive.dir/src/drive/ResourceTree.cc.o
[  8%] Building CXX object libgrive/CMakeFiles/grive.dir/src/drive/State.cc.o
...                 ....                        ....
...                 ....                        ....
[ 94%] Building CXX object libgrive/CMakeFiles/grive.dir/src/bfd/Debug.cc.o
[ 97%] Building CXX object libgrive/CMakeFiles/grive.dir/src/bfd/SymbolInfo.cc.o
Linking CXX static library libgrive.a
[ 97%] Built target grive
Scanning dependencies of target grive_executable
[100%] Building CXX object grive/CMakeFiles/grive_executable.dir/src/main.cc.o
Linking CXX executable grive
[100%] Built target grive_executable

Agora entre na pasta recém criada e execute o comando grive -a, acesse a URL e digite a autenticação.

mkdir ~/Grive
cd ~/Grive
./grive -a
-----------------------
Please go to this URL and get an authentication code:
https://accounts.google.com/o/oauth2/auth?scope=https%3A%2F%2Fwww.googleapis.com% .... ..... 0474.apps.googleusercontent.com
-----------------------
Please input the authentication code here:
4/nzjIrPhjkwL3ZOFWe6RUNa9YM7x1.Ug1alamoPosERshQV0ieZDApUquuIdwI

gdrive0

gdrive1

Modo Fácil:

Para os usuários openSUSE, deixo o 1 – Click Install:  install