I am trying to make a dll but I am coming up with the following error:

\Debug\VideoCapture2.dll.intermediate.manifest : general error c1010070: Failed to load and parse the manifest. The system cannot find the file specified.

I set up my project according to msdn using visual studio 2008.

I looked for a solution but my project name doesnt contain "."

Now, I went and had a look for this manifest file and I found it: "VideoCapture2.dll.embed.manifest" and looked at the project properties and found "(IntDir)\$(TargetFileName).intermediate.manifest" in the linker info for creating the file. I tried changing the file name manualy (just changing embed to intermediate) after a compile, and the next compile worked fine... But this is a pain to do every time i run my project - Does anyone know of a way to fix it?

Dani AI

Generated

A brief diagnostic and practical checklist for the manifest-step failure seen here.

Visual Studio’s build pipeline generates a manifest during link and then runs the Manifest Tool (mt.exe) to validate/embed it into the PE. When mt.exe cannot find or open the generated manifest file, or the manifest XML is invalid, the embed step fails and the build stops. The VS docs explain the embed/validation step and why the manifest is required for things like UAC and side-by-side dependencies. Embedding a manifest in Visual Studio. (learn.microsoft.com)

Common causes to check (many community reports show these patterns): spaces or unexpected characters in the full project path or the TMP/TEMP locations; missing or wrong-version mt.exe; an “empty/minimal” project layout that doesn’t produce the expected intermediate file; antivirus/Windows Defender locking the freshly-linked binary between link and mt.exe; or a malformed manifest XML. Community threads document the space-in-path and AV-locking cases and the practical workarounds people used. StackOverflow discussion · [Microsoft Tech Community thread on Defender locking]. (stackoverflow.com)

Practical, ordered steps to fix and to debug:

  1. Clean / remove the intermediate build folder and Rebuild.
  2. Validate the manifest with mt.exe to see XML/schema problems: run mt.exe -manifest path\to\generated.manifest -validate_manifest.
  3. Confirm the mt.exe being used is the one from your Visual Studio/Windows SDK (update SDK if needed).
  4. If your username/path contains spaces, try building from a short/no-space path or set TMP/TEMP to a no-space temp folder.
  5. If AV is suspected, add build-folder/process exclusions or temporarily set MT_EXECUTE_DELAY=1000 to reduce race conditions.
  6. As last resort for debugging only, disable manifest generation (/MANIFEST:NO or Project → Linker → Manifest File → Generate Manifest = No); note this hides the symptom and can mask runtime manifest problems. (learn.microsoft.com)

As observed, certain project-creation choices change what gets generated; prefer creating a normal VC++ project (then remove unwanted files) rather than leaving the project skeleton minimal, and confirm manifest-tool settings before relying on manual rename workarounds.

Fixed it (i think you could have changed "(IntDir)\$(TargetFileName).intermediate.manifest" in the linker to "(IntDir)\$(TargetFileName).embed.manifest", but it all seemed a bit dodgey. It doesn't do it if you dont tick "empty project". If you want an empty project, just make one and delete everything in it and set "use precompiled headers" to no

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.