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
b4644080
Commit
b4644080
authored
Aug 11, 2015
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
check original package name in add_32bit_requires
parent
cbffe0ed
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
10 deletions
+33
-10
repl
share/eterbuild/functions/repl
+13
-10
test_repl_find.sh
tests/test_repl_find.sh
+20
-0
No files found.
share/eterbuild/functions/repl
View file @
b4644080
...
...
@@ -16,6 +16,10 @@ add_32bit_requires()
assert_var DISTRNAME BUILDARCH BUILDNAME DISTRVERSION
[
-z
"
$1
"
]
&&
return
[
-z
"
$2
"
]
&&
return
local
GREP
=
"
$1
"
shift
# Only for build wine on x86_64
if
[
"
$BUILDARCH
"
=
"x86_64"
]
&&
rhas
"
$BUILDNAME
"
wine
;
then
...
...
@@ -23,27 +27,25 @@ add_32bit_requires()
# http://www.rpm.org/wiki/PackagerDocs/ArchDependencies
# add (x86-32) to all -devel packages
for
i
in
$*
;
do
rhas
$
i
"-devel$"
&&
echo
"
$i
$i
(x86-32)"
&&
continue
rhas
$
GREP
"-devel$"
&&
echo
"
$i
$i
(x86-32)"
&&
continue
echo
"
$i
"
done
| xargs
-n
1000
echo
elif
[
"
$DISTRNAME
"
=
"Ubuntu"
]
&&
version_more_version
$DISTRVERSION
12.04
||
[
"
$DISTRNAME
"
=
"Debian"
]
&&
version_more_version
$DISTRVERSION
7.0
;
then
# i386 on Debian/Ubuntu: # add :i386 to all -dev packages
for
i
in
$*
;
do
rhas
$
i
"-dev
$"
&&
echo
"
$i
$i
:i386"
&&
continue
rhas
$
GREP
"-devel
$"
&&
echo
"
$i
$i
:i386"
&&
continue
echo
"
$i
"
done
| xargs
-n
1000
echo
elif
[
"
$DISTRNAME
"
=
"ArchLinux"
]
;
then
# i386 on ArchLinux: add lib32- to all lib packages
for
i
in
$*
;
do
rhas
$
i
"^lib"
&&
echo
"lib32-
$i
"
&&
continue
rhas
$
GREP
"^lib"
&&
echo
"lib32-
$i
"
&&
continue
echo
"
$i
"
done
| xargs
-n
1000
echo
elif
[
"
$DISTRNAME
"
=
"SUSE"
]
;
then
# i386 on SUSE: # add -32bit to all lib packages
elif
[
"
$DISTRNAME
"
=
"SUSE"
]
||
[
"
$DISTRNAME
"
=
"SLED"
]
||
[
"
$DISTRNAME
"
=
"SLES"
]
;
then
# i386 on SUSE
or SLED
: # add -32bit to all lib packages
for
i
in
$*
;
do
rhas
$i
"^liberation"
&&
echo
"
$i
"
&&
continue
#rhas $i "-devel$" && echo "$i" && continue
rhas
$i
"^lib"
&&
echo
"
$i
-32bit"
&&
continue
rhas
$GREP
"^lib"
&&
echo
"
$i
-32bit"
&&
continue
echo
"
$i
"
done
| xargs
-n
1000
echo
else
...
...
@@ -62,6 +64,7 @@ tolocal_anyrepl()
{
assert_var PKGFORMAT DISTRNAME BUILDNAME
local
i REPLRULE WARULES
local
NEWRESULT
local
GREP
=
$1
shift
# TODO: fix space removing
...
...
@@ -77,7 +80,7 @@ tolocal_anyrepl()
#REPLRULE=`echo $REPLRULE | sed -r -e 's,|,!,g'`
ALTPKGNAME
=
`
echo
$REPLRULE
|
cut
-d
"|"
-f1
|
sed
-e
"s|
\+
|
\\\\\+
|g"
`
TARGETPKGNAME
=
`
echo
$REPLRULE
|
cut
-d
"|"
-f2
|
sed
-e
"s|
\+
|
\\\\\+
|g"
`
test
-n
"
$REPLRULE
"
&&
TARGETPKGNAME
=
$(
add_32bit_requires
"
$TARGETPKGNAME
"
)
&&
return
0
test
-n
"
$REPLRULE
"
&&
TARGETPKGNAME
=
$(
add_32bit_requires
"
$
GREP
"
"
$
TARGETPKGNAME
"
)
&&
return
0
done
# Part of local hack
...
...
@@ -104,7 +107,7 @@ tolocal_anyrepl()
local
NEWRESULT
=
`
echo
$GREP
|
sed
-e
"s|^ *
\(
.*
\)
-devel *
\$
|
\1
|g"
`
fi
FIXNEWRESULT
=
$(
add_32bit_requires
$NEWRESULT
)
FIXNEWRESULT
=
$(
add_32bit_requires
"
$GREP
"
$NEWRESULT
)
ALTPKGNAME
=
"
$GREP
"
TARGETPKGNAME
=
"
$FIXNEWRESULT
"
...
...
tests/test_repl_find.sh
View file @
b4644080
...
...
@@ -137,3 +137,23 @@ print_pkgrepl_list
check_repl libgphoto2-devel
"libgphoto2-devel"
check_repl libgphoto2-6
"libgphoto2-6-32bit"
############################# SUSE ##########################
BUILDNAME
=
wine
DISTRNAME
=
SLED
PKGVENDOR
=
sled
DISTRVERSION
=
11
BUILDARCH
=
x86_64
PKGFORMAT
=
rpm
echo
echo
"Replacement files for
$PKGVENDOR
/
$DISTRVERSION
(target
$PKGFORMAT
):"
print_pkgrepl_list
check_repl libXi-devel
"xorg-x11-devel-32bit"
check_repl libX11-devel
"xorg-x11-libX11-devel-32bit"
check_repl libfreetype-devel
"freetype2-devel-32bit"
check_repl zlib-devel
"zlib-devel-32bit"
check_repl libXpm-devel
"xorg-x11-libXpm-devel-32bit"
check_repl fontconfig-devel
"fontconfig-devel-32bit"
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