astrada / google-drive-ocamlfuse

FUSE filesystem over Google Drive
https://astrada.github.io/google-drive-ocamlfuse/
MIT License
5.55k stars 353 forks source link

cannot install google-drive-ocamlfuse on ocaml 4.05.0 #356

Closed tknr closed 5 years ago

tknr commented 7 years ago

please tell me what is lack or wrong...

[foo@bar ~]$ uname -a
Linux bar.com 2.6.32-696.10.2.el6.x86_64 #1 SMP Tue Sep 12 14:33:29 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
[foo@bar ~]$ cat /etc/redhat-release 
CentOS release 6.9 (Final)
[foo@bar ~]$ opam --version
1.2.2
[foo@bar ~]$ ocaml --version
The OCaml toplevel, version 4.05.0
[foo@bar ~]$ opam switch
--     -- 3.07    Official 3.07 release
--     -- 3.08.0  Official 3.08.0 release
--     -- 3.08.1  Official 3.08.1 release
--     -- 3.08.2  Official 3.08.2 release
--     -- 3.08.3  Official 3.08.3 release
--     -- 3.08.4  Official 3.08.4 release
--     -- 3.09.0  Official 3.09.0 release
--     -- 3.09.1  Official 3.09.1 release
--     -- 3.09.2  Official 3.09.2 release
--     -- 3.09.3  Official 3.09.3 release
--     -- 3.10.0  Official 3.10.0 release
--     -- 3.10.1  Official 3.10.1 release
--     -- 3.10.2  Official 3.10.2 release
--     -- 3.11.0  Official 3.11.0 release
--     -- 3.11.1  Official 3.11.1 release
--     -- 3.11.2  Official 3.11.2 release
--     -- 3.12.0  Official 3.12.0 release
--     -- 3.12.1  Official 3.12.1 release
--     -- 4.00.0  Official 4.00.0 release
--     -- 4.00.1  Official 4.00.1 release
--     -- 4.01.0  Official 4.01.0 release
--     -- 4.02.0  Official 4.02.0 release
4.02.1  I 4.02.1  Official 4.02.1 release
--     -- 4.02.2  Official 4.02.2 release
--     -- 4.02.3  Official 4.02.3 release
--     -- 4.03.0  Official 4.03.0 release
--     -- 4.04.0  Official 4.04.0 release
4.04.1  I 4.04.1  Official 4.04.1 release
--     -- 4.04.2  Official 4.04.2 release
4.05.0  C 4.05.0  Official 4.05.0 release
# 247 more patched or experimental compilers, use '--all' to show
[foo@bar ~]$ opam install google-drive-ocamlfuse
The following actions will be performed:
  ∗  install google-drive-ocamlfuse 0.6.21

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[google-drive-ocamlfuse] Archive in cache

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ERROR] The compilation of google-drive-ocamlfuse failed at "ocaml setup.ml -build".
Processing  1/1: [google-drive-ocamlfuse: ocaml]
#=== ERROR while installing google-drive-ocamlfuse.0.6.21 =====================#
# opam-version 1.2.2
# os           linux
# command      ocaml setup.ml -build
# path         /home/foo/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21
# compiler     4.05.0
# exit-code    1
# env-file     /home/foo/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21/google-drive-ocamlfuse-28863-58c514.env
# stdout-file  /home/foo/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21/google-drive-ocamlfuse-28863-58c514.out
# stderr-file  /home/foo/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21/google-drive-ocamlfuse-28863-58c514.err
### stdout ###
# [...]
# /home/foo/.opam/4.05.0/bin/ocamlfind ocamlopt -g -linkpkg -package Fuse -package camlidl -package gapi-ocaml -package sqlite3 -package threads -thread -I src src/utils.cmx src/config.cmx src/appDir.cmx src/bufferPool.cmx src/buffering.cmx src/cache.cmx src/concurrentGlobal.cmx src/keyValueStore.cmx src/state.cmx src/threadPool.cmx src/context.cmx src/gaeProxy.cmx src/mime.cmx src/oauth2.cmx src/drive.cmx src/gdfuse.cmx -o src/gdfuse.native
# + /home/foo/.opam/4.05.0/bin/ocamlfind ocamlopt -g -linkpkg -package Fuse -package camlidl -package gapi-ocaml -package sqlite3 -package threads -thread -I src src/utils.cmx src/config.cmx src/appDir.cmx src/bufferPool.cmx src/buffering.cmx src/cache.cmx src/concurrentGlobal.cmx src/keyValueStore.cmx src/state.cmx src/threadPool.cmx src/context.cmx src/gaeProxy.cmx src/mime.cmx src/oauth2.cmx src/drive.cmx src/gdfuse.cmx -o src/gdfuse.native
# /home/foo/.opam/4.05.0/lib/zarith/libzarith.a(caml_z.o): 関数 `ml_z_mul' 内:
# caml_z.c:(.text+0x471f): `__gmpn_sqr' に対する定義されていない参照です
# /home/foo/.opam/4.05.0/lib/zarith/libzarith.a(caml_z.o): 関数 `ml_z_powm_sec' 内:
# caml_z.c:(.text+0x9fa8): `__gmpz_powm_sec' に対する定義されていない参照です
# collect2: error: ld returned 1 exit status
# File "caml_startup", line 1:
# Error: Error during linking
# Command exited with code 2.
### stderr ###
# E: Failure("Command ''/home/foo/.opam/4.05.0/bin/ocamlbuild' src/gdfuse.native -tag debug' terminated with error code 10")

