Issue 119948 - [Windows 8 certification]Windows App Certification Kit - Test for "Section 5 Apps must support a clean, reversible installation" is failed.
Summary: [Windows 8 certification]Windows App Certification Kit - Test for "Section 5 ...
Status: CLOSED FIXED
Alias: None
Product: Installation
Classification: Application
Component: ui (show other issues)
Version: 3.4.0
Hardware: PC Windows 7
: P3 Blocker (vote)
Target Milestone: 3.4.1
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks: 121359 121372
  Show dependency tree
 
Reported: 2012-06-12 05:27 UTC by DaLi Liu
Modified: 2012-11-23 07:16 UTC (History)
6 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---
jsc: 3.4.1_release_blocker+


Attachments
Patch to the font isssue (2.61 KB, patch)
2012-06-25 08:28 UTC, qiuhuaidong
no flags Details | Diff
Change font component attribute to msidbComponentAttributesSharedDllRefCount (513 bytes, patch)
2012-06-28 03:17 UTC, qiuhuaidong
awf.aoo: review+
Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description DaLi Liu 2012-06-12 05:27:49 UTC
Test the package Apache_OpenOffice_incubating_3.4.0_Win_x86_install_en-US.exe  with Windows App Certification Kit on windows 8 release preview, get this warning result, it will be passed in order to pass the Windows 8 certification program.
----------------------------------------------------------------------
Related links:
Windows 8 Preview ISO image
http://windows.microsoft.com/en-US/windows-8/iso
Windows App Certification Kit
http://msdn.microsoft.com/en-us/windows/desktop/hh852363
Certification requirements for Windows 8 desktop apps
http://msdn.microsoft.com/library/windows/desktop/hh749939
----------------------------------------------------------------------
Part of The result.
Clean reversible install test

WARNING
    Remove all non-shared files and folders

    Warning: The non-shared files and folders test detected the following errors:
        File 'C:\Windows\Fonts\opens___.ttf' was not deleted.
        File 'C:\Windows\Fonts\GenBkBasR.ttf' was not deleted.
        File 'C:\Windows\Fonts\GenBkBasI.ttf' was not deleted.
        File 'C:\Windows\Fonts\GenBkBasBI.ttf' was not deleted.
        File 'C:\Windows\Fonts\GenBkBasB.ttf' was not deleted.
        File 'C:\install.res.1036.dll' was not deleted.
        File 'C:\install.res.3082.dll' was not deleted.
        File 'C:\install.res.1033.dll' was not deleted.
        File 'C:\install.res.1031.dll' was not deleted.
        File 'C:\install.res.1028.dll' was not deleted.
        File 'C:\install.res.2052.dll' was not deleted.
        ......
    Impact if not fixed: A user might remove an app to free up disk space or to return the computer to the state before installing the app. The uninstall process must restore the machine to its original state for the best user experience.
    How to fix: Remove all the files and Add/Remove Program entries. See link below for more information:
    Installer Properties 
http://go.microsoft.com/fwlink/?LinkID=247352&clcid=0x409
----------------------------------------------------------------------
Please see the wiki page for full test result.
http://wiki.services.openoffice.org/wiki/Documentation/Windows_App_Certification_Kit_-_Test_Results_for_Apache_OpenOffice_3.4
Comment 1 DaLi Liu 2012-06-12 05:46:21 UTC
WARNING
    Single user registry check

    Warning: The single user registry test detected the following errors:
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] AuthorizedCDFPrefix=String: was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] Comments=String:OpenOffice.org 3.4 (en-US) (AOO340(Build:9590)) was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] Contact=String:Department for technical support was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] DisplayName=String:OpenOffice.org 3.4 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] DisplayVersion=String:3.4.9590 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] EstimatedSize=DWord:335071 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] HelpLink=ExpandString:http://www.openoffice.org was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] HelpTelephone=String:x-xxx-xxx-xxx was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] InstallDate=String:20120611 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] InstallLocation=String:C:\Program Files\OpenOffice.org 3\ was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] InstallSource=String:C:\Users\killl_000\Desktop\OpenOffice.org 3.4 (en-US) Installation Files\ was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] Language=DWord:1033 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] ModifyPath=ExpandString:MsiExec.exe /I{51071D66-D034-4239-94E0-723FCA10B6FE} was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] Publisher=String:OpenOffice.org was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] Readme=String: was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] Size=String: was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] UninstallString=ExpandString:MsiExec.exe /I{51071D66-D034-4239-94E0-723FCA10B6FE} was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] URLInfoAbout=String:http://www.openoffice.org was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] URLUpdateInfo=String:http://www.openoffice.org was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] Version=DWord:50603382 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] VersionMajor=DWord:3 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] VersionMinor=DWord:4 was modified during installation.
        Registry key [HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Uninstall\{51071D66-D034-4239-94E0-723FCA10B6FE}] WindowsInstaller=DWord:1 was modified during installation.
    Impact if not fixed: The application is available to all users of the machine.
    How to fix: In a Per user installation, should not create or modify machine wide registry entries (HKLM).
