Commit 712019c6 authored by Rob Latham's avatar Rob Latham
Browse files

A version of IOR that uses mobject

parent 6aa8b757
From 0ee24e707fc2be9cf8f0e61ea2fe852d5272b782 Mon Sep 17 00:00:00 2001
From: Rob Latham <robl@mcs.anl.gov>
Date: Tue, 12 Feb 2019 09:54:32 -0600
Subject: [PATCH] DO NOT MERGE: mobject-specific hackery
---
src/Makefile.am | 1 -
src/aiori-RADOS.c | 2 +-
src/ior.h | 3 ++-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/Makefile.am b/src/Makefile.am
index 51fb8734951a..6f78a18bf79b 100755
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -67,7 +67,6 @@ endif
if USE_RADOS_AIORI
extraSOURCES += aiori-RADOS.c
-extraLDADD += -lrados
endif
if USE_S3_AIORI
diff --git a/src/aiori-RADOS.c b/src/aiori-RADOS.c
index 090414d24aae..adec732cdad8 100755
--- a/src/aiori-RADOS.c
+++ b/src/aiori-RADOS.c
@@ -20,7 +20,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <sys/stat.h>
-#include <rados/librados.h>
+#include <librados-mobject-store.h>
#include "ior.h"
#include "iordef.h"
diff --git a/src/ior.h b/src/ior.h
index ad543ffe5a03..fc37280608c4 100755
--- a/src/ior.h
+++ b/src/ior.h
@@ -30,7 +30,8 @@
#endif
#ifdef USE_RADOS_AIORI
-# include <rados/librados.h>
+#include <librados-mobject-store.h>
+
#else
typedef void *rados_t;
typedef void *rados_ioctx_t;
--
1.8.3.1
# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
import subprocess
import os
class Ior(AutotoolsPackage):
"""The IOR software is used for benchmarking parallel file systems
using POSIX, MPI-IO, or HDF5 interfaces."""
homepage = "https://github.com/hpc/ior"
url = "https://github.com/hpc/ior/archive/3.2.0.tar.gz"
git = 'https://github.com/shanedsnyder/ior'
version('mobject', branch='mobject-ior', submodules=True)
version('3.2.0', sha256='0cda0e00b7f070c6754ef8acb3873eb3a625bd8dee3f2e220291656be1322bbb')
version('3.0.1', '71150025e0bb6ea1761150f48b553065')
variant('hdf5', default=False, description='support IO with HDF5 backend')
variant('ncmpi', default=False, description='support IO with NCMPI backend')
variant('mobject', default=False, description='support IO with RADOS-like Mobject backend')
depends_on('autoconf', type='build')
depends_on('automake', type='build')
depends_on('libtool', type='build')
depends_on('m4', type='build')
depends_on('mpi')
depends_on('hdf5+mpi', when='+hdf5')
depends_on('parallel-netcdf', when='+ncmpi')
depends_on('mobject', when='+mobject')
patch('0001-DO-NOT-MERGE-mobject-specific-hackery.patch', when='+mobject')
@run_before('autoreconf')
def bootstrap(self):
Executable('./bootstrap')()
def configure_args(self):
spec = self.spec
config_args = []
env['CC'] = spec['mpi'].mpicc
if '+hdf5' in spec:
config_args.append('--with-hdf5')
config_args.append('CFLAGS=-D H5_USE_16_API')
else:
config_args.append('--without-hdf5')
if '+ncmpi' in spec:
config_args.append('--with-ncmpi')
else:
config_args.append('--without-ncmpi')
if '+mobject' in spec:
os.environ["PKG_CONFIG_ALLOW_SYSTEM_CFLAGS"]="yes"
pkg_config=which('pkg-config')
extra_cflags = "CPPFLAGS="
extra_ldflags="LDFLAGS="
extra_cflags += subprocess.check_output([str(pkg_config), "--cflags", "mobject-store"]).strip('\n')
extra_ldflags += subprocess.check_output([str(pkg_config), "--libs", "mobject-store"]).strip('\n')
config_args.append('--with-rados')
config_args.append(extra_cflags)
config_args.append(extra_ldflags)
return config_args
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment