[CXX-270] Clarify SCons targets Created: 02/Jul/14  Updated: 08/Jan/24  Resolved: 10/Sep/14

Status: Closed
Project: C++ Driver
Component/s: BSON
Affects Version/s: legacy-0.10.0
Fix Version/s: legacy-1.0.0-rc1

Type: Improvement Priority: Major - P3
Reporter: Andrew Morrow (Inactive) Assignee: Adam Midvidy
Resolution: Done Votes: 0
Labels: legacy-cxx
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   
  • The 'all' target doesn't actually build everything.
  • 'mongoclient-install': what else is there to install?
  • There is no Default target.

We should come up with a better set of install aliases, and ensure that the travis build actually builds every buildable target.



 Comments   
Comment by Githook User [ 10/Sep/14 ]

Author:

{u'username': u'amidvidy', u'name': u'Adam Midvidy', u'email': u'amidvidy@gmail.com'}

Message: CXX-270 change mongoclient target to driver, add examples to test target
Branch: legacy
https://github.com/mongodb/mongo-cxx-driver/commit/820932a3b6c80dd347d0c0e95ae7eecc6a24a97f

Comment by Githook User [ 03/Sep/14 ]

Author:

{u'username': u'amidvidy', u'name': u'Adam Midvidy', u'email': u'amidvidy@gmail.com'}

Message: CXX-270 update MCI config with new targets
Branch: legacy
https://github.com/mongodb/mongo-cxx-driver/commit/e05c3ed67c0a0a665d22a3345549b5d4c862a8a6

Comment by Githook User [ 03/Sep/14 ]

Author:

{u'username': u'amidvidy', u'name': u'Adam Midvidy', u'email': u'amidvidy@gmail.com'}

Message: CXX-270 Clarify Scons Targets
Branch: legacy
https://github.com/mongodb/mongo-cxx-driver/commit/ce94854737733b286a3924a576945a54c4ca6566

Comment by Tyler Brock [ 03/Sep/14 ]

Adam your strategy for all, default target, and mongoclient as well as renaming the clientTests and smokeClient to *examples look good.

I like Samantha's suggestion regarding test targets. It makes a lot of sense because if "scons test" builds and runs all of the tests then "scons unit" and "scons integration" would be expected to build and run their respective groups of tests.

Ping mira.carey@mongodb.com any thoughts?

Comment by Samantha Ritter (Inactive) [ 02/Sep/14 ]

That seems sane to me, but I wonder if it would make sense to have the targets that run the tests be the shorthand ones?

scons build-unit (builds unittests only)
scons unit (builds and runs unittests)

I feel like I've more commonly wanted to run the tests than only build them. Do other people feel this way?

Comment by Adam Midvidy [ 02/Sep/14 ]

I'm thinking along the lines of:

scons mongoclient // build libmongoclient.a
scons install --prefix=DIR // build and install libmongoclient.a to DIR

default target would be mongoclient

scons unit - build unittests
scons test-unit - run unittests
scons integration - build integration tests
scons test-integration - run integration tests

scons test - run unit and integration tests

rename clientTests to examples
rename smokeClient to run-examples

scons all would be ['mongoclient', 'unit', 'integration', 'examples']

Comments? tyler@10gen.com mira.carey@mongodb.com samantha.ritter@10gen.com

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