You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bigtop.apache.org by bm...@apache.org on 2011/08/16 02:46:28 UTC

svn commit: r1158074 - /incubator/bigtop/trunk/src/pkg/rpm/hadoop/SPECS/hadoop.spec

Author: bmahe
Date: Tue Aug 16 00:46:28 2011
New Revision: 1158074

URL: http://svn.apache.org/viewvc?rev=1158074&view=rev
Log:
BIGTOP-21. Fix macro specification for CentOS/RHEL/Fedora. CentOS 6 provides %{rhel} but CentOS 5 does not provide any mean to know what is it

Modified:
    incubator/bigtop/trunk/src/pkg/rpm/hadoop/SPECS/hadoop.spec

Modified: incubator/bigtop/trunk/src/pkg/rpm/hadoop/SPECS/hadoop.spec
URL: http://svn.apache.org/viewvc/incubator/bigtop/trunk/src/pkg/rpm/hadoop/SPECS/hadoop.spec?rev=1158074&r1=1158073&r2=1158074&view=diff
==============================================================================
--- incubator/bigtop/trunk/src/pkg/rpm/hadoop/SPECS/hadoop.spec (original)
+++ incubator/bigtop/trunk/src/pkg/rpm/hadoop/SPECS/hadoop.spec Tue Aug 16 00:46:28 2011
@@ -39,8 +39,9 @@
 %global hadoop_arch Linux-amd64-64
 %endif
 
-
-%if  0%{?fedora_version}%{?rhel_version}%{?centos_version}
+# CentOS 5 does not have any dist macro
+# So I will suppose anything that is not Mageia or a SUSE will be a RHEL/CentOS/Fedora
+%if %{!?suse_version:1}%{!?mgaversion:1}0
 # brp-repack-jars uses unzip to expand jar files
 # Unfortunately aspectjtools-1.6.5.jar pulled by ivy contains some files and directories without any read permission
 # and make whole process to fail.
@@ -123,8 +124,10 @@ BuildRequires: libfuse2, libopenssl-deve
 Requires: sh-utils, insserv
 %endif
 
-%if  0%{?fedora_version}%{?rhel_version}%{?centos_version}
-BuildRequires: fuse-libs, libtool, redhat-rpm-config, liblzo-devel
+# CentOS 5 does not have any dist macro
+# So I will suppose anything that is not Mageia or a SUSE will be a RHEL/CentOS/Fedora
+%if %{!?suse_version:1}%{!?mgaversion:1}0
+BuildRequires: fuse-libs, libtool, redhat-rpm-config, lzo-devel
 # Required for init scripts
 Requires: sh-utils, redhat-lsb
 %endif