Is there a way to specify project files explicitly? #309
-
Given an example project folder structure:
I'd like to have in my vsxproj file only the src folder files and *.sharpmake.cs files, avoiding filtering out 3rdparty folder files. SourceFiles.Add("src/**.h");
SourceFiles.Add("src/**.cpp");
SourceFiles.Add("*.sharpmake.cs"); Unfortunately I see no way to do like that. Instead I have to add the whole root folder to the project then filtering extra files out by regex expressions, which doesn't seem easy for such a simple case. What's the proper way to handle my situation? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 6 replies
-
This should work: |
Beta Was this translation helpful? Give feedback.
Hi,
Sharpmake already knows about many of the extensions your need:
public Strings SourceFilesExtensions = new Strings(".cpp", ".c", ".cc", ".h", ".inl", ".hpp", ".hh", ".asm");// All files under SourceRootPath are evaluated, if match found, it will be added to SourceFiles
For the first project in the thread, could do:
// For second project in the thread
// Would suggest you move …