From a2d1a99f06b7baa3c93f4adbd7f6b166a2209e30 Mon Sep 17 00:00:00 2001 From: Dimitris Zlatanidis Date: Thu, 20 Oct 2016 00:29:33 +0300 Subject: [PATCH] Added rlworkman.deps dependencies configuration file Signed-off-by: Dimitris Zlatanidis --- REPOSITORIES | 2 +- man/slpkg.8 | 3 +++ setup.py | 3 ++- slackbuild/doinst.sh | 2 +- slackbuild/slpkg.SlackBuild | 2 +- slpkg/binary/greps.py | 14 ++++++-------- 6 files changed, 14 insertions(+), 12 deletions(-) diff --git a/REPOSITORIES b/REPOSITORIES index 0adb52d5..d312b292 100644 --- a/REPOSITORIES +++ b/REPOSITORIES @@ -12,7 +12,7 @@ should work on it as well. Rworkman's (rlw) repository use dependencies where displayed in central site 'http://rlworkman.net/pkgs/' and only those. Unfortunately there is no fixed reference -dependencies file PACKAGES.TXT. +dependencies file PACKAGES.TXT. You can make changes in /etc/slpkg/rlworkman.deps file. Slackers.it (slackr) repository must be used only from Slackware64 current users and has no reference dependencies. diff --git a/man/slpkg.8 b/man/slpkg.8 index 0467bd9a..289e473e 100644 --- a/man/slpkg.8 +++ b/man/slpkg.8 @@ -403,6 +403,9 @@ For example: /etc/slpkg/custom-repositories List of custom repositories +/etc/slpkg/rlworkman.deps + Rworkman's repository dependencies + /var/log/slpkg ChangeLog.txt repositories files SlackBuilds logs and dependencies files diff --git a/setup.py b/setup.py index b592327f..b084c081 100755 --- a/setup.py +++ b/setup.py @@ -125,7 +125,8 @@ if "install" in sys.argv: "conf/blacklist", "conf/slackware-mirrors", "conf/default-repositories", - "conf/custom-repositories" + "conf/custom-repositories", + "conf/rlworkman.deps" ] if not os.path.exists(_meta_.conf_path): os.makedirs(_meta_.conf_path) diff --git a/slackbuild/doinst.sh b/slackbuild/doinst.sh index e66ed20b..da18b228 100644 --- a/slackbuild/doinst.sh +++ b/slackbuild/doinst.sh @@ -9,7 +9,7 @@ config() { } CONFIGS="slpkg.conf repositories.conf blacklist slackware-mirrors default-repositories \ - custom-repositories" + custom-repositories rlworkman.deps" for file in $CONFIGS; do config etc/slpkg/${file}.new done diff --git a/slackbuild/slpkg.SlackBuild b/slackbuild/slpkg.SlackBuild index 4773c291..ba26f66a 100755 --- a/slackbuild/slpkg.SlackBuild +++ b/slackbuild/slpkg.SlackBuild @@ -88,7 +88,7 @@ find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | gr mkdir -p $PKG/etc/slpkg # install configurations files CONFIGS="slpkg.conf repositories.conf blacklist slackware-mirrors default-repositories \ - custom-repositories" + custom-repositories rlworkman.deps" for file in $CONFIGS; do install -D -m0644 conf/$file $PKG/etc/slpkg/${file}.new done diff --git a/slpkg/binary/greps.py b/slpkg/binary/greps.py index bff1cac0..f86f46ae 100644 --- a/slpkg/binary/greps.py +++ b/slpkg/binary/greps.py @@ -154,14 +154,12 @@ class Requires(object): """Grap package requirements from repositories """ if self.repo == "rlw": - # Robby"s repository dependencies as shown in the central page - # http://rlworkman.net/pkgs/ - dependencies = { - "abiword": "wv", - "claws-mail": "libetpan", - "inkscape": "lxml numpy BeautifulSoup", - "xfburn": "libburn libisofs" - } + dependencies = {} + rlw_deps = Utils().read_file(_meta_.conf_path + "rlworkman.deps") + for line in rlw_deps.splitlines(): + if line and not line.startswith("#"): + pkgs = line.split(":") + dependencies[pkgs[0]] = pkgs[1] if self.name in dependencies.keys(): return dependencies[self.name].split() else: