Annotated edit history of
RPMNotes version 4, including all changes.
View license author blame.
Rev |
Author |
# |
Line |
4 |
AristotlePagaltzis |
1 |
!!!Allow normal users to compile source [RPM]s without root permissions |
3 |
AristotlePagaltzis |
2 |
|
|
|
3 |
Simply copy this into __~/.rpmmacros__ |
|
|
4 |
|
4 |
AristotlePagaltzis |
5 |
%packager Your <email> |
3 |
AristotlePagaltzis |
6 |
%distribution Personal custom flag |
|
|
7 |
%vendor You |
|
|
8 |
%_signature gpg |
|
|
9 |
%_gpg_path ~/.gnupg |
|
|
10 |
%_gpg_name your gpg name |
|
|
11 |
%_gpgbin /usr/bin/gpg |
|
|
12 |
|
|
|
13 |
%_topdir /home/user/redhat |
|
|
14 |
%_tmppath /var/tmp/rpm |
|
|
15 |
|
|
|
16 |
%_rpmtopdir %{_topdir} |
|
|
17 |
%_builddir %{_topdir}/BUILD |
|
|
18 |
%_rpmdir %{_rpmtopdir}/RPMS |
|
|
19 |
%_sourcedir %{_rpmtopdir}/SOURCES |
|
|
20 |
%_specdir %{_rpmtopdir}/SPECS |
|
|
21 |
%_srcrpmdir %{_rpmtopdir}/SRPMS |
|
|
22 |
|
|
|
23 |
If you don't want to sign the packages you can comment out/delete the lines from %_signature to %_gpgbin. You can also change %_topdir to your liking. |
|
|
24 |
|
|
|
25 |
You will need to recreate the directory tree to compile into: |
|
|
26 |
mkdir BUILD RPMS SOURCES SPECS SRPMS |
|
|
27 |
cd RPMS; mkdir athlon i386 i486 i586 i686 noarch |
|
|
28 |
Now you can run: |
|
|
29 |
rpmbuild --rebuild <package name> |
|
|
30 |
as a normal user and install the package(s) that will be in redhat/RPMS/arch |
|
|
31 |
|
|
|
32 |
---- |
|
|
33 |
|
|
|
34 |
!!!Fixing RPM if it hangs whenever you run it, regardless of action attempted |
|
|
35 |
|
|
|
36 |
RPM databases can get corrupted, or locks can get stuck forever. |
|
|
37 |
|
|
|
38 |
# rm -f /var/lib/rpm/__db* ; rpm --rebuilddb |
|
|
39 |
|
|
|
40 |
Be sure to kill all running instances of RPM before doing this. __rpm --rebuilddb__ may take a while. Afterwards you should be set. |
|
|
41 |
|
|
|
42 |
---- |
|
|
43 |
UserSubmittedNotes |