 
     // Track targets that need module aliases for each package
     for packageBuilder in packageBuilders {
-        for prod in packageBuilder.package.products {
-            var list = prod.targets.map{$0.dependencies}.flatMap{$0}.compactMap{$0.target?.name}
-            list.append(contentsOf: prod.targets.map{$0.name})
-            aliasTracker.addAliasesForTargets(list, for: prod.name, in: packageBuilder.package.identity)
+        for produdct in packageBuilder.package.products {
+            var list = produdct.targets.map{$0.dependencies}.flatMap{$0}.compactMap{$0.target?.name}
+            list.append(contentsOf: produdct.targets.map{$0.name})
+            aliasTracker.addAliasesForTargets(list, product: produdct.name, package: packageBuilder.package.identity)
         }
     }
 

    init() {}

    func addAlias(_ alias: String,
                  of targetName: String,
                  for product: String,
                  from originPackage: PackageIdentity,
                  in parentPackage: PackageIdentity) {
        let model = ModuleAliasModel(name: targetName, alias: alias, originPackage: originPackage, parentPackage: parentPackage)
        aliasMap[originPackage, default: [:]][product, default: []].append(model)
    }


        for child in children {
            if let parentMap = idTargetToAliases[cur],
               let childMap = idTargetToAliases[child] {
                for (_, parentAliases) in parentMap {
                    for parentModel in parentAliases {
                        for (childTarget, childAliases) in childMap {
                            if !parentMap.keys.contains(childTarget),
