コード例 #1
0
ファイル: oovCMaker.cpp プロジェクト: 8l/oovcde
// outDir ignored if writeToProject is true.
void CMaker::makeComponentFiles(bool writeToProject, OovStringRef const outDir,
        OovStringVec const &compNames)
    {
    FilePath incMapFn(getAnalysisPath(), FP_Dir);
    incMapFn.appendFile(Project::getAnalysisIncDepsFilename());
    mIncMap.read(incMapFn);
    if(mVerbose)
        printf("Read incmap\n");
    for(auto const &compName : compNames)
        {
        ComponentTypesFile::eCompTypes compType =
            mCompTypes.getComponentType(compName);
        if(compType != ComponentTypesFile::CT_Unknown)
            {
            OovStringVec sources = getCompSources(compName);
            FilePath outFp;
            std::string fixedCompName = makeComponentNameFromDir(compName);
            if(writeToProject)
                {
                outFp.setPath(mCompTypes.getComponentAbsolutePath(
                        compName), FP_Dir);
                outFp.appendFile("CMakeLists.txt");
                }
            else
                {
                outFp.setPath(outDir, FP_File);
                outFp.appendFile(std::string(fixedCompName + "-CMakeLists.txt"));
                }
            // Using the filepath here gives:
            // "Error evaluating generator expression", and "Target name not supported"
            makeComponentFile(fixedCompName, compType,
                    sources, outFp);
            }
        }
    }
コード例 #2
0
std::string BuildConfig::getIncDepsFilePath() const
    {
    FilePath fp(getAnalysisPath(), FP_Dir);
    fp.appendFile(Project::getAnalysisIncDepsFilename());
    return fp;
    }