[NLopt/el5] moved package-specific macros to the corresponding subpackage
Björn Esser
besser82 at fedoraproject.org
Fri Dec 20 13:39:31 UTC 2013
commit 76381eef9425b323ad8471c12df7c279047ca881
Author: Björn Esser <bjoern.esser at gmail.com>
Date: Fri Dec 20 14:38:52 2013 +0100
moved package-specific macros to the corresponding subpackage
NLopt.spec | 36 ++++++++++++++----------------------
1 files changed, 14 insertions(+), 22 deletions(-)
---
diff --git a/NLopt.spec b/NLopt.spec
index 275a35f..61c728d 100644
--- a/NLopt.spec
+++ b/NLopt.spec
@@ -12,30 +12,8 @@
# Get a lowercase name for virtual provides.
%global lc_name %(n=%{name};echo ${n,,})
-# Needed stuff for Octave.
-%global octpkg %{name}
-
-%if 0%{?fedora} || 0%{?rhel} >= 7
# We don't want provides for libs in private dirs.
%global __provides_exclude_from ^%{python2_sitearch}/.*\\.so
-%else
-# These are not defined on <= el6.
-#
-# Octave binary API provided
-%global octave_api %(octave-config -p API_VERSION || echo 0)}
-
-# Octave Package Directories
-%global octshareprefix %{_datadir}/octave
-%global octprefix %{octshareprefix}/packages
-%global octarchprefix %{_libdir}/octave/packages
-
-%global octpkgdir %{octshareprefix}/%{octpkg}-%{version}
-%global octpkglibdir %{octarchprefix}/%{octpkg}-%{version}
-%endif
-
-# Needed stuff for Guile.
-%{!?el5:%global guile_pkgconf %(pkg-config --list-all | grep guile | sed -e 's! .*$!!g')}
-%{!?el5:%global guile_sitedir %(pkg-config --variable=sitedir %{guile_pkgconf})}
Name: NLopt
Version: 2.4
@@ -134,6 +112,10 @@ This package contains documentation files for %{name}.
%if 0%{?fedora} || 0%{?rhel} >= 6
%package -n guile-%{name}
+# For compatibility with RHEL <= 6.
+%{!?guile_pkgconf:%global guile_pkgconf %(pkg-config --list-all | grep guile | sed -e 's! .*$!!g')}
+%{!?guile_sitedir:%global guile_sitedir %(pkg-config --variable=sitedir %{guile_pkgconf})}
+
Summary: Guile bindings for %{name}
Requires: guile%{?_isa}
@@ -162,6 +144,15 @@ of Guile bindings for %{name}.
%package -n octave-%{name}
+%global octpkg %{name}
+# For compatibility with RHEL <= 6.
+%{!?octave_api: %global octave_api %(octave-config -p API_VERSION || echo 0)}
+%{!?octshareprefix: %global octshareprefix %{_datadir}/octave}
+%{!?octprefix: %global octprefix %{octshareprefix}/packages}
+%{!?octarchprefix: %global octarchprefix %{_libdir}/octave/packages}
+%{!?octpkgdir: %global octpkgdir %{octshareprefix}/%{octpkg}-%{version}}
+%{!?octpkglibdir: %global octpkglibdir %{octarchprefix}/%{octpkg}-%{version}}
+
Summary: Octave bindings for %{name}
%{?el5:Group: System Environment/Libraries}
@@ -401,6 +392,7 @@ octave -H -q --no-window-system --no-site-file --eval "pkg rebuild"
* Fri Dec 20 2013 Björn Esser <bjoern.esser at gmail.com> - 2.4-3.git20130903.35e6377
- made %%clean-target conditional on el5
- restructured spec-file for quick switching between snapshot and release
+- moved package-specific macros to the corresponding subpackage
* Wed Oct 02 2013 Björn Esser <bjoern.esser at gmail.com> - 2.4-2.git20130903.35e6377
- adaptions for new Python-guidelines
More information about the scm-commits
mailing list