c++ - Using Visual Studio for IDE but using CMake for cross platform configuration -
i have found lot of similar questions i'm ask, don't seem flat out help me understand how want do, assuming it's feasible.
i enjoy visual studio quite bit, , want utilize development environment c++ projects, want able build projects of mine on dual boot linux scheme if want. want able organize headers , source files specific directory construction on shared drive. want utilize cmake configure project build either create on linux or vs on windows.
so possible maintain project in visual studio 2012 pro take advantage of intellisense , compiling sake of writing code , testing it, , making source files part cmake configuration in different directory (i figure still have maintain cmake .txt files no matter what)?
i can copying source project directory cmake files folder every time add together or modify code, updating cmake .txt files, seems time consuming.
edit: know there converter converts solutions cmake files. best option? if so, work well?
my best reply question:
while cannot recommend tool since have not used it, seems closest in line looking for.
http://sourceforge.net/projects/vcproj2cmake/
it requires ruby runtime installed on machine, generate cmakelists based on visual studio project.
i cautious depending on much, there may subtle cmake nuances lost in conversion, has several favorable reviews , create process easier, if there manual steps involved prior checking in (to verify cmake script correct).
perhaps can integrate unit testing verify integrity of cmake scripts? , offer patches issues find.
a potential alternative:i inferring things forgive me if making assumptions.
if goals cross platform , cmake isn't requirement technology (just means ends), don't want adopt using recommended cmake workflow because it's not intuitive (i can totally understand that), perhaps can take @ premake, newer still robust project generation tool:
http://industriousone.com/premake
i've found syntax (pure lua) much easier grok, , models projects much more closely visual studio solutions. might more natural workflow you.
also it's open source , found it's surprisingly easy add together extensions (it's been year since lastly used so, not sure state of in now). perhaps build reverse generator well, since library comes finish visual studio project parser , little creativity have generate in both directions.
i chose not adopt year ago because @ time had difficulty generating xcode projects depended on 1 (perhaps it's fixed!) had no problems makefiles or visual studio solutions though.
a final recommendationthe reason not recommend reverse generating project generation scripts visual studio project puts awkward dependency on project. visual studio projects not standardized, or open - , if microsoft changes format break workflow until or else creates patch reverse-generator working again.
you argue project generation shares same problems, visual studio has historically been backwards compatible - or @ to the lowest degree shipping tools perform project updating. generating project in older version work, while trying parse newer revision of visual studio solution much more prone error , breakage.
if serious production project hope go on used , maintained many years come, advise adopting proven workflow (working straight in cmake or premake files) if it's less ideal or uncomfortable @ first developers. if it's going long term project, time take familiar in new workflow dwarfed time take go on maintain adhoc build scheme across multiple platforms , varying teams. plus, add together tool belt developer. 2 cents~
c++ visual-studio cmake
No comments:
Post a Comment