/* *Checkallpreviouslyfoundincludefilesforapaththat *hasalreadybeenexpanded.
*/ for (ip = inclist; ip->i_file; ip++) if (strcmp(ip->i_incstring, include) == 0)
{
found = TRUE; break;
}
/* *Ifthepathwassurroundedby""orisanabsolutepath, *thenchecktheexactpathprovided.
*/ // FIXME: creates duplicates in the dependency files if absolute paths are // given, which certainly is not the intended behavior. Also it slows down // makedepend performance considerably. // if (!found && (dot || *include == '/')) { // // if ((exists_path(incCollection, include)) && stat(include, &st) == 0 && !( st.st_mode & S_IFDIR)) { // ip = newinclude(include, include); // found = TRUE; // } // else if (show_where_not) // warning1("\tnot in %s\n", include); // }
/* *Seeifthisincludefileisinthedirectoryofthe *filebeingcompiled.
*/ if (!found) { for (p=file+strlen(file); p>file; p--) if (*p == '/') break; if (p == file)
{ if(strlen(include) >= BUFSIZ )
{
fatalerr("include filename too long \"%s\"\n", include);
} else
{
strcpy(path, include);
}
} else
{ int partial = p - file;
size_t inc_len = strlen(include); if(inc_len + partial >= BUFSIZ )
{
fatalerr("include filename too long \"%s\"\n", include);
} else
{
memcpy(path, file, partial);
memcpy(path + partial, include, inc_len);
path[partial + inc_len] = 0;
}
}
remove_dotdot(path); if ((exists_path(incCollection, path)) && stat(path, &st) == 0 && !( st.st_mode & S_IFDIR)) {
ip = newinclude(path, include);
found = TRUE;
} elseif (show_where_not)
warning1("\tnot in %s\n", path);
}
/* *Checktheincludedirectoriesspecified.(standardincludedir *shouldbeattheend.)
*/ if (!found) for (pp = includedirs; *pp; pp++) {
SAL_WNODEPRECATED_DECLARATIONS_PUSH /* sprintf (macOS 13 SDK) */
sprintf(path, "%s/%s", *pp, include);
SAL_WNODEPRECATED_DECLARATIONS_POP
remove_dotdot(path); if ((exists_path(incCollection, path)) && stat(path, &st) == 0 && !(st.st_mode & S_IFDIR)) {
ip = newinclude(path, include);
found = TRUE; break;
} elseif (show_where_not)
warning1("\tnot in %s\n", path);
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.