Skip to content

Commit 324e8be

Browse files
committed
Fix --with-cmodel option
When passed with `--without-cmodel`, cmodel will get value `no` which is unexpected. Signed-off-by: demin.han <[email protected]>
1 parent f24f9db commit 324e8be

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

configure

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4177,10 +4177,13 @@ fi
41774177
if test ${with_cmodel+y}
41784178
then :
41794179
withval=$with_cmodel;
4180+
else $as_nop
4181+
with_cmodel=no
4182+
41804183
fi
41814184
41824185
4183-
if test "x$with_cmodel" != x
4186+
if test "x$with_cmodel" != xno
41844187
then :
41854188
cmodel=-mcmodel=$with_cmodel
41864189

configure.ac

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,10 +177,10 @@ AC_ARG_WITH(cmodel,
177177
[AS_HELP_STRING([--with-cmodel],
178178
[Select the code model to use when building libc and libgcc @<:@--with-cmodel=medlow@:>@])],
179179
[],
180-
[]
180+
[with_cmodel=no]
181181
)
182182

183-
AS_IF([test "x$with_cmodel" != x],
183+
AS_IF([test "x$with_cmodel" != xno],
184184
[AC_SUBST(cmodel, -mcmodel=$with_cmodel)],
185185
[AC_SUBST(cmodel, -mcmodel=medlow)])
186186

0 commit comments

Comments
 (0)