From abf81c3add28528119ed7770a21d67098ddf2c27 Mon Sep 17 00:00:00 2001 From: Huawei LI Date: Fri, 11 Nov 2022 13:50:26 +0800 Subject: build: fix lib install dir and add vat2 lib install when build rpm. Type: fix Signed-off-by: Huawei LI Change-Id: I5ac557756ff2b3de13ce328a27ffdd289ab3173e --- extras/rpm/vpp.spec | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) (limited to 'extras') diff --git a/extras/rpm/vpp.spec b/extras/rpm/vpp.spec index 4658aa99fc1..2bd16ca9e25 100644 --- a/extras/rpm/vpp.spec +++ b/extras/rpm/vpp.spec @@ -271,18 +271,25 @@ mkdir -p -m755 %{buildroot}%{_localstatedir}/log/vpp # # vpp-plugins # -mkdir -p -m755 %{buildroot}/usr/lib/vpp_plugins -mkdir -p -m755 %{buildroot}/usr/lib/vpp_api_test_plugins +mkdir -p -m755 %{buildroot}/usr/%{_lib}/vpp_plugins +mkdir -p -m755 %{buildroot}/usr/%{_lib}/vpp_api_test_plugins +mkdir -p -m755 %{buildroot}/usr/%{_lib}/vat2_plugins for file in $(cd %{_mu_build_dir}/%{_vpp_install_dir}/vpp/%{_lib}/vpp_plugins && find -type f -print) do install -p -m 755 %{_mu_build_dir}/%{_vpp_install_dir}/vpp/%{_lib}/vpp_plugins/$file \ - %{buildroot}/usr/lib/vpp_plugins/$file + %{buildroot}/usr/%{_lib}/vpp_plugins/$file done for file in $(cd %{_mu_build_dir}/%{_vpp_install_dir}/vpp/%{_lib}/vpp_api_test_plugins && find -type f -print) do install -p -m 755 %{_mu_build_dir}/%{_vpp_install_dir}/vpp/%{_lib}/vpp_api_test_plugins/$file \ - %{buildroot}/usr/lib/vpp_api_test_plugins/$file + %{buildroot}/usr/%{_lib}/vpp_api_test_plugins/$file +done + +for file in $(cd %{_mu_build_dir}/%{_vpp_install_dir}/vpp/%{_lib}/vat2_plugins && find -type f -print) +do + install -p -m 755 %{_mu_build_dir}/%{_vpp_install_dir}/vpp/%{_lib}/vat2_plugins/$file \ + %{buildroot}/usr/%{_lib}/vat2_plugins/$file done for file in $(find %{_mu_build_dir}/%{_vpp_install_dir}/vpp/share/vpp/api/plugins -type f -name '*.api.json' -print ) @@ -368,6 +375,7 @@ fi %global __requires_exclude_from %{_libdir}/librte_pmd_mlx[45]_glue\\.so.*$ %exclude %{_libdir}/vpp_plugins %exclude %{_libdir}/vpp_api_test_plugins +%exclude %{_libdir}/vat2_plugins %{_libdir}/* /usr/share/vpp/api/* @@ -396,6 +404,7 @@ fi %files plugins %defattr(-,bin,bin) -/usr/lib/vpp_plugins/* -/usr/lib/vpp_api_test_plugins/* +/usr/%{_lib}/vpp_plugins/* +/usr/%{_lib}/vpp_api_test_plugins/* +/usr/%{_lib}/vat2_plugins/* /usr/share/vpp/api/* -- cgit 1.2.3-korg