]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libcc1/findcomp.cc
Update copyright years.
[thirdparty/gcc.git] / libcc1 / findcomp.cc
index f02b1dfe425448d5232b22492143621ff5a29ec3..87d5fd11382781e88a92231df1277121b09ce399 100644 (file)
@@ -1,5 +1,5 @@
 /* Find the correct compiler.
-   Copyright (C) 2014 Free Software Foundation, Inc.
+   Copyright (C) 2014-2024 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -25,6 +25,7 @@ along with GCC; see the file COPYING3.  If not see
 #include "libiberty.h"
 #include "xregex.h"
 #include "findcomp.hh"
+#include "system.h"
 
 class scanner
 {
@@ -68,7 +69,7 @@ search_dir (const regex_t &regexp, const std::string &dir, std::string *result)
     {
       if (regexec (&regexp, filename, 0, NULL, 0) == 0)
        {
-         *result = filename;
+         *result = dir + DIR_SEPARATOR + filename;
          return true;
        }
     }