=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The following actions failed
  ∗  install google-drive-ocamlfuse 0.6.21
No changes have been performed

raw log is above... google_drive_ocamlfuse_log.txt

astrada commented 7 years ago

I think you have a problem with libgmp-dev. Have you installed the external dependencies?

opam install depext
opam depext google-drive-ocamlfuse
tknr commented 7 years ago

thank for reply. i checked dependency,

opam install depext
$ opam depext google-drive-ocamlfuse 
# Detecting depexts using flags: x86_64 linux centos
# The following system packages are needed:
#  - fuse-devel
#  - gmp
#  - gmp-devel
#  - libcurl-devel
#  - m4
#  - openssl-devel
#  - pkgconfig
#  - sqlite-devel
#  - which
#  - zlib-devel
Name        : fuse-devel                   Relocations: (not relocatable)
Version     : 2.8.3                             Vendor: CentOS
Release     : 5.el6                         Build Date: 2016年05月11日 16時38分49秒
Install Date: 2016年05月27日 01時22分41秒      Build Host: worker1.bsys.centos.org
Group       : Development/Libraries         Source RPM: fuse-2.8.3-5.el6.src.rpm
Size        : 108219                           License: LGPLv2+
Signature   : RSA/SHA1, 2016年05月12日 19時50分13秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://fuse.sf.net
Summary     : File System in Userspace (FUSE) devel files
Description :
With FUSE it is possible to implement a fully functional filesystem in a
userspace program. This package contains development files (headers,
pgk-config) to develop FUSE based applications/filesystems.
Name        : gmp                          Relocations: (not relocatable)
Version     : 4.3.1                             Vendor: CentOS
Release     : 12.el6                        Build Date: 2017年03月22日 12時47分19秒
Install Date: 2017年04月06日 14時50分28秒      Build Host: c1bm.rdu2.centos.org
Group       : System Environment/Libraries   Source RPM: gmp-4.3.1-12.el6.src.rpm
Size        : 657883                           License: LGPLv2+ and  GPLv3+ and LGPLv3+
Signature   : RSA/SHA1, 2017年03月24日 00時01分45秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://gmplib.org/
Summary     : A GNU arbitrary precision library
Description :
The gmp package contains GNU MP, a library for arbitrary precision
arithmetic, signed integers operations, rational numbers and floating
point numbers. GNU MP is designed for speed, for both small and very
large operands. GNU MP is fast because it uses fullwords as the basic
arithmetic type, it uses fast algorithms, it carefully optimizes
assembly code for many CPUs' most common inner loops, and it generally
emphasizes speed over simplicity/elegance in its operations.

