[CXX-1076] Generate .deb with CPack and make available through evergreen? Created: 09/Oct/16  Updated: 23/Jul/21  Resolved: 13/Sep/18

Status: Closed
Project: C++ Driver
Component/s: Build, Release
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Major - P3
Reporter: Andrew Morrow (Inactive) Assignee: Roberto Sanchez
Resolution: Won't Fix Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Gantt Dependency
has to be done before CXX-1647 Package the C++ Driver for Debian Closed
has to be done before CXX-1648 Package the C++ Driver for Fedora/RedHat Closed

 Description   

Investigate using CPack to create .deb files for Ubuntu 16.04 and Debian 8 in evergreen.

See https://groups.google.com/forum/#!topic/mongodb-user/Q8diQJspbCA for background.



 Comments   
Comment by Roberto Sanchez [ 14/Sep/18 ]

Jesse, that sounds good. Thanks for the heads up.

Comment by A. Jesse Jiryu Davis [ 13/Sep/18 ]

Roberto, I'm closing this in favor of CXX-1647 for tracking the C++ Debian work.

Comment by Roberto Sanchez [ 11/Sep/18 ]

jesse, looking at the of this ticket, it didn't seem accurate anymore given the direction we will be taking. I have gone ahead and updated the title. Let me know if you would like something different than what I chose.

Comment by Roberto Sanchez [ 10/Sep/18 ]

No problem. Once you have given some feedback on my comment to CXX-584 I should be able to begin working on that in earnest.

Comment by A. Jesse Jiryu Davis [ 10/Sep/18 ]

Thanks for the analysis! I believe (I could be wrong) that it makes sense to do the release process first, since that will have implications for the Debian and RPM packages: how the version number is determined and what set of files constitute the package will change as we improve the release process.

Comment by Roberto Sanchez [ 09/Sep/18 ]

jesse, I have performed a more thorough analysis and I propose not using CPack for this. The .deb module for CPack provides considerably less flexibility than we require. The principal value that I see in the CPackDeb module is for use in internal-only deployments where we might not want to hassle with all the requirements of a "proper" Debian package. Since we intend to provide the packages of the C++ driver for public consumption and especially because we intend to upload them to Debian proper (and have them eventually end up in Ubuntu), the best course is to apply the pattern we have in the C driver.

The structure of the two is sufficiently similar that I would use the C driver packaging as a starting point and adapt it to the C++ driver. The main effort there is going through everything to ensure all the copyrights and whatnot are properly reflected in debian/copyright and making sure that there are no incompatible (from a policy perspective) components. Once the packaging is done I should be able to drop the build_snapshot.sh script I did for the C driver directly into the C++ driver and then duplicate the debian-package-build Evergreen so that we can produce Debian packages in Evergreen and test that they install everything as expected.

I looked back through my old email and I assessed the effort require for packaging the C++ driver in response to a request from Drew in January 2016. Since then, we have learned quite a bit through the C driver packaging, which makes the C++ driver effort smaller and less complex. The only thing that was not a part of the assessment that I gave Drew was the Evergreen task. However, the heavy lift for that is already complete with the C driver, so it would be a very small effort to do the same for the C++ driver.

Am I correct in understanding that you could want the release process (CXX-584) sorted out before taking on the packaging?

Comment by Roberto Sanchez [ 07/Sep/18 ]

jesse, we investigated CPack for creating the source distribution tarball and it was not sufficient for our needs, which resulted in the implementation of the MakeDist CMake module based on the one in GNUCash. I would not expect CPack to add any value to what we have in the C driver, since the official packaging scripts that we maintain are more robust than what CPack can generate. It might be useful for the C++ driver to bootstrap the initial set of packages, but I would need to look at both the C++ driver code and also the CPack capabilities that exist for the generation of .deb packages. I will report back with an analysis of the situation.

Comment by A. Jesse Jiryu Davis [ 07/Sep/18 ]

Roberto I can't remember, have we investigated CPack already for generating C Driver Debian packages? What was our conclusion about that, and will the same conclusion apply here to the C++ Driver?

Generated at Wed Feb 07 22:01:19 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.