From 4a1432da7418562496c0a7b19701c0edbe11bec6 Mon Sep 17 00:00:00 2001 From: mattias Date: Thu, 26 Feb 2015 08:21:07 +0000 Subject: [PATCH] IDE: checking orphaned ppu files: ignore shared directories git-svn-id: trunk@48010 - --- packager/interpkgconflictfiles.pas | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/packager/interpkgconflictfiles.pas b/packager/interpkgconflictfiles.pas index 8eef15837e..a225b6d9ee 100644 --- a/packager/interpkgconflictfiles.pas +++ b/packager/interpkgconflictfiles.pas @@ -495,6 +495,16 @@ var // other unit with same name found OtherNode:=OtherNode.Successor; if OtherFile.OwnerInfo=aPPUFile.OwnerInfo then continue; + + if CompareFilenames(aPPUFile.FullFilename,OtherFile.FullFilename)=0 then + begin + // two packages share directories + // it would would require a lenghty codetools check to find out + // if this is right or wrong + // => skip + continue; + end; + // ppu in one package, unit with same name in another package if OptionUrAllowsDuplicate(aPPUFile,OtherFile) then continue; //debugln(['CheckPPUFilesInWrongDirs duplicate units found: file1="',aPPUFile.FullFilename,'"(',aPPUFile.OwnerInfo.Name,') file2="',OtherFile.FullFilename,'"(',OtherFile.OwnerInfo.Name,')']); @@ -557,6 +567,16 @@ var while OtherNode<>nil do begin OtherFile:=TPGInterPkgFile(OtherNode.Data); if (ComparePGInterPkgShortFilename(CurFile,OtherFile)<>0) then break; + + if CompareFilenames(CurFile.FullFilename,OtherFile.FullFilename)=0 then + begin + // two packages share directories + // it would would require a lenghty codetools check to find out + // if this is right or wrong + // => skip + continue; + end; + // other file with same short name found OtherNode:=OtherNode.Successor; if OtherFile.OwnerInfo=CurFile.OwnerInfo then continue;