forked from scientificlinux/python-rpmpatch
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsampleconfig.ini
More file actions
207 lines (161 loc) · 6.04 KB
/
sampleconfig.ini
File metadata and controls
207 lines (161 loc) · 6.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
Things are run in groups organized by their section names.
Each section is run alphabeticaly, but the sections are run in this order:
spec-> re -> patch -> source
This way your specfile adjustments and regex matches don't need to contend
with your other modifications
-------------------------------------------------
Example Config:
-------------------------------------------------
[program]
# you can control behavior here
# you can override this on the command line
changelog_user = me <[email protected]>
# if you set this to 'True' the ini file used
# to configure this program will be added to the
# source rpm
package_config = True
# if you set this to 'True' any patches or sources
# that were not applied due to version restrictions
# will be placed in a tar archive called
# %{name}-extras-python-rpmpatch.tar.bz2
package_unused = True
# if set to 'True' then rpmbuild -bb will be called
# automatically rather than just rpmbuild -bs
compile = False
# which arches should this rpm be built for
# if this is defined, when a compile is requested
# the items here will be passed to rpmbuild as
# --target=<>
build_targets = [ 'i386', 'i686' ]
[autodist]
# This program can attempt to determine the
# dist tag of the package and set it automatically
#
# NOTE: if you've defined 'dist' in the [define]
# section, this will not work.
# Everything defined in [define] will be used
# to determine the dist tag.
enable_autodist = False
# Since you are changing the rpm, you really
# should change the dist tag, but with autodist
# the value is inherited from the source rpm
# so we provide a regex to wrapper to adjust
autodist_re_match = el
autodist_re_replace = sl
# anything you want set for rpmbuild, mark here
[define]
scl = python27
macro = value
# ----------------------------------------------------
# The patch sections are either for adding or removing.
# They are processed in numeric order
[patch1]
# example for adding a patch
method = add
# DO NOT PUT THESE IN rpmbuild/SOURCES they will be copied in there for you
patch = /path/to/patch
# the arg to -p, ie 1 for -p1
stripe = 1
# you can leave the 'num' line off or set it if you want
num = 200
# on package version, this should be a list of versions
# for which this is performed. The sort of thing you
# get from the %{version} macro
# If undefined, we assume you want everyone to get this
on_version = [ '1.2' ]
# you must have a changelog entry
changelog = I'm adding this patch to resolve issue and fix bug
# ----------------------------------------------------
[patch2]
# example for removing a patch
method = del
# you must either specify patch name or patch num
# your choice
patch = mypatch.patch
num = 12
# on package version, this should be a list of versions
# for which this is performed. The sort of thing you
# get from the %{version} macro
# If undefined, we assume you want everyone to get this
on_version = [ '1.2' ]
# you must have a changelog entry
changelog = I'm removing this patch because it causes problem
# ----------------------------------------------------
# The 'source' sections are for adding sources right now
# Removing sources requires more complex work (like a patch)
# You probably still need a patch to do something with your newly added source
# They are processed in numeric order
[source1]
# example for adding a source
method = add
# DO NOT PUT THESE IN rpmbuild/SOURCES they will be copied in there for you
source = /path/to/source/file
# you can leave the 'num' line off or set it if you want
num = 200
# on package version, this should be a list of versions
# for which this is performed. The sort of thing you
# get from the %{version} macro
# If undefined, we assume you want everyone to get this
on_version = [ '1.2' ]
# you must have a changelog entry
changelog = An extra thingy
# ----------------------------------------------------
[source2]
# example for removing a source
method = del
# The file will remain in rpmbuild/SOURCES
source = filename
# you can leave the 'num' line off or set it if you want
num = 200
# on package version, this should be a list of versions
# for which this is performed. The sort of thing you
# get from the %{version} macro
# If undefined, we assume you want everyone to get this
on_version = [ '1.2' ]
# you must have a changelog entry
changelog = No filename in our world
# ----------------------------------------------------
[source3]
# example for replacing a source
method = replace
# The file in rpmbuild/SOURCES will be replaced
specsourcename = filename
source = my_awesome_replacement_file
# on package version, this should be a list of versions
# for which this is performed. The sort of thing you
# get from the %{version} macro
# If undefined, we assume you want everyone to get this
on_version = [ '1.2' ]
# you must have a changelog entry
changelog = This file should be our version
# ----------------------------------------------------
# The 'spec' sections are for applying patches to the specfile itself
# when you've added a new source or want to remove a source file
# this is how you can do it.
# They are processed in numeric order
[spec1]
# The patch will be added as a 'Source' so you can review it later
diff = /path/to/patch
# on package version, this should be a list of versions
# for which this is performed. The sort of thing you
# get from the %{version} macro
# If undefined, we assume you want everyone to get this
on_version = [ '1.2' ]
# you must have a changelog entry
changelog = I'm making some important changes such as
# ----------------------------------------------------
# the 're' sections are for running any random regex you want
# against the specfile. It isn't as focused as a patch, but that
# can be a benefit
# They are processed in numeric order
[re1]
# set your expression up here
match = .
replace = L
# on package version, this should be a list of versions
# for which this is performed. The sort of thing you
# get from the %{version} macro
# If undefined, we assume you want everyone to get this
on_version = [ '1.2' ]
# you must have a changelog entry
changelog = I changed everything to L for some reason