public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [patch] disable libmpx x32 multilib builds
@ 2015-03-11 14:38 Matthias Klose
  2015-03-11 15:59 ` H.J. Lu
  0 siblings, 1 reply; 4+ messages in thread
From: Matthias Klose @ 2015-03-11 14:38 UTC (permalink / raw)
  To: gcc-patches

current trunk fails to build on x86*-linux, when configured for x32 multilibs
because libmpx doesn't support these. Disable them.

ok for the trunk?

	* Disable libmpx x32 multilib builds.

--- a/config-ml.in
+++ b/config-ml.in
@@ -102,6 +102,7 @@
 Makefile=${ac_file-Makefile}
 ml_config_shell=${CONFIG_SHELL-/bin/sh}
 ml_realsrcdir=${srcdir}
+ml_srcbase=`basename $ml_realsrcdir`

 # Scan all the arguments and set all the ones we need.

@@ -220,6 +221,10 @@
   if [ "${dir}" = "." ]; then
     true
   else
+    # libmpx is not supported on x32
+    if [ "${ml_srcbase}-${dir}" = libmpx-x32 ]; then
+      continue
+    fi
     if [ -z "${multidirs}" ]; then
       multidirs="${dir}"
     else

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [patch] disable libmpx x32 multilib builds
  2015-03-11 14:38 [patch] disable libmpx x32 multilib builds Matthias Klose
@ 2015-03-11 15:59 ` H.J. Lu
  2015-03-11 16:11   ` Ilya Enkovich
  0 siblings, 1 reply; 4+ messages in thread
From: H.J. Lu @ 2015-03-11 15:59 UTC (permalink / raw)
  To: Matthias Klose; +Cc: gcc-patches

On Wed, Mar 11, 2015 at 7:37 AM, Matthias Klose <doko@ubuntu.com> wrote:
> current trunk fails to build on x86*-linux, when configured for x32 multilibs
> because libmpx doesn't support these. Disable them.
>
> ok for the trunk?
>
>         * Disable libmpx x32 multilib builds.
>
> --- a/config-ml.in
> +++ b/config-ml.in
> @@ -102,6 +102,7 @@
>  Makefile=${ac_file-Makefile}
>  ml_config_shell=${CONFIG_SHELL-/bin/sh}
>  ml_realsrcdir=${srcdir}
> +ml_srcbase=`basename $ml_realsrcdir`
>
>  # Scan all the arguments and set all the ones we need.
>
> @@ -220,6 +221,10 @@
>    if [ "${dir}" = "." ]; then
>      true
>    else
> +    # libmpx is not supported on x32
> +    if [ "${ml_srcbase}-${dir}" = libmpx-x32 ]; then
> +      continue
> +    fi
>      if [ -z "${multidirs}" ]; then
>        multidirs="${dir}"
>      else

This is incorrect.  Ilya and I are working on a proper fix.

-- 
H.J.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [patch] disable libmpx x32 multilib builds
  2015-03-11 15:59 ` H.J. Lu
@ 2015-03-11 16:11   ` Ilya Enkovich
  2015-03-12 12:17     ` Ilya Enkovich
  0 siblings, 1 reply; 4+ messages in thread
From: Ilya Enkovich @ 2015-03-11 16:11 UTC (permalink / raw)
  To: H.J. Lu; +Cc: Matthias Klose, gcc-patches

2015-03-11 18:59 GMT+03:00 H.J. Lu <hjl.tools@gmail.com>:
> On Wed, Mar 11, 2015 at 7:37 AM, Matthias Klose <doko@ubuntu.com> wrote:
>> current trunk fails to build on x86*-linux, when configured for x32 multilibs
>> because libmpx doesn't support these. Disable them.
>>
>> ok for the trunk?
>>
>>         * Disable libmpx x32 multilib builds.
>>
>> --- a/config-ml.in
>> +++ b/config-ml.in
>> @@ -102,6 +102,7 @@
>>  Makefile=${ac_file-Makefile}
>>  ml_config_shell=${CONFIG_SHELL-/bin/sh}
>>  ml_realsrcdir=${srcdir}
>> +ml_srcbase=`basename $ml_realsrcdir`
>>
>>  # Scan all the arguments and set all the ones we need.
>>
>> @@ -220,6 +221,10 @@
>>    if [ "${dir}" = "." ]; then
>>      true
>>    else
>> +    # libmpx is not supported on x32
>> +    if [ "${ml_srcbase}-${dir}" = libmpx-x32 ]; then
>> +      continue
>> +    fi
>>      if [ -z "${multidirs}" ]; then
>>        multidirs="${dir}"
>>      else
>
> This is incorrect.  Ilya and I are working on a proper fix.
>
> --
> H.J.

Current libmpx configure has a check for x32 but it doesn't work due
to square brackets removed from the test by autoconf. Will test this
patch:

diff --git a/libmpx/configure.ac b/libmpx/configure.ac
index 4669525..fe0d3f2 100644
--- a/libmpx/configure.ac
+++ b/libmpx/configure.ac
@@ -28,7 +28,7 @@ GCC_LIBSTDCXX_RAW_CXX_FLAGS
 # See if supported.
 unset LIBMPX_SUPPORTED
 AC_MSG_CHECKING([for target support for Intel MPX runtime library])