Install the gmp package if you need a fast arbitrary precision
library.
Name        : gmp-devel                    Relocations: (not relocatable)
Version     : 4.3.1                             Vendor: CentOS
Release     : 12.el6                        Build Date: 2017年03月22日 12時47分19秒
Install Date: 2017年04月06日 15時00分24秒      Build Host: c1bm.rdu2.centos.org
Group       : Development/Libraries         Source RPM: gmp-4.3.1-12.el6.src.rpm
Size        : 344621                           License: LGPLv2+ and  GPLv3+ and LGPLv3+
Signature   : RSA/SHA1, 2017年03月24日 00時04分14秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://gmplib.org/
Summary     : Development tools for the GNU MP arbitrary precision library
Description :
The libraries, header files and documentation for using the GNU MP
arbitrary precision library in applications.

If you want to develop applications which will use the GNU MP library,
you'll need to install the gmp-devel package.  You'll also need to
install the gmp package.
Name        : libcurl-devel                Relocations: (not relocatable)
Version     : 7.19.7                            Vendor: CentOS
Release     : 53.el6_9                      Build Date: 2017年04月03日 23時14分07秒
Install Date: 2017年04月06日 14時59分39秒      Build Host: c1bm.rdu2.centos.org
Group       : Development/Libraries         Source RPM: curl-7.19.7-53.el6_9.src.rpm
Size        : 497647                           License: MIT
Signature   : RSA/SHA1, 2017年04月05日 01時34分15秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://curl.haxx.se/
Summary     : Files needed for building applications with libcurl
Description :
cURL is a tool for getting files from FTP, HTTP, Gopher, Telnet, and
Dict servers, using any of the supported protocols. The libcurl-devel
package includes files needed for developing applications which can
use cURL's capabilities internally.
Name        : m4                           Relocations: (not relocatable)
Version     : 1.4.13                            Vendor: CentOS
Release     : 5.el6                         Build Date: 2010年11月12日 02時17分34秒
Install Date: 2011年07月14日 18時46分44秒      Build Host: c6b3.bsys.dev.centos.org
Group       : Applications/Text             Source RPM: m4-1.4.13-5.el6.src.rpm
Size        : 560949                           License: GPLv3+
Signature   : RSA/8, 2011年07月03日 13時44分33秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://www.gnu.org/software/m4/
Summary     : The GNU macro processor
Description :
A GNU implementation of the traditional UNIX macro processor.  M4 is
useful for writing text files which can be logically parsed, and is used
by many programs as part of their build process.  M4 has built-in
functions for including files, running shell commands, doing arithmetic,
etc.  The autoconf program needs m4 for generating configure scripts, but
not for running configure scripts.

