From 25531f565e7a89ce54744a5c321942845991905b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bar=C4=B1=C5=9F=20Metin?= Date: Wed, 29 Jun 2005 14:04:24 +0000 Subject: [PATCH] =?UTF-8?q?=C3=87a=C4=9Flar=20path=20=C3=A7ak=C4=B1=C5=9Fm?= =?UTF-8?q?alar=C4=B1n=C4=B1n=20do=C4=9Fru=20=C3=A7al=C4=B1=C5=9Fmad=C4=B1?= =?UTF-8?q?=C4=9F=C4=B1n=C4=B1=20bildirdi.=20Hakl=C4=B1.=20Bu=20commit=20i?= =?UTF-8?q?le=20bir=20deneme=20yap=C4=B1yorum,=20fakat=20halen=20d=C3=BCzg?= =?UTF-8?q?=C3=BCn=20=C3=A7al=C4=B1=C5=9Fm=C4=B1yor.=20Eve=20gidince=20d?= =?UTF-8?q?=C3=BCzeltece=C4=9Fim=20ve=20belgeleyece=C4=9Fim.=20Bilginiz=20?= =?UTF-8?q?olsun...?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pisi/build.py | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/pisi/build.py b/pisi/build.py index 602cebca..3adcc1c8 100644 --- a/pisi/build.py +++ b/pisi/build.py @@ -39,6 +39,22 @@ def getFileType(path, pinfoList): ftype = pinfo.fileType return ftype +def checkPathCollutions(spath, spkg, pkgList): + # check collution with other packages + + # FIXME: BU ŞU ANDA İSTEDİĞİM GİBİ ÇALIŞMIYOR. EVE GİDİNCE + # DÜZELTECEĞİM VE BELGELEYECEĞİM. + collutions = [] + for package in pkgList: + if package is spkg: + continue + + for path in package.paths: + if path.pathname.startswith(spath): + collutions.append(path.pathname) + + return collutions + class PisiBuild: """PisiBuild class, provides the package build and creation routines""" @@ -190,6 +206,13 @@ class PisiBuild: files = Files() install_dir = self.ctx.pkg_install_dir() for pinfo in package.paths: + collutions = checkPathCollutions(pinfo.pathname, + package, + self.spec.packages) + # don't add collutions to files.xml + if pinfo.pathname in collutions: + continue + path = install_dir + pinfo.pathname for fpath, fhash in util.get_file_hashes(path): frpath = util.removepathprefix(install_dir, fpath) # relative path