Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debug versus Release Configurations for MSVC Compiler #24

Open
LRossman opened this issue Sep 15, 2016 · 5 comments
Open

Debug versus Release Configurations for MSVC Compiler #24

LRossman opened this issue Sep 15, 2016 · 5 comments
Labels

Comments

@LRossman
Copy link
Collaborator

The current instructions in the README.md file for building EPANET 3 using the Microsoft Visual C++ Build Tools creates a debug build of the project by default. Appending /p:Configuration=Release to the msbuild command will create a release version placed in the bin\release sub-directory. Is there any specific reason to use a debug build rather than a release one? If not, I can edit the README.md file to revise the MSVC build instructions.

@bradleyjeck
Copy link
Contributor

I did not have any particular reason for using a debug build, that's just what happened by default. Thus, creating a release version is fine. Specifying this in the Cmake file that might be preferable if possible, just to keep the instructions minimal.

@LRossman
Copy link
Collaborator Author

After consulting the web there apparently is nothing you can add to the CMakeLists.txt file to make it build a release version under MSVC. So I went ahead and revised the instructions in README.md to include the "Release" switch on the msbuild command line.

@samhatchett
Copy link
Member

i'm no windows guy, but would this be relevant? :: http://stackoverflow.com/a/20423820/787801

@LRossman
Copy link
Collaborator Author

Yes, I saw that option of adding another switch to the cmake command, but figured its no different than doing the same for msbuild. @bradleyjeck was asking if something could be done to CMakeLists.txt to create the release build without making the cmake and msbuild commands any more complicated, but it appears not.

@bradleyjeck
Copy link
Contributor

Looking at it a bit further, I agree the right place for that option is on the msbuild line. For visual studio cmake creates profiles for four different builds. Thus the msbuild line seems the right place to pick the configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants