http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46516

--- Comment #13 from Tobias Burnus <burnus at gcc dot gnu.org> 2010-11-17 
15:32:34 UTC ---
Some debugging: While for libgfortran.spec and libgomp.spec the call to gcc.c's
find_a_file and thus to for_each_path is the same, the global variable
multilib_os_dir is NULL for libgfortran.spec and only later for libgomp.spec
(and thus too late) it is "../lib64"



It is set in set_multilib_dir, which is too late:

main (int argc, char **argv)
{
  ...
// Get default setting, OK so far:
  specs_file = find_a_file (&startfile_prefixes, "specs", R_OK, true);


// This reads the file we want:
    /* Process DRIVER_SELF_SPECS, adding any new options to the end
     of the command line.  */
  for (i = 0; i < ARRAY_SIZE (driver_self_specs); i++)
    do_self_spec (driver_self_specs[i]);


// but ../lib64 is only set at:
  /* Now that we have the switches and the specs, set
     the subdirectory based on the options.  */
  set_multilib_dir ();


Frankly, I have no idea how to solve this interdependence.

Reply via email to