diff mbox series

[3/5] package/openmpi: enable mpi compiler wrapper scripts

Message ID 20230207220941.58066-3-ju.o@free.fr
State Changes Requested
Headers show
Series [1/5] DEVELOPERS: add Julien Olivain for package/openmpi | expand

Commit Message

Julien Olivain Feb. 7, 2023, 10:09 p.m. UTC
openmpi normally includes compiler wrapper binary programs (e.g. mpicc,
mpicxx, etc...). Those programs are inconvenient when cross compiling.
Those target binary wrappers are useless in Buildroot, as the target
root filesystem does not include compilers. For cross compilation,
openmpi also ships Perl scripts providing a subset of those functions.
With those compiler wrappers, openmpi programs can now be cross
compiled properly in Buildroot. This patch enables those wrappers.

Signed-off-by: Julien Olivain <ju.o@free.fr>
---
 package/openmpi/openmpi.mk | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Thomas Petazzoni Feb. 21, 2023, 9:10 a.m. UTC | #1
Hello Julien,

On Tue,  7 Feb 2023 23:09:39 +0100
Julien Olivain <ju.o@free.fr> wrote:

> openmpi normally includes compiler wrapper binary programs (e.g. mpicc,
> mpicxx, etc...). Those programs are inconvenient when cross compiling.
> Those target binary wrappers are useless in Buildroot, as the target
> root filesystem does not include compilers. For cross compilation,
> openmpi also ships Perl scripts providing a subset of those functions.
> With those compiler wrappers, openmpi programs can now be cross
> compiled properly in Buildroot. This patch enables those wrappers.
> 
> Signed-off-by: Julien Olivain <ju.o@free.fr>
> ---
>  package/openmpi/openmpi.mk | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/package/openmpi/openmpi.mk b/package/openmpi/openmpi.mk
> index f14b55ced5..e6f5cd0250 100644
> --- a/package/openmpi/openmpi.mk
> +++ b/package/openmpi/openmpi.mk
> @@ -17,7 +17,9 @@ OPENMPI_INSTALL_STAGING = YES
>  # found. This makes the configuration fail. See:
>  # https://github.com/open-mpi/ompi/blob/v4.1.4/config/ompi_check_ime.m4#L35
>  # Disable explicitly to avoid the issue.
> -OPENMPI_CONF_OPTS = --without-ime
> +OPENMPI_CONF_OPTS = \
> +	--enable-script-wrapper-compilers \

So if I look at your PATCH 4/5, this means that "mpicc" is one of those
wrapper script, installed in $(STAGING_DIR), but meant to be executed
on the host?

As you're saying it's written in Perl, did you test it with a minimal
Fedora installation, to see if it has requirements beyond the base Perl
installation? (compared to Debian/Ubuntu, Fedora has a much more
fine-grained packaging of basic Perl modules, this recently lead to a
small amount of additional checks in dependencies.sh, see
https://gitlab.com/buildroot.org/buildroot/-/commits/master/support/dependencies/dependencies.sh).

Best regards,

Thomas
Thomas Petazzoni Aug. 10, 2023, 9:16 p.m. UTC | #2
Hello Julien,

Unless I missed it, you never replied to the feedback I gave on PATCH
3/5 and 4/5 in this series, so I've marked patches 3/5, 4/5 and 5/5 as
Changes Requested. Patches 1/5 and 2/5 had already been applied a while
ago.

Best regards,

Thomas Petazzoni

On Tue,  7 Feb 2023 23:09:39 +0100
Julien Olivain <ju.o@free.fr> wrote:

> openmpi normally includes compiler wrapper binary programs (e.g. mpicc,
> mpicxx, etc...). Those programs are inconvenient when cross compiling.
> Those target binary wrappers are useless in Buildroot, as the target
> root filesystem does not include compilers. For cross compilation,
> openmpi also ships Perl scripts providing a subset of those functions.
> With those compiler wrappers, openmpi programs can now be cross
> compiled properly in Buildroot. This patch enables those wrappers.
> 
> Signed-off-by: Julien Olivain <ju.o@free.fr>
> ---
>  package/openmpi/openmpi.mk | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/package/openmpi/openmpi.mk b/package/openmpi/openmpi.mk
> index f14b55ced5..e6f5cd0250 100644
> --- a/package/openmpi/openmpi.mk
> +++ b/package/openmpi/openmpi.mk
> @@ -17,7 +17,9 @@ OPENMPI_INSTALL_STAGING = YES
>  # found. This makes the configuration fail. See:
>  # https://github.com/open-mpi/ompi/blob/v4.1.4/config/ompi_check_ime.m4#L35
>  # Disable explicitly to avoid the issue.
> -OPENMPI_CONF_OPTS = --without-ime
> +OPENMPI_CONF_OPTS = \
> +	--enable-script-wrapper-compilers \
> +	--without-ime
>  
>  # Enabling Fortran support requires pre-seeding the configure script
>  # with various values that cannot be guessed, so we provide cache
diff mbox series

Patch

diff --git a/package/openmpi/openmpi.mk b/package/openmpi/openmpi.mk
index f14b55ced5..e6f5cd0250 100644
--- a/package/openmpi/openmpi.mk
+++ b/package/openmpi/openmpi.mk
@@ -17,7 +17,9 @@  OPENMPI_INSTALL_STAGING = YES
 # found. This makes the configuration fail. See:
 # https://github.com/open-mpi/ompi/blob/v4.1.4/config/ompi_check_ime.m4#L35
 # Disable explicitly to avoid the issue.
-OPENMPI_CONF_OPTS = --without-ime
+OPENMPI_CONF_OPTS = \
+	--enable-script-wrapper-compilers \
+	--without-ime
 
 # Enabling Fortran support requires pre-seeding the configure script
 # with various values that cannot be guessed, so we provide cache