CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2009
    Location
    India
    Posts
    835

    manifest embedd doubt

    I use manifest for win 7 application. My application is linked with MFC Static Library so do I need to put decencies in manifest file?

    Old manifest with dependency
    Code:
    <?xml version='1.0' encoding='UTF-8' standalone='yes'?>
    <assembly xmlns='urn:schemas-microsoft-com:asm.v1' manifestVersion='1.0'>
      <dependency>
        <dependentAssembly>
          <assemblyIdentity type='win32' name='Microsoft.VC80.CRT' version='8.0.50727.762' processorArchitecture='x86' publicKeyToken='1fc8b3b9a1e18e3b' />
        </dependentAssembly>
      </dependency>
      <dependency>
        <dependentAssembly>
          <assemblyIdentity type='win32' name='Microsoft.VC80.MFC' version='8.0.50727.762' processorArchitecture='x86' publicKeyToken='1fc8b3b9a1e18e3b' />
        </dependentAssembly>
      </dependency>
      <dependency>
        <dependentAssembly>
          <assemblyIdentity type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='x86' publicKeyToken='6595b64144ccf1df' language='*' />
        </dependentAssembly>
      </dependency>
    
     <!-- Identify the application security requirements. -->
      <trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
        <security>
          <requestedPrivileges>
            <requestedExecutionLevel
              level="requireAdministrator"
              uiAccess="false"/>
            </requestedPrivileges>
           </security>
      </trustInfo>
    </assembly>

    new manifest with-out dependency
    Code:
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
      <trustInfo xmlns="urn:schemas-microsoft-com:asm.v2">
        <security>
          <requestedPrivileges>
            <requestedExecutionLevel
              level="requireAdministrator"
              uiAccess="false"/>
            </requestedPrivileges>
           </security>
      </trustInfo>
    </assembly>
    And which way of embedding manifest file is proper for VS 2005.

    1. Using Project Properties -> Manifest Tool -> Input / Output
    2. Using post build event
    ◄◄ hypheni ►►

  2. #2
    Join Date
    Nov 2000
    Location
    Voronezh, Russia
    Posts
    6,633

    Re: manifest embedd doubt

    Regarding manifest, any way you like is proper. Of course, if you have a project, it's always better to have it as a project attribute.

    Linker options:
    /MANIFEST
    /MANIFESTFILE

    Regarding dependencies. By removing Microsoft.Windows.Common-Controls you deprive your app a Windows theme. And prior to removing Microsoft.VC80.CRT you should make sure your app really has no dependency on the CRT dll.
    Best regards,
    Igor

  3. #3
    Join Date
    Jul 2009
    Location
    India
    Posts
    835

    Re: manifest embedd doubt

    Actually VS 2005's mt.exe has some problem, one warning comes if I use manifest by my 1st method.

    And what I observed was that if I embed manifest (without any dependency) using 1st method I get lack of XP Theme support on my application.

    And another thing. Though I have build my application using Static MFC Library is it require to put those dependencies lines in manifest ?
    ◄◄ hypheni ►►

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured