[meego-commits] 5670: Changes to Trunk/sos

Anas Nashif nashif at linux.intel.com
Tue Jul 13 22:59:59 UTC 2010


Hi,
I have made the following changes to sos in project Trunk. Please review and accept ASAP.

Thank You,
Anas Nashif

[This message was auto-generated]

---

Request #5670:

  submit:   Trunk:Testing/sos(r3) -> Trunk/sos


Message:
    Move to Trunk

State:   new          2010-07-13T10:54:44 nashif
Comment: None



changes files:
--------------
--- sos.changes
+++ sos.changes
@@ -0,0 +1,3 @@
+* Mon Jul 12 2010 Yu <yu.a.wang at intel.com> - 2.2
+- Upgrade to 2.2, use spectacle
+

old:
----
  sos-1.8.tar.gz

new:
----
  sos-2.2.tar.gz
  sos.yaml

spec files:
-----------
--- sos.spec
+++ sos.spec
@@ -1,52 +1,75 @@
-%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
+# 
+# Do not Edit! Generated by:
+# spectacle version 0.17
+# 
+# >> macros
+# << macros
 
-Summary: A set of tools to gather troubleshooting information from a system
 Name: sos
-Version: 1.8
+Summary:    A set of tools to gather troubleshooting information from a system
+Version:    2.2
 Release: 15
 Group: Applications/System
-Source0: https://fedorahosted.org/releases/s/o/sos/%{name}-%{version}.tar.gz
 License: GPLv2+
 BuildArch: noarch
-Url: http://fedorahosted.org/sos
-BuildRequires: python-devel
-Requires: libxml2-python
-Requires: tar, bzip2
+URL:        http://fedorahosted.org/sos
+Source0:    https://fedorahosted.org/releases/s/o/sos/%{name}-%{version}.tar.gz
+Source100:  sos.yaml
 Patch0: sos-meego.patch
+Requires:   libxml2-python
+Requires:   tar
+Requires:   bzip2
+BuildRequires:  python-devel
+BuildRequires:  gettext
+
 
 %description
-Sos is a set of tools that gathers information about system
-hardware and configuration. The information can then be used for
-diagnostic purposes and debugging. Sos is commonly used to help
-support technicians and developers.
+Sos is a set of tools that gathers information about system hardware and configuration. The information can then be used for diagnostic purposes and debugging. Sos is commonly used to help support technicians and developers.
+
+
 
 %prep
-%setup -q
+%setup -q -n %{name}-%{version}
+
+# sos-meego.patch
 %patch0 -p1
+# >> setup
+# << setup
 
 %build
-%{__python} setup.py build
+# >> build pre
+# << build pre
+
 
+make %{?jobs:-j%jobs}
+
+# >> build post
+# << build post
 %install
-rm -rf ${RPM_BUILD_ROOT}
-install -D -m644 extras/sysreport/sysreport.legacy ${RPM_BUILD_ROOT}/%{_datadir}/%{name}/sysreport
-%{__python} setup.py install -O1 --skip-build --root ${RPM_BUILD_ROOT}
-ln -s /usr/sbin/sosreport ${RPM_BUILD_ROOT}/usr/sbin/sysreport
+rm -rf %{buildroot}
+# >> install pre
+# << install pre
+%make_install
+
+# >> install post
+# << install post
 %find_lang %{name}
 
-%clean
-rm -rf ${RPM_BUILD_ROOT}
+
+
+
+
 
 %files -f %{name}.lang
 %defattr(-,root,root,-)
-%{_bindir}/rh-upload-core
+# >> files
 %{_sbindir}/sosreport
-%{_sbindir}/sysreport
-%{_sbindir}/sysreport.legacy
 %{_datadir}/%{name}
