]> xenbits.xensource.com Git - xentesttools/bootstrap.git/commitdiff
Makefile: support for hwloc.
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Fri, 8 Jan 2016 14:54:54 +0000 (09:54 -0500)
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Fri, 8 Jan 2016 14:54:54 +0000 (09:54 -0500)
One would also need to:

git clone https://github.com/open-mpi/hwloc in the root_image

to use it.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
root_image/Makefile

index 174cea720ebbb15161864180b8337745e0049f30..de21cbee063cc2ff7ee7f8d99ba2b171f651112a 100644 (file)
@@ -710,6 +710,18 @@ ifeq ($(RPM_ARCH), x86_64)
 endif
        (cd userspace$(LIBSDIR); ln -fs ../usr$(LIBSDIR)/libsysfs.so.2)
 
+.PHONY:        hwloc-install
+hwloc-install:
+       $(call RPM_TO_USERSPACE,*libxml2.so*,$(RPM_DIR)/libxml2)
+       if ! [ -e hwloc/config.log ]; then (cd hwloc; ./autogen.sh;./configure --prefix=/usr --disable-cairo --disable-gl); fi
+       $(MAKE) $(MFLAGS) -j$$(($(NCPUS) * 2)) -C hwloc
+       (cd hwloc;$(MAKE) $(MFLAGS) -j$$(($(NCPUS) * 2)) DESTDIR=$(CURDIR)/userspace install)
+       if test -f userspace/usr/lib/libhwloc.so; then \
+               if ! test -f userspace/usr/lib64/libhwloc.so; then \
+                       ( cd userspace/usr/lib; for lib in `ls -1 *libhwloc* *libnetloc*`; do (cd ../lib64;ln -s ../lib/$$lib); done;); \
+               fi \
+       fi
+
 .PHONY:        irqbalance-install
 irqbalance-install:
        if ! [ -e irqbalance/config.h ]; then (cd irqbalance; ./autogen.sh;./configure --prefix=/usr); fi