KTX-Software icon indicating copy to clipboard operation
KTX-Software copied to clipboard

Issues with draft Windows installer

Open MarkCallow opened this issue 4 years ago • 10 comments

I've had the following issues with the draft Windows installer:

  • [x] 1. The installer name has Windows in it. It needs to indicate whether it is for 32- or 64-bit Windows.
  • [x] 2. Warning from Win 10 requiring bypass to install software from an unidentified developer. (I.e. we need to sign it.)
  • [ ] 3. Norton antivirus accuses the installer of suspicious activity (SONAR.Heuristic.170) before it even displays its first window. A similar report said the file triggering it was a .ini fle in an installer. That was a false positive as I suspect this is. I've reported it to, er, Broadcom, who seems to have bought Symantec who years ago bought Norton.
  • [ ] 4. Attempt to add the install directory to %PATH% fails saying the PATH is too long. It isn't. The maximum supported length is 2048 and my %PATH% is around 1968 characters so there is room for c:\Program Files\KTX-Software\bin.
  • [x] 5. Application version numbers have "-dirty" appended.
  • [ ] 6. The license display does not understand rtf. The text is large and links aren't displayed correctly.
  • [x] 7. uninstaller has empty file name (.exe only).
  • [x] 8. Workarea is dirty again. This is due to dfd2vk.inl being rebuilt with incorrect line endings in the build so the workarea is dirty after the build and before the package is made.

MarkCallow avatar Jun 26 '20 20:06 MarkCallow

It is necessary to also sign the uninstaller. Since this is normally created during the install, special steps are needed, outlined in https://nsis.sourceforge.io/Signing_an_Uninstaller.

MarkCallow avatar Jun 27 '20 00:06 MarkCallow

No. 5 is because the following OpenGL ES emulator libraries are being downloaded into the root of the git workarea.

Untracked files: (use "git add ..." to include in what will be committed) libEGL.dll libEGL.lib libGLES_CM.dll libGLES_CM.lib libGLESv2.dll libGLESv2.lib

This appears to be unintentional. `.appveyor.yml contains the following lins:

REM md C:\Imagination\PowerVR_Graphics\PowerVR_SDK\SDK_%PVR_SDK_DL_VER%\Builds\Windows\x86_64\Lib
REM cd C:\Imagination\PowerVR_Graphics\PowerVR_SDK\SDK_%PVR_SDK_DL_VER%\Builds\Windows\x86_64\Lib & curl -O https://raw.githubusercontent.com/powervr-graphics/Native_SDK/%PVR_SDK_GH_VER%/Builds/Windows/x86_64/Lib/libEGL.{dll,lib} -O https://raw.githubusercontent.com/powervr-graphics/Native_SDK/%PVR_SDK_GH_VER%/Builds/Windows/x86_64/Lib/libGLES_CM.{dll,lib} -O https://raw.githubusercontent.com/powervr-graphics/Native_SDK/%PVR_SDK_GH_VER%/Builds/Windows/x86_64/Lib/libGLESv2.{dll,lib}

The part of the second line following the '&' is being executed despite the REM at the start of the line. I will uncomment the whole thing. Since I don't think the es load tests are being built yet nothing should be affected by the move.

MarkCallow avatar Jun 27 '20 18:06 MarkCallow

Unbelievably weird. Cmd prompt continues to parse lines starting with REM and if it sees &, it executes what follows. I had to put another REM after the & to stop the 32-bit download.

MarkCallow avatar Jun 27 '20 22:06 MarkCallow

Norton, er ... Broadcom, has confirmed the false positive and say the detection will be removed from their products in the next virus definitions update. The whitelisting may take 24 hours to take effect.

MarkCallow avatar Jun 29 '20 05:06 MarkCallow

I can confirm that Broadcom has fixed item 3. Norton users, and probably Symantec users too, will have to use LiveUpdate to get the latest definitions with the fix.

MarkCallow avatar Jun 29 '20 18:06 MarkCallow

One more small issue is that after installation, KTX-Software folder in Program Files has an executable file with an empty name (probably the uninstaller?)

image

zeux avatar Jul 03 '20 17:07 zeux

Re adding directory to %PATH%. I was able to manual add it, i.e. via the Windows control panel so there was definitely space. This needs further investigation.

MarkCallow avatar Jul 05 '20 22:07 MarkCallow

The latest installer has fixed a couple of the issues and I've checked them off.

Issue #3 is still a big problem. Still coming despite multiple reports to Norton. Norton says that the suspicious behavior includes starting an event watcher process and starting an event process. Why would NSIS be starting an event watcher? It does sound suspicious. Any ideas @atteneder? Is this normal behavior for an installer?

MarkCallow avatar Sep 17 '20 00:09 MarkCallow

The latest installer has fixed a couple of the issues and I've checked them off.

Great!

Issue #3 is still a big problem. Still coming despite multiple reports to Norton. Norton says that the suspicious behavior includes starting an event watcher process and starting an event process. Why would NSIS be starting an event watcher? It does sound suspicious. Any ideas @atteneder? Is this normal behavior for an installer?

No, not that I know of. But I don't use anti virus atm, so no idea.

atteneder avatar Sep 17 '20 09:09 atteneder

I suspect that the installer is using Windows' setx command to add the KTX bin directory to %PATH%. This has the unfortunate behavior of truncating the target value (i.e. PATH) when it is > 1025 bytes long. The warning most likely comes because NSIS is checking if the length will exceed this. Apart from the setx behavior this is all guess work.

For others who stumble on this, potential workaarounds are: adding for current user or manually adding the location to %PATH% via the Windows control panel. The default installation location is C:\Program Files\KTX-Software\bin.

I'd happily accept a pull request to change to a different open source installer that does not have this issue.

MarkCallow avatar Jun 03 '22 08:06 MarkCallow

Final issue fixed by PR #778.

MarkCallow avatar Oct 04 '23 01:10 MarkCallow