-echo "int i[sizeof (void *) == 4 ? 1 : -1] = { __x86_64__ };" > conftest.c
+echo "int i[[sizeof (void *) == 4 ? 1 : -1]] = { __x86_64__ };" > conftest.c
 if AC_TRY_COMMAND([${CC} ${CFLAGS} -c -o conftest.o conftest.c
1>&AS_MESSAGE_LOG_FD])
 then
     LIBMPX_SUPPORTED=no


Thanks,
Ilya

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [patch] disable libmpx x32 multilib builds
  2015-03-11 16:11   ` Ilya Enkovich
@ 2015-03-12 12:17     ` Ilya Enkovich
  0 siblings, 0 replies; 4+ messages in thread
From: Ilya Enkovich @ 2015-03-12 12:17 UTC (permalink / raw)
  To: H.J. Lu; +Cc: Matthias Klose, gcc-patches

On 11 Mar 19:11, Ilya Enkovich wrote:
> 2015-03-11 18:59 GMT+03:00 H.J. Lu <hjl.tools@gmail.com>:
> > On Wed, Mar 11, 2015 at 7:37 AM, Matthias Klose <doko@ubuntu.com> wrote:
> >> current trunk fails to build on x86*-linux, when configured for x32 multilibs
> >> because libmpx doesn't support these. Disable them.
> >>
> >> ok for the trunk?
> >>
> >>         * Disable libmpx x32 multilib builds.
> >>
> >> --- a/config-ml.in
> >> +++ b/config-ml.in
> >> @@ -102,6 +102,7 @@
> >>  Makefile=${ac_file-Makefile}
> >>  ml_config_shell=${CONFIG_SHELL-/bin/sh}
> >>  ml_realsrcdir=${srcdir}
> >> +ml_srcbase=`basename $ml_realsrcdir`
> >>
> >>  # Scan all the arguments and set all the ones we need.
> >>
> >> @@ -220,6 +221,10 @@
> >>    if [ "${dir}" = "." ]; then
> >>      true
> >>    else
> >> +    # libmpx is not supported on x32
> >> +    if [ "${ml_srcbase}-${dir}" = libmpx-x32 ]; then
> >> +      continue
> >> +    fi
> >>      if [ -z "${multidirs}" ]; then
> >>        multidirs="${dir}"
> >>      else
> >
> > This is incorrect.  Ilya and I are working on a proper fix.
> >
> > --
> > H.J.
> 
> Current libmpx configure has a check for x32 but it doesn't work due
> to square brackets removed from the test by autoconf. Will test this
> patch:
> 
> diff --git a/libmpx/configure.ac b/libmpx/configure.ac
> index 4669525..fe0d3f2 100644
> --- a/libmpx/configure.ac
> +++ b/libmpx/configure.ac
> @@ -28,7 +28,7 @@ GCC_LIBSTDCXX_RAW_CXX_FLAGS
>  # See if supported.
>  unset LIBMPX_SUPPORTED
>  AC_MSG_CHECKING([for target support for Intel MPX runtime library])
> -echo "int i[sizeof (void *) == 4 ? 1 : -1] = { __x86_64__ };" > conftest.c
> +echo "int i[[sizeof (void *) == 4 ? 1 : -1]] = { __x86_64__ };" > conftest.c
>  if AC_TRY_COMMAND([${CC} ${CFLAGS} -c -o conftest.o conftest.c
> 1>&AS_MESSAGE_LOG_FD])
>  then
>      LIBMPX_SUPPORTED=no
> 
> 
> Thanks,
> Ilya

Successfully bootstrapped on on x86_64-unknown-linux-gnu with '--enable-libmpx --with-multilib-list=m32,m64,mx32'.  Applied to trunk.

Thanks,
Ilya
--
2015-03-12  Ilya Enkovich  <ilya.enkovich@intel.com>

	PR other/65384
	* configure.ac: Fix x32 test.
	* configure: Regenerate.


diff --git a/libmpx/configure.ac b/libmpx/configure.ac
index 4669525..fe0d3f2 100644
--- a/libmpx/configure.ac
+++ b/libmpx/configure.ac
@@ -28,7 +28,7 @@ GCC_LIBSTDCXX_RAW_CXX_FLAGS
 # See if supported.
 unset LIBMPX_SUPPORTED
 AC_MSG_CHECKING([for target support for Intel MPX runtime library])
-echo "int i[sizeof (void *) == 4 ? 1 : -1] = { __x86_64__ };" > conftest.c
+echo "int i[[sizeof (void *) == 4 ? 1 : -1]] = { __x86_64__ };" > conftest.c
 if AC_TRY_COMMAND([${CC} ${CFLAGS} -c -o conftest.o conftest.c 1>&AS_MESSAGE_LOG_FD])
 then
     LIBMPX_SUPPORTED=no

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-03-12 12:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-11 14:38 [patch] disable libmpx x32 multilib builds Matthias Klose
2015-03-11 15:59 ` H.J. Lu
2015-03-11 16:11   ` Ilya Enkovich
2015-03-12 12:17     ` Ilya Enkovich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).