Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
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
etersoft
eepm
Commits
a9a6c520
Commit
a9a6c520
authored
Sep 15, 2013
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix provides/requires commands for apt-rpm and apm-dpkg
parent
5958b314
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
50 additions
and
13 deletions
+50
-13
epm-provides
bin/epm-provides
+15
-4
epm-requires
bin/epm-requires
+35
-9
No files found.
bin/epm-provides
View file @
a9a6c520
...
...
@@ -44,10 +44,14 @@ esac
# by package name
case
$PMTYPE
in
apt-rpm
)
# FIXME: need fix for a few names case
# TODO: separate this function to two section
if
is_installed
$pkg_names
;
then
CMD
=
"rpm -q --provides"
else
CMD
=
"apt-cache depends"
EXTRA_SHOWDOCMD
=
' | grep "Provides:"'
docmd apt-cache show
$pkg_names
|
grep
"Provides:"
return
fi
;;
urpm-rpm|zypper-rpm|yum-rpm
)
...
...
@@ -64,9 +68,16 @@ case $PMTYPE in
# yum-rpm)
# CMD="yum deplist"
# ;;
# apt-dpkg)
# CMD="apt-cache depends"
# ;;
apt-dpkg
)
# FIXME: need fix for a few names case
if
is_installed
$pkg_names
;
then
CMD
=
"rpm -q --provides"
else
EXTRA_SHOWDOCMD
=
' | grep "Provides:"'
docmd apt-cache show
$pkg_names
|
grep
"Provides:"
return
fi
;;
*
)
fatal
"Have no suitable command for
$PMTYPE
"
;;
...
...
bin/epm-requires
View file @
a9a6c520
#!/bin/sh
#
# Copyright (C) 2012 Etersoft
# Copyright (C) 2012 Vitaly Lipatov <lav@etersoft.ru>
# Copyright (C) 2012
-2013
Etersoft
# Copyright (C) 2012
-2013
Vitaly Lipatov <lav@etersoft.ru>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
...
...
@@ -17,6 +17,9 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
load_helper epm-query
epm_requires
()
{
local
CMD
...
...
@@ -31,11 +34,14 @@ case $PMTYPE in
CMD
=
"rpm -q --requires -p"
;;
apt-dpkg
)
# FIXME: need package base
showcmd dpkg
-s
$pkg_files
a
=
dpkg
-s
$pkg_names
|
grep
"^Depends:"
|
sed
"s|^Depends:||g"
# FIXME: we need execute package name section too
return
if
[
-n
"
$pkg_files
"
]
;
then
# FIXME: need package base
showcmd dpkg
-s
$pkg_files
a
=
dpkg
-s
$pkg_files
|
grep
"^Depends:"
|
sed
"s|^Depends:||g"
# FIXME: we need execute package name section too
# TODO: separate to two section
return
fi
;;
*
)
fatal
"Have no suitable command for
$PMTYPE
"
...
...
@@ -46,7 +52,20 @@ esac
# by package name
case
$PMTYPE
in
apt-rpm|urpm-rpm|zypper-rpm
)
apt-rpm
)
# FIXME: need fix for a few names case
# FIXME: too low level of requires name (libSOME.so)
if
is_installed
$pkg_names
;
then
CMD
=
"rpm -q --requires"
else
#EXTRA_SHOWDOCMD=' | grep "Depends:"'
#docmd apt-cache show $pkg_names | grep "Depends:"
#return
CMD
=
"apt-cache depends"
fi
;;
urpm-rpm|zypper-rpm
)
# FIXME: use hi level commands
CMD
=
"rpm -q --requires"
;;
...
...
@@ -57,7 +76,14 @@ case $PMTYPE in
CMD
=
"pactree"
;;
apt-dpkg
)
CMD
=
"apt-cache depends"
# FIXME: need fix for a few names case
if
is_installed
$pkg_names
;
then
showcmd dpkg
-s
$pkg_names
a
=
dpkg
-s
$pkg_names
|
grep
"^Depends:"
|
sed
"s|^Depends:||g"
return
else
CMD
=
"apt-cache depends"
fi
;;
emerge
)
assure_exists equery
...
...
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