[CDRIVER-2713] Some branch don't are using the bundle libbson in cmake Created: 20/Jun/18  Updated: 28/Oct/23  Resolved: 28/Jun/18

Status: Closed
Project: C Driver
Component/s: libbson
Affects Version/s: 1.8.2, 1.9.5
Fix Version/s: None

Type: Bug Priority: Minor - P4
Reporter: Gustavo Brondani Schenkel Assignee: Kevin Albertson
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

MSYS2
cmake 3.11.4
gcc 7.3.0
make 4.2.1


Attachments: Text File CMakeLists.txt    

 Description   

I made a clean install of my environment and tried compile the r1.9 branch(git), and the cmake couldn't find libbson in the environment. It must use bundle if the env don't have one.

Workaround is use 'master' to install libbson in the environment, than change branch to use r1.9.



 Comments   
Comment by Gustavo Brondani Schenkel [ 17/Jul/18 ]

Sorry, was on vacation. I tried compile yesterday and was all smooth, Thanks guys.

Comment by A. Jesse Jiryu Davis [ 28/Jun/18 ]

Gustavo, I'm closing this ticket; please reopen if you have further issues building the C Driver.

Comment by Kevin Albertson [ 28/Jun/18 ]

Hi Gustavo, apologies for the delay.

Can you try a fresh install with 1.11.0 (see our installation docs), which should use bundled libbson by default.

If that fails, can you share the commands your running with the output?

Comment by Kevin Albertson [ 21/Jun/18 ]

Oops, I misremembered. Indeed r1.9 does not have ENABLE_BSON.

Comment by Gustavo Brondani Schenkel [ 21/Jun/18 ]

Hi Kevin, CMakeList from r1.9 doesn't have the ENABLE_BSON option.

CMakeLists.txt

Comment by Kevin Albertson [ 21/Jun/18 ]

Hi Gustavo, in 1.9 and 1.10 the default behavior of how libbson was included changed.

In 1.9 the default was to use the system installed libbson first, then fall back to using bundled. But you can specify -DENABLE_BSON=BUNDLED to use the bundled libbson (this option changed in 1.10).

In 1.10 the default is to use a bundled libbson, but you can specify -DENABLE_BSON=SYSTEM to use a system installed libbson. There is no longer a BUNDLED value of the ENABLE_BSON cmake option.

 

Comment by Gustavo Brondani Schenkel [ 20/Jun/18 ]

Sorry, the workaround doesn't work, since libbson is on 1.11.0-dev version, it broke the compile of r1.9 branch. I think is good to build/use always the bundled libbson, as default, to force compability, and to have a cmake option to use the libbson from environment.

Generated at Wed Feb 07 21:16:07 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.