Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9001651
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T00:27:54+00:00 2026-06-16T00:27:54+00:00

I have a visual C++ project for a DLL and a setup project for

  • 0

I have a visual C++ project for a DLL and a setup project for it. In the installer i’ve added the content files of my project.

Is there a way to add a file as a content file depending on if you are compiling debug or release? I want to include boost_date_time-vc100-mt-gd-1_51.dll if I compile under debug and boost_date_time-vc100-mt-1_51.dll if I compile under release.

My additional deps looks like this

Shell32.lib;libzmq.lib;log4cxx.lib;boost_date_time-vc100-mt-gd-1_51.lib;...

Under additional library directories i’ve added the path to all these .lib files which also contains their respective .dll files

I’ve tried the following with no success…

  1. Added a Custom build step to run before build that copies the correct dll files to the OutDir and set the Output of this custom build step to be the dll files.

  2. Conditionally include a content file by manually editing the vcxproj file. If configuration was release mode I would set the non-debug version as deployment content and the debug version to false and vice versa for Debug mode. This looked something like this,

    <ItemGroup Condition="'$(Configuration)'=='Release'">

    <None Include="boost_date_time-vc100-mt-1_51.dll ">

    <DeploymentContent>true</DeploymentContent>....

    </None></ItemGroup

Neither of these worked however. The second option seemed to always default to debug mode no matter how I built my project.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T00:27:55+00:00Added an answer on June 16, 2026 at 12:27 am

    When you add a dependency, you can add it to one configuration or all configurations:

    enter image description here

    [This picture is of VS 2012, but 2010 and 2008 look pretty much the same.]

    So, you pick the configuration you want to modify at the top-left, then add the library to the additional dependencies. Note that what you add here will be the .lib file associated with a DLL, not the dll itself (the compiler will make the executable depend on the DLL because you link with its .lib file).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

When I add a file to my setup deployment project, Visual Studio won't allow
I have a CodeSmith 6 project setup in Visual Studio. I added a class
I have a .DLL that i include in my Visual Studio 2008 project. The
I have visual studio setup project with a custom RadioButtons dialog. How do I
I have a Visual Studio project which uses nmake to call a Python file
I am using Visual studio 2008. I have a Visual C project new.vcproj. There
I have got a setup project in WiX in Visual Studio 2010 and in
Is Visual Studio's Setup Wizard project able to only deploy some of the files
I am creating a Visual Studio Setup and Deployment project to install a DLL
in my Visual Studio 2010 setup project, I have a managed Custom Action. It

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.