From 5fdf097f42dfeacda1d81387933ef20acedb1fc7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Andriot?= Date: Mon, 18 Mar 2019 20:57:03 +0100 Subject: RPM: update build scripts for TDE R14.0.6 --- redhat/main/tdebindings/tdebindings-14.0.0.spec | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'redhat/main/tdebindings/tdebindings-14.0.0.spec') diff --git a/redhat/main/tdebindings/tdebindings-14.0.0.spec b/redhat/main/tdebindings/tdebindings-14.0.0.spec index 4fb236edc..a70c39b3d 100644 --- a/redhat/main/tdebindings/tdebindings-14.0.0.spec +++ b/redhat/main/tdebindings/tdebindings-14.0.0.spec @@ -190,14 +190,16 @@ BuildRequires: rubypick %if "%{%ruby_archdir}" != "" %define ruby_arch %{?ruby_archdir} %else -%{!?ruby_arch: %define ruby_arch %(ruby -rrbconfig -e 'puts Config::CONFIG["archdir"]')} -%{!?ruby_arch: %define ruby_arch %(ruby -rrbconfig -e 'puts RbConfig::CONFIG["archdir"]')} +%{!?ruby_arch: %define ruby_arch %(ruby -rrbconfig -e 'puts Config::CONFIG["archdir"]' || ruby -rrbconfig -e 'puts RbConfig::CONFIG["archdir"]')} %endif %endif %endif %if 0%{?rhel} == 5 || 0%{?rhel} == 6 %define ruby_arch %(ruby -rrbconfig -e 'puts Config::CONFIG["archdir"]') %endif +%if 0%{?pclinuxos} +%define ruby_arch %(ruby -rrbconfig -e 'puts RbConfig::CONFIG["archdir"]') +%endif %if "%{?ruby_libdir}" != "" %define ruby_rubylibdir %{?ruby_libdir} @@ -205,7 +207,7 @@ BuildRequires: rubypick %if "%{?rb_libdir}" != "" %define ruby_rubylibdir %{?rb_libdir} %else -%{!?ruby_rubylibdir: %define ruby_rubylibdir %(ruby -rrbconfig -e 'puts Config::CONFIG["rubylibdir"]')} +%{!?ruby_rubylibdir: %define ruby_rubylibdir %(ruby -rrbconfig -e 'puts Config::CONFIG["rubylibdir"]' || ruby -rrbconfig -e 'puts RbConfig::CONFIG["rubylibdir"]')} %endif %endif @@ -993,6 +995,14 @@ This package contains the development files for the TDE bindings. exit 1 %endif +%if "%{?ruby_rubylibdir}" == "" +exit 2 +%endif + +%if "%{?ruby_arch}" == "" +exit 3 +%endif + # [tdebindings] Function 'rb_frame_this_func' does not exist in RHEL4/5 %if 0%{?rhel} >= 4 && 0%{?rhel} <= 5 %__sed -i "qtruby/rubylib/qtruby/Qt.cpp" \ -- cgit v1.2.1