From Fedora Project Wiki

(Don't tell folks to edit the CVSAdminProcedure document.)
(No useful content here, erasing everything since I cannot just delete the page)
Tag: Blanking
 
(4 intermediate revisions by 4 users not shown)
Line 1: Line 1:
== Fedora Package Collection CVS FAQ ==


This FAQ is still work in progress.
=== How do I update an existing package in CVS? (recommended way) ===
See [[PackageMaintainers/UpdatingPackageHowTo| UpdatingPackageHowTo]] .
=== Import of complete src.rpm packages ===
As an alternative to the recomended way [[PackageMaintainers/UpdatingPackageHowTo| UpdatingPackageHowTo]] , you can also import complete src.rpm packages to update an existing package, using a similar procedure than the initial package import.
The '''common''' directory in CVS, which is replicated in every module directory, contains a '''cvs-import.sh''' script. This script can commit entire src.rpm contents in one step. It uploads new tarballs into lookaside cache, updates a working copy of the last version found in CVS, and commits all changes. In case you prepare your update packages in an ordinary rpmbuild tree, you can use the script to import a finished update src.rpm in one step. Examples:
<pre>
./common/cvs-import.sh ~/rpm/SRPMS/foo-1.0-2.src.rpm
./common/cvs-import.sh -b FC-3 -m "import Joe's update" ~/bar-2.1-1.src.rpm
</pre>
See "cvs-import.sh --help" for the options it understands. It can also update modules in branch directories other than the default "devel".
Be careful, since cvs-import.sh can also create non-existing cvs modules in "devel" branch on-the-fly. According to current policies, the creation of new modules needs approval.
Also be aware that if you cvs-import.sh a single src.rpm to multiple branches, you run into problems with cvs tags which cannot be the same for different branches. You will need to avoid tag collision yourself and e.g. add the %{dist} macro to your spec file after import and then run "make tag" manually for every branch you imported to.
'''Example for this method'''
{{admon/tip|Blind spots|Warning! This way may look much easier, but it not recommended because you can't check the changes that you have made against the version in cvs before you commit them. People have accidentally overwritten other packages with this method. Please make yourself familar with above description please.}}
<pre>
export CVSROOT=:ext:USERNAME@cvs.fedoraproject.org:/cvs/pkgs
export CVS_RSH=ssh
cvs co foo
cd foo/devel
# you should checkout a new srpm in case someone else modified something in the cvs after your last update
make srpm
# <install the resulting srpm with the usual commands and modify it>
# commit your changes:
cd foo/common
./cvs-import.sh -b <branch_name> -m "foo updated to 0.0.2" ~/rpmbuild/SRPM/<package_name>-<version>-<release>.src.rpm
cd ../<branch_name>
cvs up
make build
</pre>
=== How to add new packages? ===
Please refer to the [[PackageMaintainers/NewPackageProcess| NewPackageProcess]]  and the 'Import of complete src.rpm packages' section above.
=== How to have new branches added? ===
Refer to [[CVS_admin_requests#Package_Change_Requests_for_existing_packages| CVS Admin Requests]].
=== How do I remove a branch I no longer want or need? ===
Simply use the <code>cvs remove</code> command.  Do not list this on the [[PackageMaintainers/CVSAdminProcedure| CVSAdminProcedure]]  page; that page is only for CVS administrative actions.
=== How do I make changes to an older branch? ===
Here is the scenario: you've build your package successfully on the FC-5 branch, but there is a problem keeping your package from building on FC-4.
Solution: make your changes in the branch and then add a digit to the very right of the release tag. There is no need to change the release in the other branches. This allows upgrades to work smoothly if the user upgrades to a newer release of Fedora.
<pre>
Name:    foo
Version: 1.0
Release: 1%{?dist}
Name:    foo
Version: 1.0
Release: 1%{?dist}.1
</pre>
Then tag and build as usual.
See
https://www.redhat.com/archives/fedora-extras-list/2006-May/msg00083.html
=== How to request builds? ===
For fedora, detailed information about the build system is at [[PackageMaintainers/UsingKoji| UsingKoji]] . For EPEL, you can refer to [[PackageMaintainers/BuildRequests| BuildRequests]] .
=== I have an account but I am unable to connect to CVS via ssh ===
Please write to accounts at fedora.redhat.com and include all details.  There has not been any IP address ACL anymore for months now, so your problem is likely a client configuration issue, private/public key mismatch, or some network problem.
=== I ran <code>make tag</code> without checking in my files, how do I revert so I can check them in? ===
As long as you have not built the package you have the option to run:
<pre>
TAG_OPTS=-F make tag
</pre>
* Note:  this is a dangerous command if misused only do it if you really know what your doing and you have checked everything at least twice.
If your not sure ask in #fedora-devel or #fedora-admin or simply increase the '''Release''' version in your spec file, commit the changes, and run <code>make tag</code> normally.
=== How do I update/import a new branch directory? ===
If a new branch is created on the server side, <code>cvs update</code> will not pull the new directory. Instead, you have to use <code>cvs update -d</code>.
== Hints ==
* For a list of Makefile targets, see [[PackageMaintainers/Makefile| Makefile]]  or run
<pre>
make help
</pre>
* Set the '''WORKDIR''' environment variable to point to a directory, in which the various "make" commands will run rpmbuild and store built rpms. Then make extensive use of e.g. "make i386" and "make srpm" to test your package prior to a CVS commit.
----
* After cvs commit of a new package version or release, run '''make tag''' in your working copy to add a symbolic tag to this particular version of your package. With these cvs tags you can check out a specific version of your package easily any time. For instance:
<pre>
cvs co -r fedora-rpmdevtools-1_0-2 fedora-rpmdevtools
</pre>
The automated build system for Fedora Package Collection requires such tags in order to be able to fulfill build requests.
----
* Use '''make clog''' to extract the last spec changelog entry and store it in a local "clog" file. Include this file as the cvs commit log message.  This can be done with the following commands:
<pre>
make clog
cvs commit -F clog
</pre>
=== Expired Certificates (Error 255 or OpenSSL.SSL.Error) ===
If you get this error:
<pre>
ERROR: could not check remote file status
make: *** [upload]  Error 255
</pre>
this usually means that your client certificate (~/.fedora.cert) has expired, so you need to head over to [https://admin.fedoraproject.org/accounts/ the account system]  and retrieve a new one.
You may need to rerun <code>fedora-packager-setup</code>
from the <code>fedora-packager</code> package, especially if you get the error:
<pre>
<class 'OpenSSL.SSL.Error'>: [('SSL routines', 'SSL3_READ_BYTES', 'sslv3
]alert certificate expired'), ('SSL routines', 'SSL3_WRITE_BYTES', 'ssl
handshake failure')
</pre>
Remove your ~/.fedora-server*ca.cert and rerun <code>fedora-packager-setup</code> if you get the error:
<pre>
Error: [('SSL routines', 'SSL3_GET_SERVER_CERTIFICATE', 'certificate
verify failed')]
</pre>
[[Category:Package Maintainers]][[Category:FAQ]]

Latest revision as of 20:14, 2 October 2021