diff --git a/.gitignore b/.gitignore index f55bf42..aeab119 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -SOURCES/nvml-1.1.tar.gz +SOURCES/nvml-1.2.1.tar.gz diff --git a/.nvml.metadata b/.nvml.metadata index 1b8eed7..e1d202b 100644 --- a/.nvml.metadata +++ b/.nvml.metadata @@ -1 +1 @@ -ffb05d053376868dd59b5e0ff241134a5a170d7b SOURCES/nvml-1.1.tar.gz +62f83fb89a694e69bbcec391123b3f99da5eec09 SOURCES/nvml-1.2.1.tar.gz diff --git a/SOURCES/670e94e-pmempool-fix-mapping-type-in-pool_params_parse.patch b/SOURCES/670e94e-pmempool-fix-mapping-type-in-pool_params_parse.patch new file mode 100644 index 0000000..f954ad8 --- /dev/null +++ b/SOURCES/670e94e-pmempool-fix-mapping-type-in-pool_params_parse.patch @@ -0,0 +1,25 @@ +pmempool: fix mapping type in pool_params_parse + +BZ: 1436820 + +commit 670e94e62d8dfdd9a66435dcf415b0a3fffc65c6 +Author: Lukasz Dorau +Date: Wed Dec 14 16:58:03 2016 +0100 + + pmempool: fix mapping type in pool_params_parse + + This change is required on account of DAX devices. + +diff --git a/src/libpmempool/pool.c b/src/libpmempool/pool.c +index 6705bfe..7c4ec1a 100644 +--- a/src/libpmempool/pool.c ++++ b/src/libpmempool/pool.c +@@ -349,7 +349,7 @@ pool_params_parse(const PMEMpoolcheck *ppc, struct pool_params *params, + } + params->size = (size_t)s; + addr = mmap(NULL, (uint64_t)params->size, PROT_READ, +- MAP_PRIVATE, fd, 0); ++ MAP_SHARED, fd, 0); + if (addr == MAP_FAILED) { + ret = -1; + goto out_close; diff --git a/SOURCES/aabd4d2-test-do-not-run-pool_lock-test-as-root.patch b/SOURCES/aabd4d2-test-do-not-run-pool_lock-test-as-root.patch new file mode 100644 index 0000000..702375f --- /dev/null +++ b/SOURCES/aabd4d2-test-do-not-run-pool_lock-test-as-root.patch @@ -0,0 +1,129 @@ +test: do not run pool_lock test as root + +BZ: 1383467 + +commit aabd4d26de7a41400f66632989b3592786d7db89 +Author: Krzysztof Czurylo +Date: Thu Mar 16 13:33:14 2017 +0100 + + test: do not run pool_lock test as root + + Backported from master (4a86707). + +diff --git a/src/test/blk_pool_lock/TEST0 b/src/test/blk_pool_lock/TEST0 +index 2d89772..feac8d2 100755 +--- a/src/test/blk_pool_lock/TEST0 ++++ b/src/test/blk_pool_lock/TEST0 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2015-2016, Intel Corporation ++# Copyright 2015-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -41,6 +41,7 @@ export UNITTEST_NUM=0 + . ../unittest/unittest.sh + + require_test_type medium ++require_no_superuser + + setup + +diff --git a/src/test/blk_pool_lock/TEST0.PS1 b/src/test/blk_pool_lock/TEST0.PS1 +index 8e12e52..a33c083 100644 +--- a/src/test/blk_pool_lock/TEST0.PS1 ++++ b/src/test/blk_pool_lock/TEST0.PS1 +@@ -1,5 +1,5 @@ + # +-# Copyright 2015-2016, Intel Corporation ++# Copyright 2015-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -47,6 +47,7 @@ $Env:UNITTEST_NUM = "0" + . ..\unittest\unittest.ps1 + + require_test_type medium ++require_no_superuser + + # doesn't make sense to run in local directory + require_fs_type any +diff --git a/src/test/log_pool_lock/TEST0 b/src/test/log_pool_lock/TEST0 +index 498b04c..b285486 100755 +--- a/src/test/log_pool_lock/TEST0 ++++ b/src/test/log_pool_lock/TEST0 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2015-2016, Intel Corporation ++# Copyright 2015-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -41,6 +41,7 @@ export UNITTEST_NUM=0 + . ../unittest/unittest.sh + + require_test_type medium ++require_no_superuser + + setup + +diff --git a/src/test/log_pool_lock/TEST0.PS1 b/src/test/log_pool_lock/TEST0.PS1 +index 833825c..9c2ba17 100644 +--- a/src/test/log_pool_lock/TEST0.PS1 ++++ b/src/test/log_pool_lock/TEST0.PS1 +@@ -1,5 +1,5 @@ + # +-# Copyright 2015-2016, Intel Corporation ++# Copyright 2015-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -47,6 +47,7 @@ $Env:UNITTEST_NUM = "0" + . ..\unittest\unittest.ps1 + + require_test_type medium ++require_no_superuser + + # doesn't make sense to run in local directory + require_fs_type any +diff --git a/src/test/obj_pool_lock/TEST0 b/src/test/obj_pool_lock/TEST0 +index 60f5c55..944475e 100755 +--- a/src/test/obj_pool_lock/TEST0 ++++ b/src/test/obj_pool_lock/TEST0 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2015-2016, Intel Corporation ++# Copyright 2015-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -41,6 +41,7 @@ export UNITTEST_NUM=0 + . ../unittest/unittest.sh + + require_test_type medium ++require_no_superuser + + setup + +diff --git a/src/test/obj_pool_lock/TEST0.PS1 b/src/test/obj_pool_lock/TEST0.PS1 +index 2d15fb5..3f35b28 100644 +--- a/src/test/obj_pool_lock/TEST0.PS1 ++++ b/src/test/obj_pool_lock/TEST0.PS1 +@@ -1,5 +1,5 @@ + # +-# Copyright 2015-2016, Intel Corporation ++# Copyright 2015-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -47,6 +47,7 @@ $Env:UNITTEST_NUM = "0" + . ..\unittest\unittest.ps1 + + require_test_type medium ++require_no_superuser + + # doesn't make sense to run in local directory + require_fs_type any diff --git a/SOURCES/cb2e8d2-test-limit-number-of-arenas-in-vmem_stats.patch b/SOURCES/cb2e8d2-test-limit-number-of-arenas-in-vmem_stats.patch new file mode 100644 index 0000000..f59ac4b --- /dev/null +++ b/SOURCES/cb2e8d2-test-limit-number-of-arenas-in-vmem_stats.patch @@ -0,0 +1,244 @@ +test: limit number of arenas in vmem_stats + +BZ: 1383467 + +commit cb2e8d2590520463bf43453dab1c38fa6d1e0747 +Author: Krzysztof Czurylo +Date: Fri Mar 17 15:50:53 2017 +0100 + + test: limit number of arenas in vmem_stats + + By default, jemalloc allocates 4 * num_of_cpu arenas. If statistics + are enabled, it also allocates the corresponding per-arena stat + structures for all the arenas, even if only one arena is actually used + (single-threaded program). If this test is run on a machine with + the number of cores >=64, the amount of memory required to keep all + the statistics is larger than the usable space of the pool. + + The easiest workaround is to limit the number of arenas for this test + by setting JE_VMEM_MALLOC_CONF environment variable. Thus, the test can + be run on any machine and we don't need to calculate the pool size + based on number of available CPU cores. + + Backported from master (ccbf4cb). + +diff --git a/src/test/vmem_stats/TEST0 b/src/test/vmem_stats/TEST0 +index 5e11b9a..6f180b6 100755 +--- a/src/test/vmem_stats/TEST0 ++++ b/src/test/vmem_stats/TEST0 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 0 + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST1 b/src/test/vmem_stats/TEST1 +index bfabb87..1deb947 100755 +--- a/src/test/vmem_stats/TEST1 ++++ b/src/test/vmem_stats/TEST1 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 0 g + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST2 b/src/test/vmem_stats/TEST2 +index 776e938..729a315 100755 +--- a/src/test/vmem_stats/TEST2 ++++ b/src/test/vmem_stats/TEST2 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 0 gbl + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST3 b/src/test/vmem_stats/TEST3 +index 3bfb975..99ac9f4 100755 +--- a/src/test/vmem_stats/TEST3 ++++ b/src/test/vmem_stats/TEST3 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 0 gbla + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST4 b/src/test/vmem_stats/TEST4 +index b310590..779fe86 100755 +--- a/src/test/vmem_stats/TEST4 ++++ b/src/test/vmem_stats/TEST4 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 0 gblma + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST5 b/src/test/vmem_stats/TEST5 +index 5524b69..8d39f1a 100755 +--- a/src/test/vmem_stats/TEST5 ++++ b/src/test/vmem_stats/TEST5 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 1 + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST6 b/src/test/vmem_stats/TEST6 +index 6a6b8c7..3fc0a3a 100755 +--- a/src/test/vmem_stats/TEST6 ++++ b/src/test/vmem_stats/TEST6 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 1 g + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST7 b/src/test/vmem_stats/TEST7 +index f9f1545..c7d4d5c 100755 +--- a/src/test/vmem_stats/TEST7 ++++ b/src/test/vmem_stats/TEST7 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 1 gbl + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST8 b/src/test/vmem_stats/TEST8 +index 07c0e08..33509cc 100755 +--- a/src/test/vmem_stats/TEST8 ++++ b/src/test/vmem_stats/TEST8 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 1 gbla + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + +diff --git a/src/test/vmem_stats/TEST9 b/src/test/vmem_stats/TEST9 +index b67f261..085835e 100755 +--- a/src/test/vmem_stats/TEST9 ++++ b/src/test/vmem_stats/TEST9 +@@ -1,6 +1,6 @@ + #!/bin/bash -e + # +-# Copyright 2014-2016, Intel Corporation ++# Copyright 2014-2017, Intel Corporation + # + # Redistribution and use in source and binary forms, with or without + # modification, are permitted provided that the following conditions +@@ -50,6 +50,9 @@ configure_valgrind memcheck force-disable + + setup + ++# limit the number of arenas to fit into the minimal VMEM pool size ++export JE_VMEM_MALLOC_CONF="narenas:64" ++ + expect_normal_exit ./vmem_stats$EXESUFFIX 1 gblma + grep -v ':' vmem$UNITTEST_NUM.log > grep$UNITTEST_NUM.log + diff --git a/SPECS/nvml.spec b/SPECS/nvml.spec index a449286..5c2c3ff 100644 --- a/SPECS/nvml.spec +++ b/SPECS/nvml.spec @@ -1,17 +1,21 @@ Name: nvml -Version: 1.1 +Version: 1.2.1 Release: 4%{?dist} Summary: Non-Volatile Memory Library License: BSD URL: http://pmem.io/nvml Source0: https://github.com/pmem/%{name}/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz +Patch0: aabd4d2-test-do-not-run-pool_lock-test-as-root.patch +Patch1: cb2e8d2-test-limit-number-of-arenas-in-vmem_stats.patch +Patch2: 670e94e-pmempool-fix-mapping-type-in-pool_params_parse.patch BuildRequires: glibc-devel BuildRequires: autoconf BuildRequires: automake BuildRequires: man BuildRequires: pkgconfig +BuildRequires: doxygen # Debug variants of the libraries should be filtered out of the provides. @@ -45,7 +49,7 @@ support for the persistent memory instructions for flushing changes to pmem is provided. %files -n libpmem -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_datadir}/nvml %{_libdir}/libpmem.so.* %{_datadir}/nvml/nvml.magic @@ -68,7 +72,7 @@ will find higher level libraries like libpmemobj to be much more convenient. %files -n libpmem-devel -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmem.so %{_libdir}/pkgconfig/libpmem.pc %{_includedir}/libpmem.h @@ -92,7 +96,7 @@ debug version is to set the environment variable LD_LIBRARY_PATH to /usr/lib64/nvml_debug. %files -n libpmem-debug -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_libdir}/nvml_debug %{_libdir}/nvml_debug/libpmem.so %{_libdir}/nvml_debug/libpmem.so.* @@ -103,14 +107,14 @@ debug version is to set the environment variable LD_LIBRARY_PATH to %package -n libpmemblk Summary: Persistent Memory Resident Array of Blocks library Group: System Environment/Libraries -Requires: libpmem >= %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmemblk The libpmemblk implements a pmem-resident array of blocks, all the same size, where a block is updated atomically with respect to power failure or program interruption (no torn blocks). %files -n libpmemblk -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmemblk.so.* %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -133,7 +137,7 @@ developers will find higher level libraries like libpmemobj to be more generally useful. %files -n libpmemblk-devel -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmemblk.so %{_libdir}/pkgconfig/libpmemblk.pc %{_includedir}/libpmemblk.h @@ -146,6 +150,7 @@ more generally useful. Summary: Debug variant of the Persistent Memory Resident Array of Blocks library Group: Development/Libraries Requires: libpmemblk = %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmemblk-debug The libpmemblk implements a pmem-resident array of blocks, all the same size, where a block is updated atomically with respect to power @@ -157,7 +162,7 @@ debug version is to set the environment variable LD_LIBRARY_PATH to /usr/lib64/nvml_debug. %files -n libpmemblk-debug -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_libdir}/nvml_debug %{_libdir}/nvml_debug/libpmemblk.so %{_libdir}/nvml_debug/libpmemblk.so.* @@ -168,14 +173,14 @@ debug version is to set the environment variable LD_LIBRARY_PATH to %package -n libpmemlog Summary: Persistent Memory Resident Log File library Group: System Environment/Libraries -Requires: libpmem >= %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmemlog The libpmemlog library provides a pmem-resident log file. This is useful for programs like databases that append frequently to a log file. %files -n libpmemlog -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmemlog.so.* %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -193,7 +198,7 @@ record variable length entries. Most developers will find higher level libraries like libpmemobj to be more generally useful. %files -n libpmemlog-devel -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmemlog.so %{_libdir}/pkgconfig/libpmemlog.pc %{_includedir}/libpmemlog.h @@ -206,6 +211,7 @@ level libraries like libpmemobj to be more generally useful. Summary: Debug variant of the Persistent Memory Resident Log File library Group: Development/Libraries Requires: libpmemlog = %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmemlog-debug The libpmemlog library provides a pmem-resident log file. This library is provided for cases requiring an append-mostly file to @@ -218,7 +224,7 @@ debug version is to set the environment variable LD_LIBRARY_PATH to /usr/lib64/nvml_debug. %files -n libpmemlog-debug -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_libdir}/nvml_debug %{_libdir}/nvml_debug/libpmemlog.so %{_libdir}/nvml_debug/libpmemlog.so.* @@ -229,14 +235,14 @@ debug version is to set the environment variable LD_LIBRARY_PATH to %package -n libpmemobj Summary: Persistent Memory Transactional Object Store library Group: System Environment/Libraries -Requires: libpmem >= %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmemobj The libpmemobj library provides a transactional object store, providing memory allocation, transactions, and general facilities for persistent memory programming. %files -n libpmemobj -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmemobj.so.* %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -254,10 +260,11 @@ persistent memory programming. Developers new to persistent memory probably want to start with this library. %files -n libpmemobj-devel -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmemobj.so %{_libdir}/pkgconfig/libpmemobj.pc %{_includedir}/libpmemobj.h +%{_includedir}/libpmemobj/*.h %{_mandir}/man3/libpmemobj.3.gz %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -267,6 +274,7 @@ probably want to start with this library. Summary: Debug variant of the Persistent Memory Transactional Object Store library Group: Development/Libraries Requires: libpmemobj = %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmemobj-debug The libpmemobj library provides a transactional object store, providing memory allocation, transactions, and general facilities for @@ -279,7 +287,7 @@ debug version is to set the environment variable LD_LIBRARY_PATH to /usr/lib64/nvml_debug. %files -n libpmemobj-debug -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_libdir}/nvml_debug %{_libdir}/nvml_debug/libpmemobj.so %{_libdir}/nvml_debug/libpmemobj.so.* @@ -296,7 +304,7 @@ memory pool, similar to the system heap but kept separate and with its own malloc-style API. %files -n libvmem -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libvmem.so.* %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -315,7 +323,7 @@ This sub-package contains libraries and header files for developing applications that want to make use of libvmem. %files -n libvmem-devel -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libvmem.so %{_libdir}/pkgconfig/libvmem.pc %{_includedir}/libvmem.h @@ -339,7 +347,7 @@ debug version is to set the environment variable LD_LIBRARY_PATH to /usr/lib64/nvml_debug. %files -n libvmem-debug -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_libdir}/nvml_debug %{_libdir}/nvml_debug/libvmem.so %{_libdir}/nvml_debug/libvmem.so.* @@ -360,7 +368,7 @@ The typical usage of libvmmalloc is to load it via the LD_PRELOAD environment variable. %files -n libvmmalloc -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libvmmalloc.so.* %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -380,7 +388,7 @@ This sub-package contains libraries and header files for developing applications that want to specifically make use of libvmmalloc. %files -n libvmmalloc-devel -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libvmmalloc.so %{_libdir}/pkgconfig/libvmmalloc.pc %{_includedir}/libvmmalloc.h @@ -405,7 +413,7 @@ debug version is to set the environment variable LD_LIBRARY_PATH to /usr/lib64/nvml_debug. %files -n libvmmalloc-debug -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_libdir}/nvml_debug %{_libdir}/nvml_debug/libvmmalloc.so %{_libdir}/nvml_debug/libvmmalloc.so.* @@ -413,17 +421,41 @@ debug version is to set the environment variable LD_LIBRARY_PATH to %doc ChangeLog CONTRIBUTING.md README.md +# Specify a virtual Provide for libpmemobj++-static package, so the package +# usage can be tracked. +%package -n libpmemobj++-devel +Summary: C++ bindings for Persistent Memory Transactional Object Store library +Group: Development/Libraries +Provides: libpmemobj++-static = %{version}-%{release} +Requires: libpmemobj-devel = %{version}-%{release} +%description -n libpmemobj++-devel +The libpmemobj library provides a transactional object store, +providing memory allocation, transactions, and general facilities for +persistent memory programming. + +This sub-package contains header files for libpmemobj C++ bindings. + +%files -n libpmemobj++-devel +%defattr(-,root,root,-) +%{_libdir}/pkgconfig/libpmemobj++.pc +%{_includedir}/libpmemobj++/*.hpp +%{_includedir}/libpmemobj++/detail/*.hpp +%{_docdir}/libpmemobj++-devel/* +%license LICENSE +%doc ChangeLog CONTRIBUTING.md README.md + + %package -n libpmempool Summary: Persistent Memory pool management library Group: System Environment/Libraries -Requires: libpmem >= %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmempool -The libpmempool library provides a set of utilities for off-line administration, -analysis, diagnostics and repair of persistent memory pools created -by libpmemlog, libpemblk and libpmemobj libraries. +The libpmempool library provides a set of utilities for off-line +administration, analysis, diagnostics and repair of persistent memory +pools created by libpmemlog, libpemblk and libpmemobj libraries. %files -n libpmempool -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmempool.so.* %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -435,12 +467,12 @@ Group: Development/Libraries Requires: libpmempool = %{version}-%{release} Requires: libpmem-devel = %{version}-%{release} %description -n libpmempool-devel -The libpmempool library provides a set of utilities for off-line administration, -analysis, diagnostics and repair of persistent memory pools created -by libpmemlog, libpemblk and libpmemobj libraries. +The libpmempool library provides a set of utilities for off-line +administration, analysis, diagnostics and repair of persistent memory +pools created by libpmemlog, libpemblk and libpmemobj libraries. %files -n libpmempool-devel -%defattr(644,root,root,-) +%defattr(-,root,root,-) %{_libdir}/libpmempool.so %{_libdir}/pkgconfig/libpmempool.pc %{_includedir}/libpmempool.h @@ -453,10 +485,11 @@ by libpmemlog, libpemblk and libpmemobj libraries. Summary: Debug variant of the Persistent Memory pool management library Group: Development/Libraries Requires: libpmempool = %{version}-%{release} +Requires: libpmem = %{version}-%{release} %description -n libpmempool-debug -The libpmempool library provides a set of utilities for off-line administration, -analysis, diagnostics and repair of persistent memory pools created -by libpmemlog, libpemblk and libpmemobj libraries. +The libpmempool library provides a set of utilities for off-line +administration, analysis, diagnostics and repair of persistent memory +pools created by libpmemlog, libpemblk and libpmemobj libraries. This sub-package contains debug variant of the library, providing run-time assertions and trace points. The typical way to access the @@ -464,7 +497,7 @@ debug version is to set the environment variable LD_LIBRARY_PATH to /usr/lib64/nvml_debug. %files -n libpmempool-debug -%defattr(644,root,root,-) +%defattr(-,root,root,-) %dir %{_libdir}/nvml_debug %{_libdir}/nvml_debug/libpmempool.so %{_libdir}/nvml_debug/libpmempool.so.* @@ -475,23 +508,25 @@ debug version is to set the environment variable LD_LIBRARY_PATH to %package tools Summary: Utilities for Persistent Memory Group: System Environment/Base -Requires: libpmem >= %{version}-%{release} -Requires: libpmemlog >= %{version}-%{release} -Requires: libpmemblk >= %{version}-%{release} -Requires: libpmemobj >= %{version}-%{release} -Requires: libpmempool >= %{version}-%{release} +Requires: libpmem = %{version}-%{release} +Requires: libpmemlog = %{version}-%{release} +Requires: libpmemblk = %{version}-%{release} +Requires: libpmemobj = %{version}-%{release} +Requires: libpmempool = %{version}-%{release} %description tools Useful applications for administration and diagnosis of persistent memory. %files tools %{_bindir}/pmempool %{_mandir}/man1/pmempool.1.gz -%{_mandir}/man1/pmempool-info.1.gz +%{_mandir}/man1/pmempool-check.1.gz +%{_mandir}/man1/pmempool-convert.1.gz %{_mandir}/man1/pmempool-create.1.gz %{_mandir}/man1/pmempool-dump.1.gz -%{_mandir}/man1/pmempool-check.1.gz +%{_mandir}/man1/pmempool-info.1.gz %{_mandir}/man1/pmempool-rm.1.gz -%{_mandir}/man1/pmempool-convert.1.gz +%{_mandir}/man1/pmempool-sync.1.gz +%{_mandir}/man1/pmempool-transform.1.gz %config(noreplace) %{_sysconfdir}/bash_completion.d/pmempool.sh %license LICENSE %doc ChangeLog CONTRIBUTING.md README.md @@ -499,7 +534,9 @@ Useful applications for administration and diagnosis of persistent memory. %prep %setup -q -n %{name}-%{version} - +%patch0 -p1 +%patch1 -p1 +%patch2 -p1 %build # Currently, NVML makefiles do not allow to easily override CFLAGS, @@ -520,7 +557,9 @@ make install DESTDIR=%{buildroot} \ includedir=%{_includedir} \ mandir=%{_mandir} \ bindir=%{_bindir} \ - sysconfdir=%{_sysconfdir} + sysconfdir=%{_sysconfdir} \ + docdir=%{_docdir} \ + CPP_DOC_DIR=libpmemobj++-devel mkdir -p %{buildroot}%{_datadir}/nvml cp utils/nvml.magic %{buildroot}%{_datadir}/nvml/ @@ -552,6 +591,24 @@ make check %changelog +* Wed Apr 05 2017 Jeff Moyer - 1.2.1-4.el7 +- Fix mapping type in pool params parse +- Resolves: bz#1436820 + +* Tue Mar 28 2017 Jeff Moyer - 1.2.1-3.el7 +- Add 'Requires: libpmem' lines for debug packages. +- Related: bz#1383467 bz#1382407 + +* Tue Mar 28 2017 Jeff Moyer - 1.2.1-2.el7 +- Actually apply stable update patches +- Related: bz#1383467 bz#1382407 + +* Tue Mar 28 2017 Jeff Moyer - 1.2.1-1.el7 +- Update to latest stable release +- Pull in pending stable patches for the test harness +- disable % check temporarily until all test issues are resolved +- Resolves: bz#1383467 bz#1382407 + * Thu Jul 14 2016 Jeff Moyer - 1.1-4.el7 - Add missing version dependencies between packages - Resolves: bz#1274541