-%{_datadir}/sysreport
 %{python_sitelib}/*
 %{_mandir}/man1/sosreport.1.gz
-%doc README README.rh-upload-core TODO LICENSE ChangeLog
+%{_mandir}/man5/sos.conf.5.gz
+%doc README TODO LICENSE ChangeLog
 %config %{_sysconfdir}/sos.conf
+# << files
+
 

other changes:
--------------

++++++ sos-1.8.tar.gz -> sos-2.2.tar.gz
28247 lines of diff (skipped)

++++++ sos-meego.patch
--- sos-meego.patch
+++ sos-meego.patch
@@ -1,22 +1,6 @@
---- a/extras/sysreport/sysreport.legacy
-+++ b/extras/sysreport/sysreport.legacy
-@@ -75,10 +75,10 @@ fi
- 
- trap "{ rm -rf $ROOT ; exit ; }" EXIT
- 
--if [ -f /etc/fedora-release ] ; then
--  release_name="Fedora Core"
-+if [ -f /etc/meego-release ] ; then
-+  release_name="MeeGo Linux"
- else
--  release_name="Red Hat Linux"
-+  release_name="Moblin"
- fi
- 
- echo
---- a/lib/sos/plugins/general.py
-+++ b/lib/sos/plugins/general.py
-@@ -24,8 +24,7 @@ class general(sos.plugintools.PluginBase
+--- sos-2.2/sos/plugins/general.py	2010-05-28 04:24:07.000000000 +0800
++++ sos/sos/plugins/general.py	2010-07-12 14:21:03.570684403 +0800
+@@ -25,8 +25,7 @@
                    ("all_logs", "collect all log files defined in syslog.conf", "", False)]
  
      def setup(self):
@@ -26,26 +10,40 @@
          self.addCopySpec("/etc/inittab")
          self.addCopySpec("/etc/sos.conf")
          self.addCopySpec("/etc/sysconfig")
-@@ -40,7 +39,6 @@ class general(sos.plugintools.PluginBase
-         self.addCopySpecLimit("/var/log/secure.*", sizelimit = self.getOption("syslogsize"))
+@@ -39,7 +38,6 @@
+         self.addCopySpecLimit("/var/log/secure*", sizelimit = self.getOption("syslogsize"))
          self.addCopySpec("/var/log/sa")
          self.addCopySpec("/var/log/pm/suspend.log")
 -        self.addCopySpec("/var/log/up2date")
          self.addCopySpec("/etc/exports")        
          self.collectExtOutput("/bin/hostname", root_symlink = "hostname")
          self.collectExtOutput("/bin/date", root_symlink = "date")
---- a/sosreport
-+++ b/sosreport
-@@ -664,10 +664,10 @@ def sosreport():
+--- sos-2.2/sos/sosreport.py	2010-06-09 02:11:39.000000000 +0800
++++ sos/sos/sosreport.py	2010-07-12 14:19:41.542746971 +0800
+@@ -48,10 +48,10 @@
+ from sos import _sos as _
+ 
+ __version__ = 2.1
+-if os.path.isfile('/etc/fedora-release'):
+-    __distro__ = 'Fedora'
++if os.path.isfile('/etc/meego-release'):
++    __distro__ = 'MeeGo'
+ else:
+-    __distro__ = 'Red Hat Enterprise Linux'
++    __distro__ = 'Moblin'
+ 
+ class GlobalVars:
+     """ Generic container for shared vars """
+@@ -622,10 +622,10 @@
          doExit(1)
  
      msg = _("""This utility will collect some detailed  information about the
--hardware and  setup of your Fedora system.
-+hardware and  setup of your MeeGo system.
+-hardware and setup of your %(distroa)s system.
++hardware and setup of your %(distroa) system.
  The information is collected and an archive is  packaged under
  /tmp, which you can send to a support representative.
--Fedora will use this information for diagnostic purposes ONLY
-+MeeGo will use this information for diagnostic purposes ONLY
+-%(distrob)s will use this information for diagnostic purposes ONLY
++%(distrob) will use this information for diagnostic purposes ONLY
  and it will be considered confidential information.
  
  This process may take a while to complete.

++++++ sos.yaml (new)
--- sos.yaml
+++ sos.yaml
+Name: sos
+Summary: A set of tools to gather troubleshooting information from a system
+Version: 2.2
+Release: 15
+Group: Applications/System
+License: GPLv2+
+URL: http://fedorahosted.org/sos
+Sources:
+    - https://fedorahosted.org/releases/s/o/sos/%{name}-%{version}.tar.gz
+Patches:
+    - sos-meego.patch
+Description: 
+    Sos is a set of tools that gathers information about system
+    hardware and configuration. The information can then be used for
+    diagnostic purposes and debugging. Sos is commonly used to help
+    support technicians and developers.
+
+Requires:
+    - libxml2-python
+    - tar
+    - bzip2
+PkgBR:
+    - python-devel
+    - gettext
+Configure: none
+Builder: make
+BuildArch: noarch
+LocaleName: "%{name}"



More information about the MeeGo-commits mailing list