summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--eclass/flag-o-matic.eclass4
-rwxr-xr-xeclass/tests/flag-o-matic.sh6
2 files changed, 8 insertions, 2 deletions
diff --git a/eclass/flag-o-matic.eclass b/eclass/flag-o-matic.eclass
index 0aec22c83f2c..ebfc49bf30b7 100644
--- a/eclass/flag-o-matic.eclass
+++ b/eclass/flag-o-matic.eclass
@@ -474,8 +474,8 @@ test-flag-PROG() {
cmdline_extra+=(-xc)
;;
esac
- local test_in=${T}/test-flag-${comp}.${lang}
- local test_out=${T}/test-flag-${comp}.exe
+ local test_in=${T}/test-flag.${lang}
+ local test_out=${T}/test-flag.exe
printf "%s\n" "${in_src}" > "${test_in}" || return 1
diff --git a/eclass/tests/flag-o-matic.sh b/eclass/tests/flag-o-matic.sh
index 90eaf3a6ffb0..229dff52af94 100755
--- a/eclass/tests/flag-o-matic.sh
+++ b/eclass/tests/flag-o-matic.sh
@@ -139,6 +139,12 @@ out=$(test-flags-CC -O3)
[[ $? -eq 0 && ${out} == "-O3" ]]
ftend
+tbegin "test-flags-CC (valid flags, absolute path)"
+absolute_CC=$(type -P $(tc-getCC))
+out=$(CC=${absolute_CC} test-flags-CC -O3)
+[[ $? -eq 0 && ${out} == "-O3" ]]
+ftend
+
tbegin "test-flags-CC (invalid flags)"
out=$(test-flags-CC -finvalid-flag)
[[ $? -ne 0 && -z ${out} ]]