Added support for case-insensitive recognition of package names. Fixes #5854.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36534 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Matt Madia
2010-04-29 15:56:46 +00:00
parent ac8e7456e6
commit 2731f156ed
+5 -3
View File
@@ -393,7 +393,7 @@ function ReadPackageNamesIntoMemory()
# read list into associative array
while read line ; do
local pkg=`echo ${line} | awk '{print $1}'`
local pkgDeps=${line/':'/}
local pkgDeps=${line/"${pkg} :"/}
availablePackages[${pkg}]="${pkgDeps}"
availablePackagesKeys="${availablePackagesKeys} ${pkg}"
done < ${file}
@@ -419,8 +419,9 @@ function GeneratePackageNames()
nonRepeatingDeps=""
GetPackageDependencies "$pkg"
local lowerCasePkg=`echo ${pkg} | tr '[A-Z]' '[a-z]'`
if IsPackageAndDepsOkToInstall ${pkg} ; then
echo "${pkg} : ${nonRepeatingDeps}" >> ${file}
echo "${lowerCasePkg} : ${pkg} ${nonRepeatingDeps}" >> ${file}
fi
done < ${file}.temp
@@ -483,7 +484,8 @@ function BuildListOfRequestedPackages()
shift
fi
while [ $# -gt 0 ]; do
wantsToInstall="${wantsToInstall} $1"
local lowerCase=`echo $1 | tr '[A-Z]' '[a-z]'`
wantsToInstall="${wantsToInstall} $lowerCase"
shift
done
}