Skip to content

Commit e9e9750

Browse files
author
Neil Conway
committed
With the native compiler on Unixware, disable optimization if
--enable-debug is used, to avoid complaints about debugging and optimization being mutually exclusive. Patch from Stefan Kaltenbrunner.
1 parent ae1b7e2 commit e9e9750

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/template/unixware

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,14 @@ void g(void){
1212
}
1313
__EOF__
1414

15+
# Debugging and optimization are mutually exclusive
16+
if test "$enable_debug" != yes; then
17+
CFLAGS="-O"
18+
fi
1519
if $CC -c -O -Kinline conftest.c >conftest.err 2>&1; then
16-
CFLAGS="-O -Kinline"
20+
CFLAGS="$CFLAGS -Kinline"
1721
else
18-
CFLAGS="-O -Kinline,no_host"
22+
CFLAGS="$CFLAGS -Kinline,no_host"
1923
fi
2024
rm -f conftest.*
2125

0 commit comments

Comments
 (0)