diff --git a/pamac/aur.py b/pamac/aur.py index cf48304..b22b6a1 100644 --- a/pamac/aur.py +++ b/pamac/aur.py @@ -210,4 +210,12 @@ def get_extract_tarball(pkg): print(e) return None else: - return os.path.join(srcpkgdir, pkg.name) + return os.path.join(srcpkgdir, get_name(pkg)) + +def get_name(pkg): + # the splitext is to remove the original extension + # which is tar.foo - currently foo is gz, but this can change + # the rstrip is to remove the trailing tar part. + if pkg.name not in pkg.tarpath: + return os.path.splitext(os.path.basename(pkg.tarpath))[0].rstrip('.tar') + return pkg.name diff --git a/pamac/transaction.py b/pamac/transaction.py index 7ff89a9..fad2548 100644 --- a/pamac/transaction.py +++ b/pamac/transaction.py @@ -640,7 +640,7 @@ def download(url_list, path): def build_next(): global build_proc pkg = to_build[0] - path = os.path.join(aur.srcpkgdir, pkg.name) + path = os.path.join(aur.srcpkgdir, aur.get_name(pkg)) new_pkgs = aur.get_pkgs(path + '/PKGBUILD') # sources are identicals for splitted packages # (not complete) download(new_pkgs[0].source, path)