Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mac version doesn't build as it doesn't find berkeleyDB #16

Open
madhtv opened this issue Nov 13, 2023 · 1 comment
Open

Mac version doesn't build as it doesn't find berkeleyDB #16

madhtv opened this issue Nov 13, 2023 · 1 comment

Comments

@madhtv
Copy link

madhtv commented Nov 13, 2023

I installed berkeleydb using > brew install berkeley-db and now

make -j4 results in DB specific errors, see

In file included from /Users/madhulathatiruvilyamalaiviluvadri/benzene-vanilla-cmake/src/book/BookCheck.cpp:6:
In file included from /Users/madhulathatiruvilyamalaiviluvadri/benzene-vanilla-cmake/src/book/BookCheck.hpp:8:
In file included from /Users/madhulathatiruvilyamalaiviluvadri/benzene-vanilla-cmake/src/book/Book.hpp:11:
/Users//benzene-vanilla-cmake/src/util/HashDB.hpp:157:44: error: use of undeclared identifier 'db_strerror'; did you mean 'strerror'?
fprintf(stderr, "db_create: %s\n", db_strerror(ret));
^~~~~~~~~~~
strerror
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.3.sdk/usr/include/string.h:81:7: note: 'strerror' declared here
char *strerror(int __errnum) __DARWIN_ALIAS(strerror);
^
In file included from /Users/madhulathatiruvilyamalaiviluvadri/benzene-vanilla-cmake/src/book/BookCheck.cpp:6:
In file included from /Users/madhulathatiruvilyamalaiviluvadri/benzene-vanilla-cmake/src/book/BookCheck.hpp:8:
In file included from /Users/madhulathatiruvilyamalaiviluvadri/benzene-vanilla-cmake/src/book/Book.hpp:11:
/Users//benzene-vanilla-cmake/src/util/HashDB.hpp:160:22: error: no member named 'open' in '__db'
if ((ret = m_db->open(m_db, NULL, filename.c_str(), NULL,
~~~~ ^
/Users//benzene-vanilla-cmake/src/util/HashDB.hpp:161:36: error: use of undeclared identifier 'DB_CREATE'
DB_HASH, DB_CREATE, PERMISSION_FLAGS)) != 0)
^
/Users//benzene-vanilla-cmake/src/util/HashDB.hpp:163:15: error: no member named 'err' in '__db'
m_db->err(m_db, ret, "%s", m_filename.c_str());

@eilvelia
Copy link
Contributor

By default, homebrew doesn't link berkeley-db to the system (it is "keg-only"). Perhaps executing the commands provided by brew link berkeley-db should solve this, something along the lines of:

export LDFLAGS="-L/usr/local/opt/berkeley-db/lib"
export CPPFLAGS="-I/usr/local/opt/berkeley-db/include"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants