Whamcloud - gitweb
LU-15521 spec: fix more bare words error with rpm 4.16 35/47835/3
authorJian Yu <yujian@whamcloud.com>
Wed, 29 Jun 2022 21:37:30 +0000 (14:37 -0700)
committerOleg Drokin <green@whamcloud.com>
Fri, 15 Jul 2022 04:58:25 +0000 (04:58 +0000)
This patch fixes more bare words errors and extra tokens
warnings with rpm 4.16.

Lustre-change: https://review.whamcloud.com/47833
Lustre-commit: 81530fe44c6b8d8819b8e70ea99ef7014c23a05b

Test-Parameters: trivial

Change-Id: Ic40b5763d1cb362d5aa77b06e9a5768b2abbc708
Fixes: 597a6bf9e085 ("LU-15521 spec: fix bare words error with rpm 4.16")
Signed-off-by: Jian Yu <yujian@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/47835
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Yang Sheng <ys@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre.spec.in

index 8118525..87effdf 100644 (file)
@@ -368,8 +368,10 @@ BuildRequires: openmpi-devel
 %else
 BuildRequires: openmpi2-devel
 %endif
-%endif # openmpi
-%endif # mpi
+# openmpi
+%endif
+# mpi
+%endif
 
 %description tests
 This package contains a set of test binaries and scripts that are intended
@@ -486,13 +488,14 @@ fi
 %endif
 
 %if %{with mpi}
-%if %{mpi_name} == "mpich"
+%if "%{mpi_name}" == "mpich"
 %{?_mpich_load}
 %endif
-%if %{mpi_name} == "openmpi"
+%if "%{mpi_name}" == "openmpi"
 %{?_openmpi_load}
 %endif
-%endif # mpi
+# mpi
+%endif
 
 %if %{with mofed}
        o2ib_path=$(find /usr/src/ofa_kernel/ -type d -name ofed_scripts | xargs dirname)
@@ -537,24 +540,26 @@ fi
 make %{?_smp_mflags} -s %{?make_args}
 
 %if %{with mpi}
-%if %{mpi_name} == "mpich"
+%if "%{mpi_name}" == "mpich"
 %{?_mpich_unload}
 %endif
-%if %{mpi_name} == "openmpi"
+%if "%{mpi_name}" == "openmpi"
 %{?_openmpi_unload}
 %endif
-%endif # mpi
+# mpi
+%endif
 
 %install
 
 %if %{with mpi}
-%if %{mpi_name} == "mpich"
+%if "%{mpi_name}" == "mpich"
 %{?_mpich_load}
 %endif
-%if %{mpi_name} == "openmpi"
+%if "%{mpi_name}" == "openmpi"
 %{?_openmpi_load}
 %endif
-%endif # mpi
+# mpi
+%endif
 
 make install DESTDIR=$RPM_BUILD_ROOT
 
@@ -666,13 +671,14 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/liblustreapi.la
 %if %{with lustre_tests}
 :> lustre-tests.files
 %if %{with mpi}
-%if %{mpi_name} == "mpich"
+%if "%{mpi_name}" == "mpich"
 %{?_mpich_load}
 %endif
-%if %{mpi_name} == "openmpi"
+%if "%{mpi_name}" == "openmpi"
 %{?_openmpi_load}
 %endif
-%endif # mpi
+# mpi
+%endif
 echo '%{_libdir}/lustre/tests/*' >>lustre-tests.files
 echo '%{_bindir}/mcreate' >>lustre-tests.files
 echo '%{_bindir}/munlink' >>lustre-tests.files