/docs/MyDocs

To get this branch, use:
bzr branch http://darksoft.org/webbzr/docs/MyDocs

« back to all changes in this revision

Viewing changes to SCM/packaging/rpm/rpm.scrypt

  • Committer: Suren A. Chilingaryan
  • Date: 2017-04-03 02:45:17 UTC
  • Revision ID: csa@suren.me-20170403024517-dwzj0z0k1cmhxm7u
Restructuring, OpenShift, Ansible, Git

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
%description    - Package Description
 
2
%prep           - Preparing Stage (Directory $RPM_BUILD_DIR/XFree86-4.0.1)
 
3
    %setup      -   Deletes Top Level Build Directory, Unpacks Source Files
 
4
            -n <path>   - Specify alternate build directory (from $RPM_BUILD_DIR)
 
5
            -c          - Create directory and change to it before unpacking
 
6
            -D          - Don't delete Directory Before Unpacking
 
7
            -T          - Don't unpack files
 
8
            -b <num>    - Unpack source <num> before changing directory 
 
9
                        also if -T specified ( if -T not specified source <num>
 
10
                        will be unpacked twice )
 
11
            -a <num>    - Unpack source <num> after changing directory
 
12
    %patch      - Applies patches if neccesary
 
13
            -P <num>    - Applies only patch <num>
 
14
            -p <num>    - Removes <num> leading sleshes & directories from
 
15
                        patch file names ( i mean from patch file ), 
 
16
                        works as ( patch -p<num> )
 
17
            -b <ext>    - Set backup files extension to <ext>, by defaul ".orig"
 
18
            -E          - Remove empty output files
 
19
%build          - Building Stage
 
20
    make CFLAGS="$RPM_OPT_FLAGS"
 
21
%install        - Installing Stage
 
22
    make install
 
23
%clean          - Cleaning temporary files
 
24
    rm -rf $RPM_BUILD_ROOT
 
25
%verifyscript   - Executes then RPM verification program executed ( addon for
 
26
                files verification )
 
27
%files          - List of all file to be packaged, with path from RPM_BUILD_ROOT
 
28
                If specified path of directory then all files of directory
 
29
                assumed.
 
30
                <subpackage>    Files for specified SubPackage
 
31
                <-n subpackage> Files for specified FullName SubPackage
 
32
                -f <file>       - Read FileList from File
 
33
                %dir <dir>      Package only directory specified, not all files
 
34
                                from it
 
35
                %doc <file>     - Specifies what file is Documentation file 
 
36
                                if no path specified assumed what it placed in
 
37
                                RPM Source Directory and will be installed into
 
38
                                /usr/doc directory
 
39
                %docdir <dir>   All files of directory will be treated as
 
40
                                documentation ( By default /usr/doc, /usr/info,
 
41
                                /usr/man - Doc Dirs )           
 
42
                %config <file>  - Specifies what files is Configuration File
 
43
                                Only one file can follow %config derictive
 
44
                %attr(mode,user,group) <file>   - Specifies file attributes
 
45
                                "-" - use standart one ( I mean mode, user or
 
46
                                group ) 
 
47
                %verify ( arg1 ... argn ) <file - Specify which must be verified
 
48
                                during rpm verification. Args may been:
 
49
                                owner, group, mode, size, mtime, symlink,
 
50
                                md5 - MD5 Checksum, pgp - For signed packages
 
51
                                maj - Major Number,  mai - Minor Numnber
 
52
%package <name>                 If must been builded several rpm files 
 
53
                                (XFree86, XFree86-devel, ...)  then %package
 
54
                                specifies instruction of subpackage building
 
55
                                Name must contain subpackage name addon
 
56
                                (in this case name must been "devel")
 
57
%post <name>                    End of subpackage section
 
58
%package -n <name>              Specify Full Name of subpackage
 
59
%post -n <name>                 In this case post also must contain "-n" option
 
60
%ifarch,%ifnarch,%ifos,%ifnos,%else,%endif      - I think clear
 
61
%pre            - Pre Install Script
 
62
%post           - Post Install Script
 
63
%preun          - Pre Uninstall Script
 
64
%postun         - Post Uninstall Script
 
65
                <subpackage>    Scripts for specified SubPackage
 
66
                <-n subpackage> Scripts for specified FullName SubPackage