GithubHelp home page GithubHelp logo

Compilation error on Linux about rust-rocksdb HOT 8 CLOSED

tikv avatar tikv commented on July 26, 2024
Compilation error on Linux

from rust-rocksdb.

Comments (8)

Hoverbear avatar Hoverbear commented on July 26, 2024 1

Workaround:

CXXFLAGS="-Wno-deprecated-copy -Wno-pessimizing-move -Wno-sign-compare" cargo build

Seems when building TiKV with this you need:

CXXFLAGS='-Wno-error=deprecated-copy -Wno-error=pessimizing-move -Wno-error=sign-compare' cargo build

from rust-rocksdb.

yiwu-arbug avatar yiwu-arbug commented on July 26, 2024 1

Fix facebook/rocksdb#5651

from rust-rocksdb.

yiwu-arbug avatar yiwu-arbug commented on July 26, 2024

gcc has version 9 already?!

from rust-rocksdb.

BusyJay avatar BusyJay commented on July 26, 2024

Surprise! /cc facebook/rocksdb#5303

from rust-rocksdb.

BusyJay avatar BusyJay commented on July 26, 2024

Build with latest cherry pick still fails with following:

/home/jay/.cargo/git/checkouts/rust-rocksdb-82ef6e5337b3fbe6/6ead62c/librocksdb_sys/rocksdb/port/port_posix.cc: In function ‘int rocksdb::port::GetMaxOpenFiles()’:
/home/jay/.cargo/git/checkouts/rust-rocksdb-82ef6e5337b3fbe6/6ead62c/librocksdb_sys/rocksdb/port/port_posix.cc:180:31: error: comparison of integer expressions of different signedness: ‘rlim_t’ {aka ‘long unsigned int’} and ‘int’ [-Werror=sign-compare]
  180 |   if (no_files_limit.rlim_cur >= std::numeric_limits<int>::max()) {
      |       ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
gmake[4]: *** [CMakeFiles/rocksdb.dir/build.make:2991: CMakeFiles/rocksdb.dir/port/port_posix.cc.o] Error 1
gmake[4]: *** Waiting for unfinished jobs....
gmake[3]: *** [CMakeFiles/Makefile2:2714: CMakeFiles/rocksdb.dir/all] Error 2
gmake[2]: *** [CMakeFiles/Makefile2:2726: CMakeFiles/rocksdb.dir/rule] Error 2
gmake[1]: *** [Makefile:1036: rocksdb] Error 2
thread 'main' panicked at '
command did not execute successfully, got: exit code: 2

build script failed, must exit now', /home/jay/.cargo/registry/src/github.com-1ecc6299db9ec823/cmake-0.1.40/src/lib.rs:832:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.

make: *** [Makefile:210: clippy] Error 101
env TMPDIR=/mnt/wwn-0x5002538d00000000-part1/workspace/temp/ make dev  1389.83s user 134.81s system 206% cpu 12:19.09 total

from rust-rocksdb.

yiwu-arbug avatar yiwu-arbug commented on July 26, 2024

@BusyJay not reproducing on my side (ubuntu 19.10 + gcc9). Does adding static_cast<int> around no_files_limit.rlim_cur work for you?

from rust-rocksdb.

BusyJay avatar BusyJay commented on July 26, 2024

I can confirm that rust-rocksdb is built successfully using the latest compile toolchains on fedora 30.

from rust-rocksdb.

Hoverbear avatar Hoverbear commented on July 26, 2024

Related to #343

from rust-rocksdb.

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.