ld: Replace regexp with string match
Replace regexp with string match to workaround dejagnu 1.4.4 which complains: ERROR: bad switch "-fPIE": must be -all, -about, -indices, -inline, -expanded, -line, -linestop, -lineanchor, -nocase, -start, or -- * testsuite/ld-i386/i386.exp (undefined_weak): Replace regexp with string match. * testsuite/ld-x86-64/x86-64.exp (undefined_weak): Likewise.
This commit is contained in:
parent
28e6a46bcb
commit
074f606684
|
@ -1,3 +1,9 @@
|
||||||
|
2017-08-24 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
|
* testsuite/ld-i386/i386.exp (undefined_weak): Replace regexp
|
||||||
|
with string match.
|
||||||
|
* testsuite/ld-x86-64/x86-64.exp (undefined_weak): Likewise.
|
||||||
|
|
||||||
2017-08-24 H.J. Lu <hongjiu.lu@intel.com>
|
2017-08-24 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
* testsuite/ld-x86-64/x86-64.exp: Run pr22001-1b on x32.
|
* testsuite/ld-x86-64/x86-64.exp: Run pr22001-1b on x32.
|
||||||
|
|
|
@ -468,8 +468,8 @@ proc undefined_weak {cflags ldflags} {
|
||||||
set testname "$testname ($cflags $ldflags)"
|
set testname "$testname ($cflags $ldflags)"
|
||||||
}
|
}
|
||||||
|
|
||||||
if { [ regexp "\-fPIE" $cflags]
|
if { [string match "*-fPIE*" $cflags]
|
||||||
&& ![ regexp "\-z nodynamic-undefined-weak" $ldflags] } {
|
&& ![string match "*-z nodynamic-undefined-weak*" $ldflags] } {
|
||||||
set weak_symbol "Weak defined"
|
set weak_symbol "Weak defined"
|
||||||
} else {
|
} else {
|
||||||
set weak_symbol "Weak undefined"
|
set weak_symbol "Weak undefined"
|
||||||
|
|
|
@ -577,8 +577,8 @@ proc undefined_weak {cflags ldflags} {
|
||||||
set testname "$testname ($cflags $ldflags)"
|
set testname "$testname ($cflags $ldflags)"
|
||||||
}
|
}
|
||||||
|
|
||||||
if { [ regexp "\-fPIE" $cflags]
|
if { [string match "*-fPIE*" $cflags]
|
||||||
&& ![ regexp "nodynamic-undefined-weak" $ldflags] } {
|
&& ![string match "*nodynamic-undefined-weak*" $ldflags] } {
|
||||||
set weak_symbol "Weak defined"
|
set weak_symbol "Weak defined"
|
||||||
} else {
|
} else {
|
||||||
set weak_symbol "Weak undefined"
|
set weak_symbol "Weak undefined"
|
||||||
|
|
Loading…
Reference in New Issue