[odb-users] Error when trying to compile with odb
Sandgrav Morten
Morten.Sandgrav at esf.se
Sun Aug 16 11:25:42 EDT 2026
Hi,
I have started to look at odb, but when I tried to compile the first example in the manual, person.hxx, I got an error:
odb -d mysql --generate-query person.hxx
cc1plus: error: cannot load plugin /usr/bin/odb.so: /usr/bin/odb.so: undefined symbol: tree_code_type
I am working on docker, so I have attached the dockerfile and as I said, the file I am trying to compile is person.hxx:
// person.hxx
//
#include <string>
#include <odb/core.hxx> // (1)
#pragma db object // (2)
class person
{
private:
person () {} // (3)
friend class odb::access; // (4)
#pragma db id auto // (5)
unsigned long long id_; // (5)
std::string first_;
std::string last_;
unsigned short age_;
};
What am I doing wrong?
Morten Sandgrav
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Dockerfile.ebsc
Type: application/octet-stream
Size: 2354 bytes
Desc: Dockerfile.ebsc
Url : https://codesynthesis.com/pipermail/odb-users/attachments/20260816/69f8db73/Dockerfile.obj
More information about the odb-users
mailing list