Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
etersoft-build-utils
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
korinf
etersoft-build-utils
Commits
8e30ecc4
Commit
8e30ecc4
authored
Feb 14, 2013
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rpmcs: do not replace if in and out are identically
parent
8f872b93
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
9 deletions
+14
-9
rpmcs
bin/rpmcs
+14
-9
No files found.
bin/rpmcs
View file @
8e30ecc4
...
...
@@ -43,6 +43,8 @@ toalt_pkgrepl()
if
[
-n
"
$REPLRULE
"
]
;
then
REPLRULE1
=
`
echo
$REPLRULE
|
cut
-d
"|"
-f1
|
sed
-e
"s|
\+
|
\\\\\+
|g"
`
REPLRULE2
=
`
echo
$REPLRULE
|
cut
-d
"|"
-f2
|
sed
-e
"s|
\+
|
\\\\\+
|g"
`
# really if they are identically both, there is no replacement
[
"
$REPLRULE1
"
=
"
$REPLRULE2
"
]
&&
return
1
return
0
else
REPLRULE1
=
...
...
@@ -402,24 +404,27 @@ do
echog
"fix build requires..."
ALLREPLRULES
=
""
for
n
in
`
print_buildreq
$i
`
;
do
toalt_pkgrepl
$n
&&
ALLREPLRULES
=
"
$ALLREPLRULES
s|(.*Req.*)
$REPLRULE1
|
\1
$REPLRULE2
|g"
&&
test
-n
"
$VERBOSE
"
&&
echo
"Replace '
$REPLRULE1
' with '
$REPLRULE2
'"
#echo REPLRULE: $REPLRULE
toalt_pkgrepl
$n
||
continue
ALLREPLRULES
=
"
$ALLREPLRULES
s|(.*Req.*)
$REPLRULE1
|
\1
$REPLRULE2
|g"
[
-n
"
$VERBOSE
"
]
&&
echo
"Replace '
$REPLRULE1
' with '
$REPLRULE2
'"
done
echog
"fix package requires..."
ALLREPLRULES
=
""
for
n
in
`
print_pkgreq
$i
`
;
do
toalt_pkgrepl
$n
&&
ALLREPLRULES
=
"
$ALLREPLRULES
s|(.*Req.*)
$REPLRULE1
|
\1
$REPLRULE2
|g"
&&
test
-n
"
$VERBOSE
"
&&
echo
"Replace '
$REPLRULE1
' with '
$REPLRULE2
'"
#echo REPLRULE: $REPLRULE
toalt_pkgrepl
$n
||
continue
ALLREPLRULES
=
"
$ALLREPLRULES
s|(.*Req.*)
$REPLRULE1
|
\1
$REPLRULE2
|g"
[
-n
"
$VERBOSE
"
]
&&
echo
"Replace '
$REPLRULE1
' with '
$REPLRULE2
'"
done
echog
"fix groups..."
for
n
in
`
print_grpreq
$i
`
;
do
toalt_grprepl
$n
&&
ALLREPLRULES
=
"
$ALLREPLRULES
s|(^Group.*)
$GRPREPLRULE1
|
\1
$GRPREPLRULE2
|g"
&&
test
-n
"
$VERBOSE
"
&&
echo
"Replace '
$GRPREPLRULE1
' with '
$GRPREPLRULE2
'"
#echo REPLRULE: $REPLRULE
toalt_grprepl
$n
||
continue
ALLREPLRULES
=
"
$ALLREPLRULES
s|(^Group.*)
$GRPREPLRULE1
|
\1
$GRPREPLRULE2
|g"
[
-n
"
$VERBOSE
"
]
&&
echo
"Replace '
$GRPREPLRULE1
' with '
$GRPREPLRULE2
'"
done
# Replace package names in source spec
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment