Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
package-helpers
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
trisquel
package-helpers
Commits
32a9a4d6
Commit
32a9a4d6
authored
9 years ago
by
Santiago Rodriguez
Browse files
Options
Downloads
Patches
Plain Diff
compiz: change string manipulations and use sed
parent
deafb13d
No related branches found
No related tags found
1 merge request
!99
Remove recomendation to use non-free software
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
helpers/make-compiz
+2
-48
2 additions, 48 deletions
helpers/make-compiz
with
2 additions
and
48 deletions
helpers/make-compiz
+
2
−
48
View file @
32a9a4d6
...
...
@@ -25,30 +25,8 @@ VERSION=1
# Need to remove an 'option' in the XML file.
# It extends for five lines, so we will comment
# them out.
xmlFileName
=
plugins/workarounds/workarounds.xml.in
xmlStringToLookFor
=
fglrx_xgl_fix
xmlSkipLines
=
4
cat
$xmlFileName
|
while
read
line
;
do
if
(
echo
$line
|grep
$xmlStringToLookFor
>
/dev/null
)
;
then
echo
"<!-- Removing recommendation to use non-free software"
echo
"
$line
"
count
=
0
while
[
"
$count
"
-lt
"
$xmlSkipLines
"
]
;
do
count
=
`
expr
$count
+ 1
`
;
read
line
echo
"
$line
"
done
echo
"-->"
else
echo
"
$line
"
fi
done
>
$xmlFileName
.tmp
mv
$xmlFileName
.tmp
$xmlFileName
sed
-i
'/fglrx_xgl_fix"/,/option/d'
plugins/workarounds/workarounds.xml.in
# The C++ code calls methods that appear to be based
# on the part of the XML file that we removed.
...
...
@@ -60,32 +38,8 @@ mv $xmlFileName.tmp $xmlFileName
# It's defined at the end of the "*.cpp" file.
# There is another call to a related method.
# I just comment out that call.
cppFileName
=
plugins/workarounds/src/workarounds.cpp
cppStringToLookFor
=
optionSetFglrxXglFixNotify
cppSkipLines
=
2
cat
$cppFileName
|
while
read
line
;
do
if
(
echo
$line
|grep
$cppStringToLookFor
>
/dev/null
)
;
then
echo
"/**************** Removing recommendation to use non-free software"
echo
"
$line
"
count
=
0
while
[
"
$count
"
-lt
"
$cppSkipLines
"
]
;
do
count
=
`
expr
$count
+ 1
`
;
read
line
echo
"
$line
"
done
echo
"****************/"
else
echo
"
$line
"
fi
done
>
$cppFileName
.tmp
mv
$cppFileName
.tmp
$cppFileName
sed
-i
'/optionSetFglrxXglFixNotify/,/_1/ s:^://:'
plugins/workarounds/src/workarounds.cpp
# Create declaration of method in the *.h file
echo
"extern bool optionGetFglrxXglFix();"
>>
plugins/workarounds/src/workarounds.h
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment