Skip to content

Conversation

@bergmeister
Copy link
Contributor

@bergmeister bergmeister commented Jan 7, 2018

PR Summary

Fix bug #5597: x86/x64 installer are uninstalling each other when installing either of them:

-Make x86 installer to be installed as a x86 component (-arch argument to candle.exe, which sets the sys.BUILDARCH variable)
-Make the UpgradeCode unique per platform

Replace var.ProductTargetArchitecture variable with sys.BUILDARCH use to have only 1 variable for the architecture
Additionally, the architecture was appended to the package name to be able to distinguish the installations.

Windows installer PRs usually got reviewed by @SteveL-MSFT in the past.

PR Checklist

Note: Please mark anything not applicable to this PR NA.

…of them:

-Make x86 installer to be installed as a x86 component (-arch argument to candle.exe)
-Make the UpgradeCode unique per platform

Additionally, the architecture was appended to the package name to be able to distinguish the installations.
Simplified architecture variable use to have only 1 variable for it.
@bergmeister
Copy link
Contributor Author

@SteveL-MSFT @joeyaiello I am not sure if this bug was ever triaged but it seems quite severe to me and would cause problems in the future when trying to upgrade install the x86 version in 6.1 if this fix does not go into 6.0. On the other hand, I can understand that this is last minute (maybe building only the x86 installer using this fix would mitigate the risk?)...

@iSazonov
Copy link
Collaborator

iSazonov commented Jan 7, 2018

Should Explorer menu be fixed too?

@iSazonov iSazonov self-assigned this Jan 7, 2018
@bergmeister
Copy link
Contributor Author

bergmeister commented Jan 7, 2018

@iSazonov : The explorer context menu goes into 6.1 (I already asked this question, the answer by @SteveL-MSFT is here). @SteveL-MSFT said here that it is not clear whether the current behaviour is right or wrong and therefore we should wait for feedback. If the current behaviour is bothering you please open an issue so that it can be tracked and discussed further.

@iSazonov
Copy link
Collaborator

iSazonov commented Jan 8, 2018

@bergmeister My request was that in the previous PR we added the menu and in this PR we add a second PowerShell version - what version will be called from this menu? I suppose that if we want this menu, then in this PR you have to add the menu for both versions.

@bergmeister
Copy link
Contributor Author

bergmeister commented Jan 8, 2018

@iSazonov I see, you have a fair point that I did not consider the case of installing both x64 and x86 for the context menu.
But this bug fix itself has nothing to do with the context menu since it should have always worked to install both versions, hence the question to steve if this fix is needed for the release branch as well. At the moment the PR targets fixing the installer problem so that it is also easily possible to merge it into the release branch if needed/required. I shall open a 2nd WIP PR for the architecture specific context menu to separate the issues.

@SteveL-MSFT
Copy link
Member

I think the number of users using both x86 and x64 are very minimal. Giving that where we are with 6.0.0, I think we should document this (Known Issues @joeyaiello) and fix it for 6.1.0.

@SteveL-MSFT SteveL-MSFT added the Documentation Needed in this repo Documentation is needed in this repo label Jan 8, 2018
@TravisEz13
Copy link
Member

I think we need to take this for GA to ensure that we can create servicing packages correctly without creating a complicated servicing wrapper.

@SteveL-MSFT
Copy link
Member

I talked to @TravisEz13 offline, agree that servicing would be an issue so we should take this for GA.

@SteveL-MSFT SteveL-MSFT added this to the 6.0.0-GA milestone Jan 8, 2018
@SteveL-MSFT SteveL-MSFT removed the Documentation Needed in this repo Documentation is needed in this repo label Jan 8, 2018
@TravisEz13
Copy link
Member

TravisEz13 commented Jan 8, 2018

filed: #5821

@bergmeister
Copy link
Contributor Author

OK. I will prepare now a separate PR that targets the release branch to check for merge problems beforehand.

<!-- Generate Your Own GUID for both ID and UpgradeCode attributes. -->
<!-- Note: UpgradeCode GUID MUST REMAIN SAME THROUGHOUT ALL VERSIONS -->
<!-- Otherwise, updates won't occur -->
<Product Id="$(var.ProductGuid)" Name="$(var.ProductSemanticVersionWithName)" Language="1033" Version="$(var.ProductVersion)" Manufacturer="Microsoft Corporation" UpgradeCode="{f7ba3e58-0be8-443b-ac91-f99dd1e7bd3b}">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

@bergmeister bergmeister Jan 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TravisEz13 : I created a separate PR for 6.0.0 here. The difference is that it is based on the 6.0.0. branch where I cherry picked the fixing commit (an auto-merge of whitespace was needed) so that local testing becomes easier. I have addressed your comment about adding the product code related comment.
This PR shall now as WIP and for 6.1.0.
For the record: the mentioned context menu issue applies only to 6.1 and is not related to this PR

@TravisEz13
Copy link
Member

@bergmeister I will take care of any merge conflicts with the release branch. Just get it working on this branch. I've finished my review. It looks good otherwise.

@bergmeister
Copy link
Contributor Author

OK. Whatever you prefer then.

@TravisEz13
Copy link
Member

Can you get the comment added in the next few hours?

@TravisEz13
Copy link
Member

@bergmeister Thanks

@bergmeister
Copy link
Contributor Author

bergmeister commented Jan 8, 2018

No worries, my pleasure. I am glad I found it by coincidence (I guess the bug must have been in there since day one). I think the next time we have to ensure that issues get triaged better because if the impact was understood better from the reported issue then it would not have been so much last minute.
I have done some local testing if this PR got merged into the 6.0.0. branch and it seems fine as well.

@TravisEz13 TravisEz13 merged commit f8a5fc1 into PowerShell:master Jan 8, 2018
@bergmeister
Copy link
Contributor Author

I did some analysis and it showed that the bug about the upgrade code being constant and the -arch parameter being hardcoded to x64 was already present in the first commit here that added the WiX file and the MSI build script...

TravisEz13 pushed a commit to TravisEz13/PowerShell that referenced this pull request Jan 9, 2018
… same UpgradeCode as the x64 installer leading to an uninstallation of an x64 installation (and vice versa) (PowerShell#5812)

Fix bug PowerShell#5597: x86/x64 installer are uninstalling each other when installing either of them:

-Make x86 installer to be installed as an x86 component (-arch argument to candle.exe, which sets the `sys.BUILDARCH` variable)
-Make the UpgradeCode unique per platform
-Replace `var.ProductTargetArchitecture` variable with sys.BUILDARCH use to have only 1 variable for the architecture
-Additionally, the architecture was appended to the package name to be able to distinguish the installations.

# Conflicts:
#	assets/Product.wxs
@TravisEz13 TravisEz13 mentioned this pull request Jan 9, 2018
TravisEz13 pushed a commit that referenced this pull request Jan 9, 2018
… same UpgradeCode as the x64 installer leading to an uninstallation of an x64 installation (and vice versa) (#5812)

Fix bug #5597: x86/x64 installer are uninstalling each other when installing either of them:

-Make x86 installer to be installed as an x86 component (-arch argument to candle.exe, which sets the `sys.BUILDARCH` variable)
-Make the UpgradeCode unique per platform
-Replace `var.ProductTargetArchitecture` variable with sys.BUILDARCH use to have only 1 variable for the architecture
-Additionally, the architecture was appended to the package name to be able to distinguish the installations.

# Conflicts:
#	assets/Product.wxs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants