Open MPI logo

Hardware Locality Development Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Hardware Locality Development mailing list

Subject: Re: [hwloc-devel] hwloc in Debian, anybody working on RPMs?
From: Tony Breeds (tony_at_[hidden])
Date: 2009-11-26 00:14:05

On Tue, Nov 24, 2009 at 07:01:30AM -0500, Jeff Squyres wrote:
> True. We googled around to try to find a fairly unique name before
> we re-branded from libtopology (because there *was* a name collision
> with that project). Hopefully it'll stay unique and/or we'll gain
> enough of a following that it'll be unambiguously "claimed" for this
> project. :-)

Sorry I was thinking more in tersm of package dependacies that the name of
hwloc itself. It's easy enough to work around if we hit it.

> Awesome -- thanks!
> Do you want to commit that? If we keep the analog to the OMPI
> project, we'd put it under contrib/dist/linux/hwloc.spec.

Sure. I was thinking of the following patch:

Essentailly rather than hardcoding the hwloc version track it from the VERSION
file and generate the .spec file at ./configure time.

Does that look okay?

Index: contrib/dist/linux/
--- contrib/dist/linux/ (revision 0)
+++ contrib/dist/linux/ (revision 0)
@@ -0,0 +1,93 @@
+%define ver_major @HWLOC_MAJOR_VERSION@
+%define ver_minor @HWLOC_MINOR_VERSION@
+%define ver_release @HWLOC_RELEASE_VERSION@
+%define ver_majmin %{ver_major}.%{ver_minor}
+Name: hwloc
+Version: %{ver_majmin}.%{ver_release}
+Release: 1%{?dist}
+Summary: Hardware Locality Library
+Group: System Environment/Libraries
+License: BSD
+Source0: %{url}/software/%{name}/v%{ver_majmin}/downloads/%{name}-%{version}.tar.bz2
+BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
+BuildRequires: libxml2-devel, ncurses-devel
+The Portable Hardware Locality (hwloc) software package provides a portable
+abstraction (across OS, versions, architectures, ...) of the hierarchical
+topology of modern architectures, including NUMA memory nodes, sockets, shared
+caches, cores and simultaneous multithreading. It also gathers various system
+attributes such as cache and memory information. It primarily aims at helping
+applications with gathering information about modern computing hardware so as
+to exploit it accordingly and efficiently.
+%package devel
+Summary: Hardware Locality development package
+Group: Development/Libraries
+Requires: %{name} = %{version}-%{release}
+%description devel
+Development package for hwloc.
+%setup -q
+%configure --disable-static
+make %{?_smp_mflags}
+rm -rf %{buildroot}
+make install DESTDIR=%{buildroot}
+rm %{buildroot}/%{_libdir}/
+rm -rf %{buildroot}
+%post -p /sbin/ldconfig
+%postun -p /sbin/ldconfig
+%dir %{_datarootdir}/%{name}
+%files devel
+%dir %{_includedir}/hwloc
+* Thu Nov 19 2009 tony_at_[hidden] - 0.9.2-1
+ - Initial packaging
--- (revision 1405)
+++ (working copy)
@@ -35,6 +35,9 @@
 HWLOC_RELEASE_VERSION="`$srcdir/config/ $srcdir/VERSION --release`"
 HWLOC_SVN_R="`$srcdir/config/ $srcdir/VERSION --svn`"
 HWLOC_RELEASE_DATE="`$srcdir/config/ $srcdir/VERSION --release-date`"
@@ -524,6 +527,7 @@
+ contrib/dist/linux/hwloc.spec

Yours Tony