Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

7-Zip #30

Closed
ghost opened this issue Oct 21, 2014 · 12 comments
Closed

7-Zip #30

ghost opened this issue Oct 21, 2014 · 12 comments

Comments

@ghost
Copy link

ghost commented Oct 21, 2014

I have noticed the 7zip package is installing the 32-bit version regardless of
operating system.

This is a problem; I have found that installing the 32-bit version on 64-bit
Windows 7 breaks the context menu entries.

@ferventcoder
Copy link
Owner

I think at the time the x64 version was not considered stable. I'm guessing that is not true anymore.

@ghost
Copy link
Author

ghost commented Oct 21, 2014

@ferventcoder I tried it on a virtual machine and it is working correctly. For
some reason on my 64-bit Windows 7 running chocolatey.exe launches a 32-bit
powershell.exe.

@ferventcoder
Copy link
Owner

@svnpenn if you are in PS, before you install - type [System.IntPtr]::Size - what is the result?

@ghost
Copy link
Author

ghost commented Oct 21, 2014

@ferventcoder it returns 8 as expected

PS > [System.IntPtr]::Size
8

Again, the problem is that even though I am using Windows 7 64-bit, and running

choco install 7zip 

from a 64-bit PowerShell window, choco.exe is spawning a 32-bit PowerShell
process which breaks the bit detection after that. A clean Windows virtual
machine is not having this problem, but I would like to avoid reinstalling
Windows if possible.

@ferventcoder
Copy link
Owner

Are you familiar with filesystem redirection? I don't know why, but it seems like something is being subjected to this.

One then you can try is where powershell / or from powershell console &where.exe powershell - see where that is pointing to, I'm guessing it may point to c:\windows\SysWOW64\yadayada\powershell.exe

@ghost
Copy link
Author

ghost commented Oct 22, 2014

I found the answer! It appears I deleted the Enable64Bit registry value at
some point. This caused “Any CPU” programs such as Chocolatey to be run as
32-bit. To fix that, I used this command

C:\Windows\Microsoft.NET\Framework64\v2.0.50727> Ldr64 set64

Any CPU 32-bit mode on 64 bit machine

@ferventcoder
Copy link
Owner

@svnpenn TIL. Interesting.

@ferventcoder
Copy link
Owner

I think this could be documented somewhere... hmm

@ghost
Copy link
Author

ghost commented Oct 22, 2014

I feel the registry key should be checked when installing Chocolatey

@ferventcoder
Copy link
Owner

This should ultimately become a troubleshooting thing - https://github.com/chocolatey/chocolatey/wiki/ChocolateyFAQs#im-seeing-chocolatey--application--tool-using-32-bit-to-run-instead-of-x64-what-is-going-on

Because of the stackoverflow notes, I don't think chocolatey should change it, but it should report it during install if it is set incorrectly.

@ferventcoder
Copy link
Owner

Added chocolatey-archive/chocolatey#593 to address this.

@ghost
Copy link
Author

ghost commented Oct 22, 2014

Thanks so much!

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

No branches or pull requests

1 participant