Install m4 if you need a macro processor.
Name        : openssl-devel                Relocations: (not relocatable)
Version     : 1.0.1e                            Vendor: CentOS
Release     : 57.el6                        Build Date: 2017年03月23日 06時47分09秒
Install Date: 2017年04月06日 14時59分31秒      Build Host: c1bm.rdu2.centos.org
Group       : Development/Libraries         Source RPM: openssl-1.0.1e-57.el6.src.rpm
Size        : 2288823                          License: OpenSSL
Signature   : RSA/SHA1, 2017年03月24日 00時00分42秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://www.openssl.org/
Summary     : Files for development of applications which will use OpenSSL
Description :
OpenSSL is a toolkit for supporting cryptography. The openssl-devel
package contains include files needed to develop applications which
support various cryptographic algorithms and protocols.
Name        : pkgconfig                    Relocations: (not relocatable)
Version     : 0.23                              Vendor: CentOS
Release     : 9.1.el6                       Build Date: 2010年08月19日 12時30分32秒
Install Date: 2011年07月14日 18時45分43秒      Build Host: c6b1.bsys.dev.centos.org
Group       : Development/Tools             Source RPM: pkgconfig-0.23-9.1.el6.src.rpm
Size        : 140091                           License: GPLv2+
Signature   : RSA/8, 2011年07月03日 13時57分05秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://pkgconfig.freedesktop.org
Summary     : A tool for determining compilation options
Description :
The pkgconfig tool determines compilation options. For each required
library, it reads the configuration file and outputs the necessary
compiler and linker flags.
Name        : sqlite-devel                 Relocations: (not relocatable)
Version     : 3.6.20                            Vendor: CentOS
Release     : 1.el6_7.2                     Build Date: 2015年08月17日 19時25分28秒
Install Date: 2015年08月20日 15時57分37秒      Build Host: c6b8.bsys.dev.centos.org
Group       : Development/Libraries         Source RPM: sqlite-3.6.20-1.el6_7.2.src.rpm
Size        : 289974                           License: Public Domain
Signature   : RSA/SHA1, 2015年08月18日 00時29分10秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://www.sqlite.org/
Summary     : Development tools for the sqlite3 embeddable SQL database engine
Description :
This package contains the header files and development documentation
for sqlite. If you like to develop programs using sqlite, you will need
to install sqlite-devel.
Name        : which                        Relocations: (not relocatable)
Version     : 2.19                              Vendor: CentOS
Release     : 6.el6                         Build Date: 2011年09月23日 19時47分56秒
Install Date: 2012年01月07日 04時31分57秒      Build Host: c6b18n1.dev.centos.org
Group       : Applications/System           Source RPM: which-2.19-6.el6.src.rpm
Size        : 73004                            License: GPLv3
Signature   : RSA/SHA1, 2011年09月26日 13時26分13秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://www.xs4all.nl/~carlo17/which/
Summary     : Displays where a particular program in your path is located
Description :
The which command shows the full pathname of a specified program, if
the specified program is in your PATH.
Name        : zlib-devel                   Relocations: (not relocatable)
Version     : 1.2.3                             Vendor: CentOS
Release     : 29.el6                        Build Date: 2013年02月22日 08時02分17秒
Install Date: 2013年03月14日 21時14分32秒      Build Host: c6b9.bsys.dev.centos.org
Group       : Development/Libraries         Source RPM: zlib-1.2.3-29.el6.src.rpm
Size        : 117496                           License: zlib and Boost
Signature   : RSA/SHA1, 2013年02月24日 02時40分28秒, Key ID 0946fca2c105b9de
Packager    : CentOS BuildSystem <http://bugs.centos.org>
URL         : http://www.gzip.org/zlib/
Summary     : Header files and libraries for Zlib development
Description :
The zlib-devel package contains the header files and libraries needed
to develop programs that use the zlib compression and decompression
library.
# All required OS packages found.

the required packages seems installed...hmm...

astrada commented 7 years ago

Maybe, you can try downgrading zarith to 1.5:

opam pin add zarith 1.5
tknr commented 7 years ago

thank,i tried

[tknr@server ~]$ opam pin add zarith 1.5
[NOTE] Package zarith is already version-pinned to 1.5.
       This will erase any previous custom definition.
Proceed ? [Y/n] Y

[zarith] https://github.com/ocaml/Zarith/archive/release-1.5.tar.gz downloaded

