From 470672abaafa1c83bba7d6b1972c17096eaa9c65 Mon Sep 17 00:00:00 2001 From: aoliva Date: Tue, 31 Jan 2017 01:01:32 +0000 Subject: [PATCH] libcc1: return absolute filename from make search_dir for libcc1/ChangeLog * findcomp.cc: Include system.h. (search_dir): Return absolute filename. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245050 138bc75d-0d04-0410-961f-82ee72b054a4 --- libcc1/ChangeLog | 3 +++ libcc1/findcomp.cc | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/libcc1/ChangeLog b/libcc1/ChangeLog index ef1577b2d29..9a943148a3b 100644 --- a/libcc1/ChangeLog +++ b/libcc1/ChangeLog @@ -1,5 +1,8 @@ 2017-01-30 Jan Kratochvil + * findcomp.cc: Include system.h. + (search_dir): Return absolute filename. + * libcc1.cc (libcc1): Add class compiler with field compilerp, class compiler_triplet_regexp and class compiler_driver_filename. diff --git a/libcc1/findcomp.cc b/libcc1/findcomp.cc index bf9a14a9fe9..1fdec12dc12 100644 --- a/libcc1/findcomp.cc +++ b/libcc1/findcomp.cc @@ -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 ®exp, const std::string &dir, std::string *result) { if (regexec (®exp, filename, 0, NULL, 0) == 0) { - *result = filename; + *result = dir + DIR_SEPARATOR + filename; return true; } } -- 2.11.4.GIT