Fedora 22 - compile - __atomic_is_lock_free

前端 未结 2 1628
遥遥无期
遥遥无期 2021-01-19 06:23

I am try to compile a software (SuperCollider) on Fedora 22 but I run into a problem:

libsupernova.a(server.cpp.o):          


        
相关标签:
2条回答
  • 2021-01-19 07:05

    i ran into the same issue, and yes you do need to link libatomic. the way to do this is to add to the line: set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -latomic") to the top level CMakeLists.txt file before running cmake.

    the full flow might look like this:

    • git clone https://github.com/supercollider/supercollider.git
    • cd supercollider
    • add set(CMAKE_CXX_LINK_FLAGS "${CMAKE_CXX_LINK_FLAGS} -latomic") to top level CMakeLists.txt
    • run ccmake . to configure the install
    • mkdir _build ; cd _build
    • cmake ..
    • make && <sudo> make install

    you may or may not need sudo depending on where you have decided to install supercollider.

    0 讨论(0)
  • 2021-01-19 07:17

    It seems to me that this is a problem with libatomic. Is it possible that gcc does not link to libatomic?

    It only links to libatomic if you tell it to.

    Does someone have any idea on how to solve this problem?

    Link to libatomic.

    Another idea would be to try to install -latomic, but I cannot find information about. Instead I already installed libatomic. I don't know if they are the same.

    You can't "install -latomic" because -latomic is the compiler/linker option that says to link to libatomic, and you can't "install a linker option" because it's an option to a program, not a package.

    You install libatomic, then you link to it with -latomic

    (Aside: I hope to fix GCC so that you won't need to use -latomic explicitly for simple cases, only more complex ones, see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65913)

    0 讨论(0)
提交回复
热议问题