diff options
-rwxr-xr-x | pythonFunktionen | 17 | ||||
-rwxr-xr-x | testeAbhaengigkeiten | 7 |
2 files changed, 18 insertions, 6 deletions
diff --git a/pythonFunktionen b/pythonFunktionen index 9ebe72a1e..e54b2368b 100755 --- a/pythonFunktionen +++ b/pythonFunktionen @@ -18,8 +18,7 @@ versionsUniq() { ladePkgbuild() { paket="$1" - if [[ "${paket}" != "python-"* ]] - then + if [ -n "${paket%%python-*}" ]; then return 1 fi @@ -28,7 +27,12 @@ ladePkgbuild() { makepkg -f --verifysource - . PKGBUILD + . <( + sed ' + /^\s*_pinned_dependencies\S*=(.*)/ d + /^\s*_pinned_dependencies\S*=(/,/)/ d + ' PKGBUILD + ) if grep -qF _pinned_dependencies PKGBUILD; then depends+=('"${_pinned_dependencies[@]}"') fi @@ -59,7 +63,8 @@ versteheRequirements() { "${metaRegexe[@]}" tar -Oxzf "${archiv}" "${_pkgname}-${pkgver}/setup.py" \ | sed -n "$( - printf '/^\\s*%s = \[/,/^\s*$/ p\n' \ + printf '/=/ s/^\\s\\+//\n' + printf '/^%s = \[/,/^\s*$/ p\n' \ "${metaRegexe[@]}" )" \ | sed ' @@ -90,6 +95,8 @@ versteheRequirements() { s,^https\?:.*/mysql-connector-python-[^/]*$,mysql-connector, s/^/depends:/ ' + ! grep -qwF _pinned_dependencies PKGBUILD \ + || printf 'depends:"${_pinned_dependencies[@]}"\n' } | \ tr '[:upper:]' '[:lower:]' | \ sort -u @@ -105,7 +112,7 @@ versteheRequirements() { p ' | \ sed ' - /^cython\($\|[<>=]\)\|^python-/! s/^/python-/ + /^cython\($\|[<>=]\)\|^python-\|^"\?\$/! s/^/python-/ /[^<>]=/ s/=/>=/ ' ) diff --git a/testeAbhaengigkeiten b/testeAbhaengigkeiten index e76bd5da2..38c98fbed 100755 --- a/testeAbhaengigkeiten +++ b/testeAbhaengigkeiten @@ -72,7 +72,12 @@ if ${err}; then if [ -n "${metaYml["${wasAusgeben}"]}" ]; then echo "${wasAusgeben}=(" echo "${metaYml["${wasAusgeben}"]})" | \ - sed "s|^\s*||; s|\s*\$||; s|^\(.*[^)]\)\()\?\)\$| '\1'\2|" + sed ' + s|^\s*|| + s|\s*$|| + s|^\([^"].*[^)]\)\()\?\)$|'"'"'\1'"'"'\2| + s|^["'"'"']| \0| + ' fi done | \ sed ':begin; |