2015-12-07 171 views
0

我刚开始使用PreMake来构建我的项目解决方案,它真的非常棒!文本文件构建依赖关系

还有一件事我仍然可以弄清楚......我有用于为我的项目生成C++代码的文本文件(.oxd)文件。我得到了prebuild命令,但Visual Studio中的项目中的.oxd文件会自动标记为项目类型:“不参与构建”。我希望将它们标记为文本文件,以便在修改它时触发构建项目(并预编译命令),当我编译时。

有什么想法?

干杯!

回答

0

预生成命令不支持输入依赖关系。改为看看Custom Build Commands

从该网页的示例显示了基本语法:

filter 'files:**.lua' 
    -- A message to display while this build step is running (optional) 
    buildmessage 'Compiling %{file.relpath}' 

    -- One or more commands to run (required) 
    buildcommands { 
     'luac -o "%{cfg.objdir}/%{file.basename}.out" "%{file.relpath}"' 
    } 

    -- One or more outputs resulting from the build (required) 
    buildoutputs { '%{cfg.objdir}/%{file.basename}.c' }