[SERVER-2040] SPEC File %setup Created: 31/Oct/10  Updated: 06/Dec/22  Resolved: 05/May/22

Status: Closed
Project: Core Server
Component/s: Build, Packaging
Affects Version/s: 1.7.2
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Alex Davies Assignee: [DO NOT ASSIGN] Backlog - Server Development Platform Team (SDP) (Inactive)
Resolution: Done Votes: 0
Labels: build-later, build-needs-definition, packaging
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-4693 RPM .spec files should build packages... Closed
Assigned Teams:
Server Development Platform
Participants:

 Description   

I am no expert, but the SPEC file at http://github.com/mongodb/mongo/blob/master/rpm/mongo.spec does not work for me, and i'd thought i'd post the two minor changes that are needed to get it to work (at least for me).

Firstly, file downloaded for the SOURCES should be renamed to mongodb-src-r1.7.2.tar.gz as this is what you download on the website, i.e.

-Source0: %

{name}

-%

{version}.tar.gz
+Source0:mongodb-src-r%{version}

.tar.gz

Then, this file extracts differently too, so this should be updated:

-%setup
+%setup -n mongodb-src-r1.7.2

There is a bug in that the man page of mongosniff is included, but not the binary:
[in %files]
+%{_bindir}/mongosniff

The RPM will then build fine.

Alex



 Comments   
Comment by Andrew Morrow (Inactive) [ 05/May/22 ]

It isn't clear if this is still an issue, but the files being made note of no longer form part of our packaging. I'm closing this as gone away.

Comment by Jonas Courteau [ 16/Jan/12 ]

As of version 2.0.2, the changes required to the spec file to build are:
Change the Source0 line:
Source0: %

{name}db-src-r%{version}.tar.gz

Change the %setup macro:
%setup -n %{name}

db-src-r%

{version}

Fix a typo in the %files section:
%{_mandir}/man1/bsondump.1*

Generated at Thu Feb 08 02:58:47 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.