11debfc3dSmrg /* Prototypes and data structures used for implementing functions for 21debfc3dSmrg finding files relative to GCC binaries. 3*8feb0f0bSmrg Copyright (C) 1992-2020 Free Software Foundation, Inc. 41debfc3dSmrg 51debfc3dSmrg This file is part of GCC. 61debfc3dSmrg 71debfc3dSmrg GCC is free software; you can redistribute it and/or modify it under 81debfc3dSmrg the terms of the GNU General Public License as published by the Free 91debfc3dSmrg Software Foundation; either version 3, or (at your option) any later 101debfc3dSmrg version. 111debfc3dSmrg 121debfc3dSmrg GCC is distributed in the hope that it will be useful, but WITHOUT ANY 131debfc3dSmrg WARRANTY; without even the implied warranty of MERCHANTABILITY or 141debfc3dSmrg FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 151debfc3dSmrg for more details. 161debfc3dSmrg 171debfc3dSmrg You should have received a copy of the GNU General Public License 181debfc3dSmrg along with GCC; see the file COPYING3. If not see 191debfc3dSmrg <http://www.gnu.org/licenses/>. */ 201debfc3dSmrg 211debfc3dSmrg #ifndef GCC_FILE_FIND_H 221debfc3dSmrg #define GCC_FILE_FIND_H 231debfc3dSmrg 241debfc3dSmrg /* Structure to hold all the directories in which to search for files to 251debfc3dSmrg execute. */ 261debfc3dSmrg 271debfc3dSmrg struct prefix_list 281debfc3dSmrg { 291debfc3dSmrg const char *prefix; /* String to prepend to the path. */ 301debfc3dSmrg struct prefix_list *next; /* Next in linked list. */ 311debfc3dSmrg }; 321debfc3dSmrg 331debfc3dSmrg struct path_prefix 341debfc3dSmrg { 351debfc3dSmrg struct prefix_list *plist; /* List of prefixes to try */ 361debfc3dSmrg int max_len; /* Max length of a prefix in PLIST */ 371debfc3dSmrg const char *name; /* Name of this list (used in config stuff) */ 381debfc3dSmrg }; 391debfc3dSmrg 401debfc3dSmrg extern void find_file_set_debug (bool); 411debfc3dSmrg extern char *find_a_file (struct path_prefix *, const char *, int); 421debfc3dSmrg extern void add_prefix (struct path_prefix *, const char *); 431debfc3dSmrg extern void add_prefix_begin (struct path_prefix *, const char *); 441debfc3dSmrg extern void prefix_from_env (const char *, struct path_prefix *); 451debfc3dSmrg extern void prefix_from_string (const char *, struct path_prefix *); 461debfc3dSmrg 471debfc3dSmrg #endif /* GCC_FILE_FIND_H */ 48