Please note: This project is no longer active. The website is kept online for historic purposes only.
If you´re looking for a Linux driver for your Atheros WLAN device, you should continue here .

Ticket #434 (assigned enhancement)

Opened 13 years ago

Last modified 13 years ago

Add top-level "rpm" target to build rpms

Reported by: rich@phekda.gotadsl.co.uk Assigned to: mrenzmann (accepted)
Priority: minor Milestone: version 1.0.0 - first stable release
Component: madwifi: makefiles Version:
Keywords: Cc:
Patch is attached: 1 Pending:

Description

From a mail I sent to madwifi-devel:

"Attached is a patch for svn revision 1453 (i.e.: current) that adds an "rpm" target. To build rpms, just do:

make rpm

I also modified the .spec file to include the user name in the BuildRoot? -- this is standard practice in Fedora spec files.

I'd like this to be committed to svn. Let me know what work it needs for that to happen."

Attachments

madwifi-ng-rpmbuild-20060219.diff (2.4 kB) - added by rich@phekda.gotadsl.co.uk on 02/26/06 13:56:24.
First iteration
madwifi-ng-rpmbuild-20060304.diff (4.4 kB) - added by rich@phekda.gotadsl.co.uk on 03/04/06 20:05:30.
Updated "make rpm" patch, with support for branches
madwifi-tarball-scripts-20060304.diff (1.9 kB) - added by rich@phekda.gotadsl.co.uk on 03/04/06 20:06:35.
Companion patch so tarballs scripts catch up with madwifi-ng-rpmbuild-20060304.diff

Change History

02/26/06 13:56:24 changed by rich@phekda.gotadsl.co.uk

  • attachment madwifi-ng-rpmbuild-20060219.diff added.

First iteration

02/26/06 13:58:14 changed by rich@phekda.gotadsl.co.uk

Feedback from Axel Thimm:

"On Sun, Feb 19, 2006 at 10:00:45PM +0000, Richard Dawe wrote:

I also modified the .spec file to include the user name in the BuildRoot?

This isn't a good idea. Someone misinterpreted the "root" at the end of the %{buildroot} as meaning *user* root instead of buildroot. Next thing some people replaced the -root suffix with calls to id, and the last generation not knowing what the original thought was considered doing both is the safest, so now there are sometimes even -root-id -n suffixes.

It would only make sense to start adding user ids to the buildroot if one would think of concurrent builds of exactly the same package on one box by different users, which is unlikely. And if one would want to target multiple concurrent builds on one system, you wouldn't want to restrict that on multiple users, but multiple processes anyway, so you would better use the pid or mktemp to disambiguate concurrent builds of the same package."

02/26/06 13:59:58 changed by rich@phekda.gotadsl.co.uk

Feedback from Michael Renzmann:

"On Sun, 2006-02-19 at 22:00 +0000, Richard Dawe wrote:

I'd like this to be committed to svn. Let me know what work it needs for that to happen.

From a technical pov I'd ask you to resubmit your patch by opening a new ticket and attaching your patch to it. In addition, your patch will need to be signed off by you before it can be committed to the repository.

Apart from what Axel Thimm already mentioned about adding the user name into the rpm: replacing @@DDAY@@ with $(SNAPSHOT) is not correct. From the script that generates the tarballs:

            cat $TARBALL_NAME/$SPECFILE_IN | \
                sed -e "s/@@SVNREL@@/$newrev/" \
                -e "s/@@DDAY@@/$(date +%Y%m%d)/" \
                -e "s/@@BRANCH@@/trunk/" > $TARBALL_NAME/$SPECFILE_OUT

In addition we should find a way to properly set @@BRANCH@@ (easy for now, since the rpm stuff is included only in trunk - but that will change sooner or later)."

02/26/06 23:19:30 changed by rich@phekda.gotadsl.co.uk

@ Michael Renzmann:

Where can I find the script to build tarballs? I couldn't find it in svn or the CVS imports in svn. I need to look at that, before updating my patch.

How should the branch appear in the rpm name/version? I don't think including the branch + svn version is going to work -- how do you upgrade from branch foo svn version 1234 to branch bar svn version 1311? Which is newer? Is the branch just for informational purposes in the version?

02/28/06 06:32:13 changed by mrenzmann

Sent you the tarball generation script by e-mail. It's not publically available (yet).

how do you upgrade from branch foo svn version 1234 to branch bar svn version 1311? Which is newer? Is the branch just for informational purposes in the version?

The revision is valid for the whole repository, and the higher the revision number the more current is a snapshot. The information about the branch is important to distinct madwifi-old (which is kept in branches/madwifi-old in the repository) from madwifi-ng (which is kept in trunk).

03/01/06 18:11:38 changed by pichon

Sorry for being late on that issue, My recommendation would be to keep the rpm build out of the Makefile, since only rpmbuild --ta <tarfile> would be enought to build the Fedora package.

However, it would be good to integrate the rpm build inside the Makefile for Release build.

03/01/06 20:47:29 changed by rich@phekda.gotadsl.co.uk

@ pichon:

That's fine if you're using a tarball, but this is aimed at people using the svn check-out, where a "make rpm" target would be helpful.

03/04/06 20:05:30 changed by rich@phekda.gotadsl.co.uk

  • attachment madwifi-ng-rpmbuild-20060304.diff added.

Updated "make rpm" patch, with support for branches

03/04/06 20:06:35 changed by rich@phekda.gotadsl.co.uk

  • attachment madwifi-tarball-scripts-20060304.diff added.

Companion patch so tarballs scripts catch up with madwifi-ng-rpmbuild-20060304.diff

03/04/06 20:08:33 changed by rich@phekda.gotadsl.co.uk

I've attached updated patches (dated 20060304). There is one patch for the Makefile and spec file and a companion patch to update the tarball snapshot scripts for madwifi.org (thanks for sending me those scripts, by the way).

One problem I can see with these patches is that they assume there is a branch name. I imagine at some point "trunk" will want to be called just "madwifi" rather than "madwifi-ng". Is this something that needs fixing as part of this ticket or later?

03/06/06 21:59:55 changed by mrenzmann

  • status changed from new to assigned.
  • owner set to mrenzmann.
  • patch_attached set to 1.
  • milestone set to version 1.0.0 - first stable release.

As a reminder: patches need to be signed off before they can be committed.

03/06/06 22:21:41 changed by rich@phekda.gotadsl.co.uk

@ mrenzmann

Thanks for the reminder about signing my patches. I actually included the sign-off in the .diff files dated 20060304 attached to this ticket.

I can include the sign-off in the ticket text, if that's preferred.

03/07/06 06:38:44 changed by mrenzmann

Richard, sorry, that was my bad. The sign-off in the diff is fine, I just didn't noticed it (shouldn't walk through the tickets late in the evening, I guess).