Comment 2 Olaf Felka 2012-06-12 08:28:10 UTC
These *.res files are artifacts from the VCRdist installation (https://issues.apache.org/ooo/show_bug.cgi?id=119424). For removing fonts we should think twice. These fonts might be used by other applications. Removing fonts installed by AOO might destroy the layout of these documents
Comment 3 Rob Weir 2012-06-12 18:46:06 UTC
Don't we do reference counting in install of shared components?  That should protect us if another application also depends on the same component.
Comment 4 qiuhuaidong 2012-06-21 02:31:56 UTC
I am working on the font issue. My plan is to disable the font registering during the install process, put the packed fonts into the program directory of AOO.

I already created a modified MSI file for this purpose using Orca, Next, I will change the build script for windows installer to generate the wanted MSI file.
Comment 5 Olaf Felka 2012-06-21 05:13:34 UTC
I don't think that it's a good idea to have the fonts in the program dir. No other application can use the fonts if they are not registered.
Comment 6 qiuhuaidong 2012-06-21 06:58:58 UTC
We can not remove those fonts from system directory, once the install registered those fonts as system fonts, because these fonts might be used by other applications.

If we don't remove the fonts installed by AOO, AOO can not pass the Windows App Certification check.

Other applications can register their own fonts if they need them.
Comment 7 Olaf Felka 2012-06-21 08:03:47 UTC
(In reply to comment #6)
> We can not remove those fonts from system directory, once the install
> registered those fonts as system fonts, because these fonts might be used by
> other applications.
> 
> If we don't remove the fonts installed by AOO, AOO can not pass the Windows
> App Certification check.

It's not decided that we need to pass check.

> Other applications can register their own fonts if they need them.

Yes, but they can't use the AOO font. MS Office can open ODF documents but the documents will not display correct if an AOO font can't be used by MS Office.
Comment 8 qiuhuaidong 2012-06-25 08:28:25 UTC
Created attachment 78460 [details]
Patch to the font isssue

Put the patch for installer build script to install the fonts files into the program directory.

Changes
1) remove the entry for system font directory in MSI components table.
2) change font files Attributes from 16 to 2 in MSI files table.
3) clear the entries in MSI font table.
Comment 9 qiuhuaidong 2012-06-25 08:31:57 UTC
Changes
4) remove the entry for system font directory in MSI directory table.
Comment 10 Rob Weir 2012-06-26 16:24:37 UTC
The correct way of handling this is described here:

http://technet.microsoft.com/en-us/subscriptions/aa368606%28v=vs.85%29.aspx

You treat it like a shared DLL, and reference count it in the registry.  If another application also depends on the fonts, then it should increment the reference count.  If all apps do this, then they increment the reference count at install, and decrement it at uninstall. If the reference count drops to zero then the uninstaller is safe to remove the files.  If the reference count is not zero, then you know another application depends on the file.

This method works well only if other applications follow these same conventions.  Not all of them do.  So it is also common for an uninstaller to prompt the user on whether it is OK to remove shared files that are no longer needed.

See also 2.3 here:  http://msdn.microsoft.com/en-us/library/windows/desktop/aa372825%28v=vs.85%29.aspx
Comment 11 qiuhuaidong 2012-06-28 03:17:15 UTC
Created attachment 78505 [details]
Change font component attribute to msidbComponentAttributesSharedDllRefCount

Use ref count to maintain font registration.
Comment 12 DaLi Liu 2012-07-04 09:08:17 UTC
I build aoo with huaidong's font issue patch, and test aoo install file with Windows App Certification Kit again.
The section about "Remove all non-shared files and folders" is PASSED.
Comment 13 Andre 2012-07-10 08:45:47 UTC
Comment on attachment 78505 [details]
Change font component attribute to msidbComponentAttributesSharedDllRefCount

Patch looks good.
Comment 14 Andre 2012-07-10 08:46:49 UTC
A definition of the msidbComponentAttributesSharedDllRefCount flag can be found here:
http://msdn.microsoft.com/en-us/library/windows/desktop/aa368007(v=vs.85).aspx
Comment 15 SVN Robot 2012-07-10 08:49:57 UTC
"af" committed SVN revision 1359527:
#i119948# Instruct windows installer to use refcounting on fonts.
Comment 16 Andre 2012-07-10 08:50:27 UTC
Fixed on trunk.
Comment 17 jsc 2012-07-18 11:04:29 UTC
set release blocker flag
Comment 18 Li Feng Wang 2012-07-25 07:31:54 UTC
Not merge to AOo341 branch as release blocker. Not include in AOO341 RC(r1364591).

If already merge to AOO341 branch,  suggest to add comment.
If not merge to AOO341 branch, suggest to remove 3.4.1 release blocker flag.
Comment 19 SVN Robot 2012-07-25 08:15:27 UTC
"jsc" committed SVN revision 1365484 into branches/AOO34:
#119948# merge fix from trunk
Comment 20 jsc 2012-07-25 08:37:46 UTC
set target 3.4.1
Comment 21 louqle 2012-11-23 07:16:02 UTC
Test build 1409708 with Windows App Certification Kit, by both multi-user mode and single-user mode, no warning font and res. Accroding to the comment history. Close this defect as fixed