http://bugs.winehq.org/show_bug.cgi?id=16956
--- Comment #27 from Mike Kaplinskiy mike.kaplinskiy@gmail.com 2010-04-17 21:30:03 --- Created an attachment (id=27423) --> (http://bugs.winehq.org/attachment.cgi?id=27423) patches
The patches let the installer crash at a later time, although invoking the installer again afterwards replies that the product is already installer (and the files seem to be there).
From the voicewarmup log it looks windows msi moves the rows with conflicting
diskids temporarily:
-- snip -- MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: This transform is not changing the 'Media.DiskId' column. No pre-transform fixup of this column is necessary. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The maximum 'Media.LastSequence' or 'File.Sequence' value inserted by this transform is 320 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The minimum 'Media.DiskId' value inserted by a patch transform is 100 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The maximum 'Media.DiskId' value inserted by a patch transform is 101 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The minimum 'File.Sequence' or 'Patch.Sequence' value inserted by a patch transform is 10000 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The maximum 'File.Sequence' or 'Patch.Sequence' value inserted by a patch transform is 10038. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: No collisions detected between this transform and existing data added by patch transforms. No pre-transform fixup is necessary. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Applying regular transform to database.
MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The minimum 'Media.DiskId' value inserted by a patch transform is 100 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The maximum 'Media.DiskId' value inserted by a patch transform is 101 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The minimum 'File.Sequence' or 'Patch.Sequence' value inserted by a patch transform is 10000 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: The maximum 'File.Sequence' or 'Patch.Sequence' value inserted by a patch transform is 10038. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Temporarily moving 'Media' table row with 'DiskId' value 101 to avoid conflict with this transform. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Temporarily moving 'PatchPackage' table row with 'Media_' value 101 to avoid conflict with this transform MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Applying special patch transform to database. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Modifying 'File' and 'Patch' rows added by this patch transform to have appropriate 'Sequence' values. Offsetting values by 9038 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Modifying 'PatchPackage' table row added by this patch transform to use 'Media_' value 102. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Modifying 'Media' table row added by this patch transform to use 'DiskId' value 102 and 'Source' values MSPSRC558CD0A70548422088FE01CC1477DF61. MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Moving 'Media' table row back to use correct 'DiskId' value 101 MSI (s) (54:D8) [21:30:57:703]: TRANSFORM: Moving 'PatchPackage' table row back to use correct 'Media_' value 101 -- snip --
But these are not the only ways that dot net abuses the installer. All of the patches bundled with SP1 are of exactly the same structure - i.e. a transform T1toU1 (and special transform #T1toU1), and a cab file PCW_CAB_NetFX.cab . The worst part is that some (read: NetFX_CA.msp) patches have a completely empty cab file yet add a media entry nonetheless. So our media source handling gets botched since we don't expect conflicting stream filenames, or media entries with no files. All of the patches have overlapping file sequence numbers as well, so we need to do offset these numbers. (And as I found out, you also need to offset sequence numbers from files that have their sequence number changed by a patch).
These patches fix all these problems and let the installer install all of the files. However afterwards the installer still crashes, but it seems like for a different reason.
Could an MSI guru look at this and say whether the direction of the patches at least right? I recognize that "msi: offset file/patch sequences and media diskids to prevent conflicts when applying a patch" is a mess and should probably be moved out of action.c