Obj in Debug and Release

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Obj in Debug and Release

Pierre-Julien VILLOUD-3

Hi everyone,

 

I’m using CMake 2.6 with C++ projects. I would like object files to be built in a distinct directory if the configuration is Debug or Release.

As I understood, obj files are written in CMakefiles/ProjectName.dir. Is is possible to be CMakeFiles/ProjectName.dir/${CMAKE_BUILD_TYPE} ??

 

Thanks in advance

 

Best regards

 

Pierre-Julien


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: Obj in Debug and Release

Pau Garcia i Quiles
On Tue, Aug 4, 2009 at 11:34 AM, Pierre-Julien
Villoud<[hidden email]> wrote:

> Hi everyone,
>
>
>
> I’m using CMake 2.6 with C++ projects. I would like object files to be built
> in a distinct directory if the configuration is Debug or Release.
>
> As I understood, obj files are written in CMakefiles/ProjectName.dir. Is is
> possible to be CMakeFiles/ProjectName.dir/${CMAKE_BUILD_TYPE} ??
>
>
>
> Thanks in advance

What platform (operating system and compiler) are you using?

What you ask for is what the VC++ generator will do by default. For
gcc you'll need to create two different build directories, one for
release, one for debug. Are you using anything else?

--
Pau Garcia i Quiles
http://www.elpauer.org
(Due to my workload, I may need 10 days to answer)
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: Obj in Debug and Release

Pierre-Julien VILLOUD-3
Sorry, I did not precise that I work with GCC.
Thanks for your answer, I thought about that solution but I wondered if something specific existed...

Thanks !

-----Message d'origine-----
De : Pau Garcia i Quiles [mailto:[hidden email]]
Envoyé : mardi 4 août 2009 12:26
À : Pierre-Julien Villoud
Cc : cmake
Objet : Re: [CMake] Obj in Debug and Release

On Tue, Aug 4, 2009 at 11:34 AM, Pierre-Julien
Villoud<[hidden email]> wrote:

> Hi everyone,
>
>
>
> I'm using CMake 2.6 with C++ projects. I would like object files to be built
> in a distinct directory if the configuration is Debug or Release.
>
> As I understood, obj files are written in CMakefiles/ProjectName.dir. Is is
> possible to be CMakeFiles/ProjectName.dir/${CMAKE_BUILD_TYPE} ??
>
>
>
> Thanks in advance

What platform (operating system and compiler) are you using?

What you ask for is what the VC++ generator will do by default. For
gcc you'll need to create two different build directories, one for
release, one for debug. Are you using anything else?

--
Pau Garcia i Quiles
http://www.elpauer.org
(Due to my workload, I may need 10 days to answer)
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: Obj in Debug and Release

Alexander Neundorf-3
On Tuesday 04 August 2009, Pierre-Julien Villoud wrote:
> Sorry, I did not precise that I work with GCC.
> Thanks for your answer, I thought about that solution but I wondered if
> something specific existed...

Using separate build directories for release and debug is the correct way to
do it if you are using a makefile-based generator.

Alex
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake