ubisoft / Sharpmake

Sharpmake is an open-source C#-based solution for generating project definition files, such as Visual Studio projects and solutions, GNU makefiles, Xcode projects, etc.
Apache License 2.0
927 stars 171 forks source link

Reference externally generated projects #218

Closed Sharlock93 closed 1 year ago

Sharlock93 commented 1 year ago

I was wondering if its possible to add a project to a solution which already exists and was generated by a different tool? I couldn't find any examples or docs on this.

For example: I have a file ProjectA.vcxproj that was generated as part of a different tool. I want to include ProjectA.vcxproj as a dependency for a project that will be generated by Sharpmake.

Sorry if this has been mentioned in some place very obvious and I just completely missed it.

Sharlock93 commented 1 year ago

After reading through the source code a bit, this is solved. You can use the configuration under a solution and use ProjectReferencesByPath.Add("<path_to_project>")