[tknr@server ~]$ opam install google-drive-ocamlfuse
The following actions will be performed:
  ∗  install google-drive-ocamlfuse 0.6.21

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[google-drive-ocamlfuse] Archive in cache

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ERROR] The compilation of google-drive-ocamlfuse failed at "ocaml setup.ml -build".
Processing  1/1: [google-drive-ocamlfuse: ocaml]
#=== ERROR while installing google-drive-ocamlfuse.0.6.21 =====================#
# opam-version 1.2.2
# os           linux
# command      ocaml setup.ml -build
# path         /home/tknr/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21
# compiler     4.05.0
# exit-code    1
# env-file     /home/tknr/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21/google-drive-ocamlfuse-29810-58c514.env
# stdout-file  /home/tknr/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21/google-drive-ocamlfuse-29810-58c514.out
# stderr-file  /home/tknr/.opam/4.05.0/build/google-drive-ocamlfuse.0.6.21/google-drive-ocamlfuse-29810-58c514.err
### stdout ###
# [...]
# /home/tknr/.opam/4.05.0/bin/ocamlfind ocamlopt -g -linkpkg -package Fuse -package camlidl -package gapi-ocaml -package sqlite3 -package threads -thread -I src src/utils.cmx src/config.cmx src/appDir.cmx src/bufferPool.cmx src/buffering.cmx src/cache.cmx src/concurrentGlobal.cmx src/keyValueStore.cmx src/state.cmx src/threadPool.cmx src/context.cmx src/gaeProxy.cmx src/mime.cmx src/oauth2.cmx src/drive.cmx src/gdfuse.cmx -o src/gdfuse.native
# + /home/tknr/.opam/4.05.0/bin/ocamlfind ocamlopt -g -linkpkg -package Fuse -package camlidl -package gapi-ocaml -package sqlite3 -package threads -thread -I src src/utils.cmx src/config.cmx src/appDir.cmx src/bufferPool.cmx src/buffering.cmx src/cache.cmx src/concurrentGlobal.cmx src/keyValueStore.cmx src/state.cmx src/threadPool.cmx src/context.cmx src/gaeProxy.cmx src/mime.cmx src/oauth2.cmx src/drive.cmx src/gdfuse.cmx -o src/gdfuse.native
# /home/tknr/.opam/4.05.0/lib/zarith/libzarith.a(caml_z.o): 関数 `ml_z_mul' 内:
# caml_z.c:(.text+0x515f): `__gmpn_sqr' に対する定義されていない参照です
# /home/tknr/.opam/4.05.0/lib/zarith/libzarith.a(caml_z.o): 関数 `ml_z_powm_sec' 内:
# caml_z.c:(.text+0xbdd8): `__gmpz_powm_sec' に対する定義されていない参照です
# collect2: error: ld returned 1 exit status
# File "caml_startup", line 1:
# Error: Error during linking
# Command exited with code 2.
### stderr ###
# E: Failure("Command ''/home/tknr/.opam/4.05.0/bin/ocamlbuild' src/gdfuse.native -tag debug' terminated with error code 10")

=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The following actions failed
  ∗  install google-drive-ocamlfuse 0.6.21
No changes have been performed

but failed...

[tknr@server ~]$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/home/opt/rh/devtoolset-3/root/usr/bin/../libexec/gcc/x86_64-redhat-linux/4.9.2/lto-wrapper
Target: x86_64-redhat-linux
Configured with: ../configure --prefix=/opt/rh/devtoolset-3/root/usr --mandir=/opt/rh/devtoolset-3/root/usr/share/man --infodir=/opt/rh/devtoolset-3/root/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --enable-multilib --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --enable-languages=c,c++,fortran,lto --enable-plugin --with-linker-hash-style=gnu --enable-initfini-array --disable-libgcj --with-isl=/builddir/build/BUILD/gcc-4.9.2-20150212/obj-x86_64-redhat-linux/isl-install --with-cloog=/builddir/build/BUILD/gcc-4.9.2-20150212/obj-x86_64-redhat-linux/cloog-install --with-mpc=/builddir/build/BUILD/gcc-4.9.2-20150212/obj-x86_64-redhat-linux/mpc-install --with-tune=generic --with-arch_32=i686 --build=x86_64-redhat-linux
Thread model: posix
gcc version 4.9.2 20150212 (Red Hat 4.9.2-6) (GCC)

some gcc or any version is wrong?