Hi David,
Thanks.
Background of our project:
In our project there are many modules. The existing build system is using
Microsoft Visual Studio. Each module has a Microsoft Visual Studio project
(.vcxproj) file and in some of the project files, Microsoft Visual Studio
targets (.targets) file is included using the import statement.
As an example, let us take a module with the name "module1". It will have a
Visual Studio project with the name "module1.vcxproj". The file
"module1.vcxproj" file will include the Microsoft Visual Studio targets file
"target1.targets" as follows:
<Import Project="target1.targets" />
Attaching a sample "target1.targets" file for your reference. In that, there
are many entries as follows (for each target) and there are certain steps that
get executed within the Target block.
<Target Name="Target_1" ....>
....
</Target>
Requirement:
The requirement is to convert the existing Microsoft Visual Studio built system
to cmake built system.
As per cmake requirement, we have created CMakeLists.txt file for module
"module1". Cmake does not understand or include .targets file directly. So,
there is a need to put the equivalent logic of whatever steps are executed
within the <Target> blocks in .targets file into the corresponding cmake
statements in CMakeLists.txt file of module "module1".
So, is there any mechanism that cmake provides for doing that ?
Are there any examples of such work being done in the past, which we can refer
to ?
Thanks & Regards
Ravi Raman
Xoriant Solutions Pvt. Ltd
4th Floor, Winchester, Hiranandani Business Park, Powai, Mumbai 400076, INDIA.
Tel: +91 22 30511000,9930100026 Extn: 2144 Voip No. 4088344495/96/97/98 Voip
Extn:1178| Fax: +91 22 30511111
[email protected]| http://www.xoriant.com
-----Original Message-----
From: David Cole [mailto:[email protected]]
Sent: Wednesday, July 30, 2014 9:22 PM
To: Ravi Raman
Cc: [email protected]
Subject: Re: [CMake] Cmake issue regarding conversion of existing Visual Studio
.targets files to cmake
To the best of my knowledge, CMake does not do anything with ".targets"
files. It doesn't know what they are, and it doesn't generate any of
them...
What is the function of the .targets files in your non-CMake build
system?
Perhaps somebody else who is more familiar with .targets files is
listening and can chime in. I'm not sure what to recommend for you.
add_custom_target and add_custom_command are commands you can use to
organize and execute custom build steps (as opposed to compiling source
files as part of an add_library or add_executable)
Maybe.... with the build system you can generate using CMake, you won't
even need the .targets files anymore. If you do need them, I'd be
curious to learn what it is your .targets file do and why you still
need them.
HTH,
David C.
target1.targets
Description: target1.targets
-- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
