This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v4] Mips support for PT_GNU_STACK


On Tue, 20 Aug 2019, Dragan Mladjenovic wrote:

> diff --git a/sysdeps/mips/configure.ac b/sysdeps/mips/configure.ac
> index bcbdaff..f0f89ae 100644
> --- a/sysdeps/mips/configure.ac
> +++ b/sysdeps/mips/configure.ac
> @@ -13,3 +13,31 @@ yes
>  if test x$libc_cv_mips_nan2008 = xyes; then
>    AC_DEFINE(HAVE_MIPS_NAN2008)
>  fi
> +
> +# Moved here to allow linux configure fragment to set minimum_kernel
> +# beforehand.

So you have an ordering problem between 
sysdeps/unix/sysv/linux/configure.ac and 
sysdeps/unix/sysv/linux/mips/configure.ac.  But the Linux-specific code

> +AC_CACHE_CHECK([checking whether the compiler must use executable stack],
> +				libc_cv_mips_force_execstack, [dnl
> +libc_cv_mips_force_execstack=no
> +case $os in linux*)
> +  if test x"$libc_mips_float" = xhard -a -n "$minimum_kernel"; then
> +     changequote(,)
> +     min_version=$((`echo "$minimum_kernel.0.0.0" | sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]*\).*/\1 \* 65536 + \2 \* 256 + \3/'`))
> +     changequote([,])
> +     if test $min_version -lt 264192; then

doesn't seem appropriate for sysdeps/mips/configure.ac at all; I think the 
ordering issue should be addressed another way.  I think that would be 
simply making sysdeps/unix/sysv/linux/mips/configure.ac handle the case of 
empty minimum_kernel as meaning an old kernel, with a comment saying that 
once the minimum kernel globally is 4.8 or later, all the code relating to 
forcing executable stacks can be removed.  (At that point, the person 
increasing the minimum kernel version will be updating 
sysdeps/unix/sysv/linux/mips/configure.ac anyway to remove the 
arch_minimum_kernel=4.5.0 setting for NaN2008.)

(With all the configure changes in sysdeps/unix/sysv/linux/mips/, I'd 
expect all the Makefile changes to be there as well.)

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]