Skip to content

Undefined Reference to bitpit::ParaTree::ParaTree #456

@myermo

Description

@myermo

Hi there,

I hope this message finds you well. I'm encountering an issue while attempting to use the Paratree object in my project. Whenever I compile my code, I encounter the following error:

/usr/bin/ld: /tmp/cc5WslX9.ltrans0.ltrans.o: in function `main':
<artificial>:(.text+0x6bb85): undefined reference to `bitpit::ParaTree::ParaTree(unsigned char, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'

It seems like there's an undefined reference to bitpit::ParaTree::ParaTree during the linking phase. I've checked my code and made sure that I'm including all necessary headers and linking against the appropriate libraries, but I'm still encountering this issue.

Here's a brief overview of my setup:

  • Compiler: g++ 13.2.1
  • Operating System: Arch Linux with Kernel 6.7.8

Steps to reproduce:

  1. Include <bitpit/ParaTree.hpp> in a file.
  2. Try to build the Paratree with bitpit::ParaTree pt(2);

I've tried various solutions such as checking the include paths, ensuring the correct libraries are linked, and confirming that the necessary functions are declared and defined properly, but the problem persists.

The only library I have to link bitpit is libbitpit_MPI.so. Also, I'm compiling the library enabling MPI support with -D BITPIT_ENABLE_MPI=on.

Could you please provide guidance on how to resolve this issue? Any help would be greatly appreciated.

Thank you for your time and assistance.

Best regards,
myermo

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions