microsoft / vcpkg

C++ Library Manager for Windows, Linux, and MacOS
MIT License
23.18k stars 6.39k forks source link

[libodb] Build error #28307

Open MGuillaumeF opened 1 year ago

MGuillaumeF commented 1 year ago

Host Environment

To Reproduce

Steps to reproduce the behavior:

git clone https://github.com/Microsoft/vcpkg
cd vcpkg
git pull
./bootstrap-vcpkg.sh
./vcpkg update
./vcpkg integrate install
./vcpkg install libodb-sqlite

Failure logs For example :

vcpkg/buildtrees/libodb/src/libodb-2-59eaf93c2b.clean/odb/details/shared-ptr/base.hxx:38:49: 
error: ISO C++17 does not allow dynamic exception specifications
   38 | operator new (std::size_t, odb::details::share) throw (std::bad_alloc);

Additional context

Libodb max c++ version is : C++14 version, because of dynamic exception

i haven’t found in documentation a CLI argument to select C++ standard version

LilyWangLL commented 1 year ago

Thanks for posting this issue. Could you please provide the full log?

MGuillaumeF commented 1 year ago

Thanks for your reply, the full log of commandes result below

install-x64-linux-dbg-out.log

LilyWangLL commented 1 year ago

This is a upstream issue: https://www.codesynthesis.com/pipermail/odb-users/2018-March/003972.html. Could you test the new version 2.5.0-b.3 of libodb? If this can install succeed on C++17, I will submit a PR to update libodb. The attached file is new version of libodb. You can download it and unzip it, then use these file instead of your local file and rebuild libodb. libodb.zip

MGuillaumeF commented 1 year ago

Thanks, I'll try that as soon as possible and I'll report result.

Can we choose which c++ version to use with VCPKG to continue to use 2.4.0 version of libodb (the version used and tested currently by my application) ? The beta version of libodb will be the only usable in the future ?

Because i was using vcpkg in my continuous integration (github actions) during many month (and it works very good 😊) and i would like manage my dependencies versions updates like maven or npmjs to avoid errors from incompatibly of updated dependency

MGuillaumeF commented 1 year ago

Reply of version 2.5.0-b.3 : it seems to work

nurettin commented 1 year ago

this still doesn't work out of the box.

the temporary workaround I found was to override

CXXFLAGS=--std=c++14 ./vcpkg install libodb

be warned that all dependencies will be built using this flag, but it doesn't seem to break anything since they are all C libraries.

github-actions[bot] commented 1 year ago

This is an automated message. Per our repo policy, stale issues get closed if there has been no activity in the past 180 days. The issue will be automatically closed in 14 days. If you wish to keep this issue open, please add a new comment.

github-actions[bot] commented 4 months ago

This is an automated message. Per our repo policy, stale issues get closed if there has been no activity in the past 180 days. The issue will be automatically closed in 14 days. If you wish to keep this issue open, please add a new comment.