diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..9b63ddb
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1 @@
+SOURCES/ndctl-62.tar.gz
diff --git a/.ndctl.metadata b/.ndctl.metadata
new file mode 100644
index 0000000..b4b822d
--- /dev/null
+++ b/.ndctl.metadata
@@ -0,0 +1 @@
+0f906e39f1af10fe60748b8862e761fe36abd985 SOURCES/ndctl-62.tar.gz
diff --git a/SOURCES/5c67ce4-ndctl-Revert-ndctl-Create-ndctl-udev-rules-for-dirty-shutdown.patch b/SOURCES/5c67ce4-ndctl-Revert-ndctl-Create-ndctl-udev-rules-for-dirty-shutdown.patch
new file mode 100644
index 0000000..1bd9230
--- /dev/null
+++ b/SOURCES/5c67ce4-ndctl-Revert-ndctl-Create-ndctl-udev-rules-for-dirty-shutdown.patch
@@ -0,0 +1,499 @@
+ndctl: Revert "ndctl: Create ndctl udev rules for dirty shutdown"
+
+BZ: 1637624
+
+commit 5c67ce4d0b6a678c52f35a6a1e2dd14983076a19
+Author: Dan Williams <dan.j.williams@intel.com>
+Date:   Thu Sep 27 17:41:53 2018 -0700
+
+    ndctl: Revert "ndctl: Create ndctl udev rules for dirty shutdown"
+    
+    Environments that choose to implement dirty-shutdown mitigation can use
+    'list --dimm --health nmemX' to retrieve the dirty-shutdown count, or
+    the new 'nmemX/nfit/dirty_shutdown' attribute in sysfs. The kernel
+    otherwise takes no default action on that counter rolling. If the
+    platform advertises support for "Memory Controller Flush to NVDIMM
+    Durability on Power Loss Capable" then the default Linux policy is to
+    trust that designation.
+    
+    Otherwise this usage of libndctl enumeration apis in the udev path
+    causes the entire udev queue to backup behind libnvdimm sub-system
+    initialization:
+    
+        INFO: task systemd-udevd:1554 blocked for more than 120 seconds.
+        "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
+        systemd-udevd   D    0  1554   1544 0x80000004
+        Call Trace:
+         ? __schedule+0x25d/0x870
+         schedule+0x28/0x80
+         async_synchronize_cookie_domain+0x96/0x140
+         ? finish_wait+0x80/0x80
+         nvdimm_bus_check_dimm_count+0x31/0xa0 [libnvdimm]
+         acpi_nfit_register_dimms+0x4b5/0x800 [nfit]
+         acpi_nfit_init+0xca6/0x1300 [nfit]
+         ? acpi_nfit_add+0x197/0x210 [nfit]
+         acpi_nfit_add+0x197/0x210 [nfit]
+         acpi_device_probe+0x48/0x110
+    
+    Cc: Keith Busch <keith.busch@intel.com>
+    Cc: Vishal Verma <vishal.l.verma@intel.com>
+    Signed-off-by: Dan Williams <dan.j.williams@intel.com>
+    Signed-off-by: Vishal Verma <vishal.l.verma@intel.com>
+
+diff -uprN ndctl-62/.gitignore ndctl-62.new/.gitignore
+--- ndctl-62/.gitignore	2018-08-13 20:06:33.000000000 -0400
++++ ndctl-62.new/.gitignore	2018-10-09 11:55:10.410374923 -0400
+@@ -25,7 +25,6 @@ daxctl/lib/libdaxctl.pc
+ *.a
+ ndctl/lib/libndctl.pc
+ ndctl/ndctl
+-ndctl/ndctl-udev
+ rhel/
+ sles/ndctl.spec
+ util/log.lo
+diff -uprN ndctl-62/Makefile.am ndctl-62.new/Makefile.am
+--- ndctl-62/Makefile.am	2018-08-13 20:06:33.000000000 -0400
++++ ndctl-62.new/Makefile.am	2018-10-09 11:55:10.410374923 -0400
+@@ -42,9 +42,6 @@ bashcompletiondir = $(BASH_COMPLETION_DI
+ dist_bashcompletion_DATA = contrib/ndctl
+ endif
+ 
+-udevrulesdir = $(UDEVDIR)/rules.d
+-dist_udevrules_DATA = contrib/80-ndctl.rules
+-
+ noinst_LIBRARIES = libccan.a
+ libccan_a_SOURCES = \
+ 	ccan/str/str.h \
+diff -uprN ndctl-62/configure.ac ndctl-62.new/configure.ac
+--- ndctl-62/configure.ac	2018-08-13 20:06:33.000000000 -0400
++++ ndctl-62.new/configure.ac	2018-10-09 11:58:18.412932195 -0400
+@@ -169,9 +169,6 @@ AC_ARG_WITH([tmpfilesdir],
+ 	[tmpfilesdir=$withval],
+ 	[tmpfilesdir="/run"])
+ 
+-UDEVDIR="$(pkg-config udev --variable=udevdir)"
+-AC_SUBST([UDEVDIR])
+-
+ my_CFLAGS="\
+ -D DEF_CONF_FILE='\"${sysconfdir}/ndctl/monitor.conf\"' \
+ -D DEF_TMPFS_DIR='\"${tmpfilesdir}/ndctl\"' \
+diff -uprN ndctl-62/configure.ac.orig ndctl-62.new/configure.ac.orig
+--- ndctl-62/configure.ac.orig	1969-12-31 19:00:00.000000000 -0500
++++ ndctl-62.new/configure.ac.orig	2018-10-09 11:54:00.000000000 -0400
+@@ -0,0 +1,223 @@
++AC_PREREQ(2.60)
++m4_include([version.m4])
++AC_INIT([ndctl],
++        GIT_VERSION,
++        [linux-nvdimm@lists.01.org],
++        [ndctl],
++        [https://github.com/pmem/ndctl])
++AC_CONFIG_SRCDIR([ndctl/lib/libndctl.c])
++AC_CONFIG_AUX_DIR([build-aux])
++AM_INIT_AUTOMAKE([
++	check-news
++	foreign
++	1.11
++	-Wall
++	-Wno-portability
++	silent-rules
++	tar-pax
++	no-dist-gzip
++	dist-xz
++	subdir-objects
++])
++AC_PROG_CC_STDC
++AC_USE_SYSTEM_EXTENSIONS
++AC_SYS_LARGEFILE
++AC_CONFIG_MACRO_DIR([m4])
++AM_SILENT_RULES([yes])
++LT_INIT([
++	disable-static
++	pic-only
++])
++AC_PREFIX_DEFAULT([/usr])
++
++AC_PROG_SED
++AC_PROG_MKDIR_P
++
++AC_ARG_ENABLE([docs],
++        AS_HELP_STRING([--disable-docs],
++	[disable documentation build @<:@default=enabled@:>@]),
++        [], enable_docs=yes)
++AS_IF([test "x$enable_docs" = "xyes"], [
++        AC_DEFINE(ENABLE_DOCS, [1], [Documentation / man pages.])
++])
++AM_CONDITIONAL([ENABLE_DOCS], [test "x$enable_docs" = "xyes"])
++
++AC_ARG_ENABLE([asciidoctor],
++	AS_HELP_STRING([--enable-asciidoctor],
++	[use asciidoctor for documentation build]),
++	[], enable_asciidoctor=no)
++AM_CONDITIONAL([USE_ASCIIDOCTOR], [test "x$enable_asciidoctor" = "xyes"])
++if test "x$enable_asciidoctor" = "xyes"; then
++	asciidoc="asciidoctor"
++else
++	asciidoc="asciidoc"
++fi
++AC_CHECK_PROG(ASCIIDOC, [$asciidoc], [$(which $asciidoc)], [missing])
++if test "x$ASCIIDOC" = xmissing -a "x$enable_docs" = "xyes"; then
++	AC_MSG_ERROR([$asciidoc needed to build documentation])
++fi
++AC_SUBST([ASCIIDOC])
++
++if test x"$asciidoc" = x"asciidoc"; then
++AC_CHECK_PROG(XMLTO, [xmlto], [$(which xmlto)], [missing])
++if test "x$XMLTO" = xmissing -a "x$enable_docs" = "xyes"; then
++       AC_MSG_ERROR([xmlto needed to build documentation])
++fi
++AC_SUBST([XMLTO])
++fi
++
++AC_C_TYPEOF
++AC_DEFINE([HAVE_STATEMENT_EXPR], 1, [Define to 1 if you have statement expressions.])
++
++AC_C_BIGENDIAN(
++	AC_DEFINE(HAVE_BIG_ENDIAN, 1, [Define to 1 if big-endian-arch]),
++	AC_DEFINE(HAVE_LITTLE_ENDIAN, 1, [Define to 1 if little-endian-arch]),
++	[], [])
++
++AC_ARG_ENABLE([logging],
++        AS_HELP_STRING([--disable-logging], [disable system logging @<:@default=enabled@:>@]),
++        [], enable_logging=yes)
++AS_IF([test "x$enable_logging" = "xyes"], [
++        AC_DEFINE(ENABLE_LOGGING, [1], [System logging.])
++])
++
++AC_ARG_ENABLE([debug],
++        AS_HELP_STRING([--enable-debug], [enable debug messages @<:@default=disabled@:>@]),
++        [], [enable_debug=no])
++AS_IF([test "x$enable_debug" = "xyes"], [
++        AC_DEFINE(ENABLE_DEBUG, [1], [Debug messages.])
++])
++
++AC_ARG_ENABLE([destructive],
++        AS_HELP_STRING([--enable-destructive], [enable destructive functional tests @<:@default=disabled@:>@]),
++        [], [enable_destructive=no])
++AS_IF([test "x$enable_destructive" = "xyes"],
++	[AC_DEFINE([ENABLE_DESTRUCTIVE], [1], [destructive functional tests support])])
++AM_CONDITIONAL([ENABLE_DESTRUCTIVE], [test "x$enable_destructive" = "xyes"])
++
++AC_ARG_ENABLE([test],
++        AS_HELP_STRING([--enable-test], [enable ndctl test command @<:@default=disabled@:>@]),
++        [], [enable_test=$enable_destructive])
++AS_IF([test "x$enable_test" = "xyes"],
++	[AC_DEFINE([ENABLE_TEST], [1], [ndctl test support])])
++AM_CONDITIONAL([ENABLE_TEST], [test "x$enable_test" = "xyes"])
++
++AC_CHECK_DECLS([BUS_MCEERR_AR], [enable_bus_mc_err=yes], [], [[#include <signal.h>]])
++AC_CHECK_DECLS([MAP_SYNC], [enable_map_sync=yes], [], [[#include <linux/mman.h>]])
++
++AS_IF([test "x$enable_bus_mc_err" = "xyes" -a "x$enable_map_sync" = "xyes"],
++	[AC_DEFINE([ENABLE_POISON], [1], [ndctl test poison support])])
++AM_CONDITIONAL([ENABLE_POISON],
++	[test "x$enable_bus_mc_err" = "xyes" -a "x$enable_map_sync" = "xyes"])
++
++PKG_CHECK_MODULES([KMOD], [libkmod])
++PKG_CHECK_MODULES([UUID], [uuid])
++PKG_CHECK_MODULES([JSON], [json-c])
++
++AC_ARG_WITH([bash-completion-dir],
++	AS_HELP_STRING([--with-bash-completion-dir[=PATH]],
++		[Install the bash auto-completion script in this directory. @<:@default=yes@:>@]),
++	[],
++	[with_bash_completion_dir=yes])
++
++if test "x$with_bash_completion_dir" = "xyes"; then
++	PKG_CHECK_MODULES([BASH_COMPLETION], [bash-completion >= 2.0],
++		[BASH_COMPLETION_DIR="`pkg-config --variable=completionsdir bash-completion`"],
++		[BASH_COMPLETION_DIR="$datadir/bash-completion/completions"])
++else
++	BASH_COMPLETION_DIR="$with_bash_completion_dir"
++fi
++
++AC_SUBST([BASH_COMPLETION_DIR])
++AM_CONDITIONAL([ENABLE_BASH_COMPLETION],[test "x$with_bash_completion_dir" != "xno"])
++
++AC_ARG_ENABLE([local],
++        AS_HELP_STRING([--disable-local], [build against kernel ndctl.h @<:@default=system@:>@]),
++        [], [enable_local=yes])
++
++AC_CHECK_HEADERS_ONCE([linux/version.h])
++
++AC_CHECK_FUNCS([ \
++	__secure_getenv \
++	secure_getenv\
++])
++
++PKG_PROG_PKG_CONFIG
++AC_ARG_WITH([systemd-unit-dir],
++	AS_HELP_STRING([--with-systemd-unit-dir[=DIR]],
++		[Directory for systemd service files]),
++	[],
++	[with_systemd_unit_dir=yes])
++
++if test "x$with_systemd_unit_dir" = "xyes"; then
++	def_systemd_unit_dir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)
++	if test "x$def_systemd_unit_dir" = "x"; then
++		AC_MSG_ERROR([systemd support requested but pkg-config unable to query systemd package])
++		with_systemd_unit_dir=no
++	else
++		with_systemd_unit_dir="$def_systemd_unit_dir"
++	fi
++fi
++
++AS_IF([test "x$with_systemd_unit_dir" != "xno"],
++	[AC_SUBST([systemd_unitdir], [$with_systemd_unit_dir])])
++AM_CONDITIONAL([ENABLE_SYSTEMD_UNIT_DIR], [test "x$with_systemd_unit_dir" != "xno"])
++
++AC_ARG_WITH([tmpfilesdir],
++	[AS_HELP_STRING([--with-tmpfilesdir=DIR], [Directory for temporary runtime files])],
++	[tmpfilesdir=$withval],
++	[tmpfilesdir="/run"])
++
++my_CFLAGS="\
++-D DEF_CONF_FILE='\"${sysconfdir}/ndctl/monitor.conf\"' \
++-D DEF_TMPFS_DIR='\"${tmpfilesdir}/ndctl\"' \
++-Wall \
++-Wchar-subscripts \
++-Wformat-security \
++-Wmissing-declarations \
++-Wmissing-prototypes \
++-Wnested-externs \
++-Wpointer-arith \
++-Wshadow \
++-Wsign-compare \
++-Wstrict-prototypes \
++-Wtype-limits \
++-Wmaybe-uninitialized \
++-Wdeclaration-after-statement \
++-Wunused-result \
++-D_FORTIFY_SOURCE=2 \
++-O2
++"
++AC_SUBST([my_CFLAGS])
++
++AC_CONFIG_HEADERS(config.h)
++AC_CONFIG_FILES([
++        Makefile
++        daxctl/lib/Makefile
++        ndctl/lib/Makefile
++        ndctl/Makefile
++        daxctl/Makefile
++        test/Makefile
++        Documentation/ndctl/Makefile
++        Documentation/daxctl/Makefile
++])
++
++AC_OUTPUT
++AC_MSG_RESULT([
++        $PACKAGE $VERSION
++        =====
++
++        prefix:                 ${prefix}
++        sysconfdir:             ${sysconfdir}
++        libdir:                 ${libdir}
++        includedir:             ${includedir}
++	systemd-unit-dir:	${systemd_unitdir}
++        tmpfilesdir:            ${tmpfilesdir}
++
++        compiler:               ${CC}
++        cflags:                 ${CFLAGS}
++        ldflags:                ${LDFLAGS}
++
++        logging:                ${enable_logging}
++        debug:                  ${enable_debug}
++])
+diff -uprN ndctl-62/contrib/80-ndctl.rules ndctl-62.new/contrib/80-ndctl.rules
+--- ndctl-62/contrib/80-ndctl.rules	2018-08-13 20:06:33.000000000 -0400
++++ ndctl-62.new/contrib/80-ndctl.rules	1969-12-31 19:00:00.000000000 -0500
+@@ -1,3 +0,0 @@
+-# do not edit this file, it will be overwritten on update
+-
+-ACTION=="add", KERNEL=="nmem*", RUN+="ndctl-udev $kernel"
+diff -uprN ndctl-62/ndctl/Makefile.am ndctl-62.new/ndctl/Makefile.am
+--- ndctl-62/ndctl/Makefile.am	2018-08-13 20:06:33.000000000 -0400
++++ ndctl-62.new/ndctl/Makefile.am	2018-10-09 11:55:10.411374926 -0400
+@@ -51,8 +51,3 @@ EXTRA_DIST += $(monitor_config_file)
+ if ENABLE_SYSTEMD_UNIT_DIR
+ systemd_unit_DATA = ndctl-monitor.service
+ endif
+-
+-ndctl_udevdir = $(UDEVDIR)
+-ndctl_udev_PROGRAMS = ndctl-udev
+-ndctl_udev_SOURCES = ndctl-udev.c
+-ndctl_udev_LDADD = lib/libndctl.la
+diff -uprN ndctl-62/ndctl/ndctl-udev.c ndctl-62.new/ndctl/ndctl-udev.c
+--- ndctl-62/ndctl/ndctl-udev.c	2018-08-13 20:06:33.000000000 -0400
++++ ndctl-62.new/ndctl/ndctl-udev.c	1969-12-31 19:00:00.000000000 -0500
+@@ -1,150 +0,0 @@
+-/* SPDX-License-Identifier: GPL-2.0 */
+-/* Copyright(c) 2018 Intel Corporation. All rights reserved. */
+-
+-#include <ctype.h>
+-#include <errno.h>
+-#include <fcntl.h>
+-#include <stddef.h>
+-#include <stdio.h>
+-#include <stdlib.h>
+-#include <string.h>
+-#include <sys/stat.h>
+-#include <sys/types.h>
+-#include <ndctl/libndctl.h>
+-
+-/**
+- * mkdir_p
+- *
+- * Copied from util-linux lib/fileutils.c
+- */
+-static int mkdir_p(const char *path, mode_t mode)
+-{
+-	char *p, *dir;
+-	int rc = 0;
+-
+-	if (!path || !*path)
+-		return -EINVAL;
+-
+-	dir = p = strdup(path);
+-	if (!dir)
+-		return -ENOMEM;
+-
+-	if (*p == '/')
+-		p++;
+-
+-	while (p && *p) {
+-		char *e = strchr(p, '/');
+-		if (e)
+-			*e = '\0';
+-		if (*p) {
+-			rc = mkdir(dir, mode);
+-			if (rc && errno != EEXIST)
+-				break;
+-			rc = 0;
+-		}
+-		if (!e)
+-			break;
+-		*e = '/';
+-		p = e + 1;
+-	}
+-
+-	free(dir);
+-	return rc;
+-}
+-
+-static struct ndctl_dimm *find_dimm(struct ndctl_ctx *ctx, const char *devname)
+-{
+-	struct ndctl_bus *bus;
+-	struct ndctl_dimm *dimm;
+-
+-	ndctl_bus_foreach(ctx, bus) {
+-		ndctl_dimm_foreach(bus, dimm) {
+-			if (strcmp(ndctl_dimm_get_devname(dimm), devname) == 0)
+-				return dimm;
+-		}
+-	}
+-	return NULL;
+-}
+-
+-static void ack_shutdown(struct ndctl_dimm *dimm)
+-{
+-	struct ndctl_cmd *cmd;
+-
+-	cmd = ndctl_dimm_cmd_new_ack_shutdown_count(dimm);
+-	if (!cmd)
+-		return;
+-	ndctl_cmd_submit(cmd);
+-	ndctl_cmd_unref(cmd);
+-}
+-
+-static void save_unsafe_shutdown_count(struct ndctl_dimm *dimm,
+-				       const char *devname)
+-{
+-	char *path, *usc, count[16];
+-	unsigned int shutdown;
+-	struct ndctl_cmd *cmd;
+-	int fd;
+-
+-	cmd = ndctl_dimm_cmd_new_smart(dimm);
+-	if (!cmd)
+-		return;
+-
+-	if (ndctl_cmd_submit(cmd))
+-		goto unref_cmd;
+-
+-	shutdown = ndctl_cmd_smart_get_shutdown_count(cmd);
+-	if (shutdown == UINT_MAX)
+-		goto unref_cmd;
+-
+-	if (asprintf(&path, DEF_TMPFS_DIR "/%s", devname) < 0)
+-		goto unref_cmd;
+-
+-	if (mkdir_p(path, 0755))
+-		goto free_path;
+-
+-	if (asprintf(&usc, "%s/usc", path) < 0)
+-		goto free_path;
+-
+-	fd = open(usc, O_WRONLY | O_CREAT, 0644);
+-	if (fd < 0)
+-		goto free_usc;
+-
+-	if (snprintf(count, sizeof(count), "%u\n", shutdown) < 0)
+-		goto close_fd;
+-
+-	if (write(fd, count, strlen(count)) < 0)
+-		goto close_fd;
+-
+- close_fd:
+-	close(fd);
+- free_usc:
+-	free(usc);
+- free_path:
+-	free(path);
+- unref_cmd:
+-	ndctl_cmd_unref(cmd);
+-}
+-
+-int main(int argc, char *argv[])
+-{
+-	struct ndctl_ctx *ctx;
+-	struct ndctl_dimm *dimm = NULL;
+-	const char *devname;
+-
+-	if (argc < 2)
+-		return EINVAL;
+-
+-	devname = argv[1];
+-	if (ndctl_new(&ctx))
+-		return ENOMEM;
+-
+-	dimm = find_dimm(ctx, devname);
+-	if (!dimm)
+-		return ENODEV;
+-
+-	ack_shutdown(dimm);
+-	save_unsafe_shutdown_count(dimm, devname);
+-
+-	ndctl_unref(ctx);
+-	return 0;
+-}
+diff -uprN ndctl-62/ndctl.spec.in ndctl-62.new/ndctl.spec.in
+--- ndctl-62/ndctl.spec.in	2018-08-13 20:06:33.000000000 -0400
++++ ndctl-62.new/ndctl.spec.in	2018-10-09 11:55:10.411374926 -0400
+@@ -110,7 +110,6 @@ make check
+ %postun -n DAX_LNAME -p /sbin/ldconfig
+ 
+ %define bashcompdir %(pkg-config --variable=completionsdir bash-completion)
+-%define udevdir  %(pkg-config --variable=udevdir udev)
+ 
+ %files
+ %defattr(-,root,root)
+@@ -120,8 +119,6 @@ make check
+ %{bashcompdir}/
+ %{_sysconfdir}/ndctl/monitor.conf
+ %{_unitdir}/ndctl-monitor.service
+-%{_udevrulesdir}/80-ndctl.rules
+-%{udevdir}/ndctl-udev
+ 
+ %files -n daxctl
+ %defattr(-,root,root)
diff --git a/SPECS/ndctl.spec b/SPECS/ndctl.spec
new file mode 100644
index 0000000..4b5aa4b
--- /dev/null
+++ b/SPECS/ndctl.spec
@@ -0,0 +1,233 @@
+Name:		ndctl
+Version:	62
+Release:	2%{?dist}
+Summary:	Manage "libnvdimm" subsystem devices (Non-volatile Memory)
+License:	GPLv2
+Group:		System Environment/Base
+Url:		https://github.com/pmem/ndctl
+Source0:	https://github.com/pmem/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
+Patch0:		5c67ce4-ndctl-Revert-ndctl-Create-ndctl-udev-rules-for-dirty-shutdown.patch
+
+Requires:	ndctl-libs%{?_isa} = %{version}-%{release}
+Requires:	daxctl-libs%{?_isa} = %{version}-%{release}
+BuildRequires:	autoconf
+BuildRequires:	asciidoc
+BuildRequires:	xmlto
+BuildRequires:	automake
+BuildRequires:	libtool
+BuildRequires:	pkgconfig
+BuildRequires:	pkgconfig(libkmod)
+BuildRequires:	pkgconfig(libudev)
+BuildRequires:	pkgconfig(uuid)
+BuildRequires:	pkgconfig(json-c)
+BuildRequires:	pkgconfig(bash-completion)
+BuildRequires:	systemd
+
+%description
+Utility library for managing the "libnvdimm" subsystem.  The "libnvdimm"
+subsystem defines a kernel device model and control message interface for
+platform NVDIMM resources like those defined by the ACPI 6+ NFIT (NVDIMM
+Firmware Interface Table).
+
+
+%package -n ndctl-devel
+Summary:	Development files for libndctl
+License:	LGPLv2
+Group:		Development/Libraries
+Requires:	ndctl-libs%{?_isa} = %{version}-%{release}
+
+%description -n ndctl-devel
+The %{name}-devel package contains libraries and header files for
+developing applications that use %{name}.
+
+%package -n daxctl
+Summary:	Manage Device-DAX instances
+License:	GPLv2
+Group:		System Environment/Base
+Requires:	daxctl-libs%{?_isa} = %{version}-%{release}
+
+%description -n daxctl
+The daxctl utility provides enumeration and provisioning commands for
+the Linux kernel Device-DAX facility. This facility enables DAX mappings
+of performance / feature differentiated memory without need of a
+filesystem.
+
+%package -n daxctl-devel
+Summary:	Development files for libdaxctl
+License:	LGPLv2
+Group:		Development/Libraries
+Requires:	daxctl-libs%{?_isa} = %{version}-%{release}
+
+%description -n daxctl-devel
+The %{name}-devel package contains libraries and header files for
+developing applications that use %{name}, a library for enumerating
+"Device DAX" devices.  Device DAX is a facility for establishing DAX
+mappings of performance / feature-differentiated memory.
+
+
+%package -n ndctl-libs
+Summary:	Management library for "libnvdimm" subsystem devices (Non-volatile Memory)
+License:	LGPLv2
+Group:		System Environment/Libraries
+Requires:	daxctl-libs%{?_isa} = %{version}-%{release}
+
+
+%description -n ndctl-libs
+Libraries for %{name}.
+
+%package -n daxctl-libs
+Summary:	Management library for "Device DAX" devices
+License:	LGPLv2
+Group:		System Environment/Libraries
+
+%description -n daxctl-libs
+Device DAX is a facility for establishing DAX mappings of performance /
+feature-differentiated memory. daxctl-libs provides an enumeration /
+control API for these devices.
+
+
+%prep
+%setup -q ndctl-%{version}
+%patch0 -p1
+
+%build
+echo %{version} > version
+./autogen.sh
+%configure --disable-static --disable-silent-rules
+make %{?_smp_mflags}
+
+%install
+%make_install
+find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
+
+%check
+make check
+
+%post -n ndctl-libs -p /sbin/ldconfig
+
+%postun -n ndctl-libs -p /sbin/ldconfig
+
+%post -n daxctl-libs -p /sbin/ldconfig
+
+%postun -n daxctl-libs -p /sbin/ldconfig
+
+%define bashcompdir %(pkg-config --variable=completionsdir bash-completion)
+
+%files
+%license util/COPYING licenses/BSD-MIT licenses/CC0
+%{_bindir}/ndctl
+%{_mandir}/man1/ndctl*
+%{bashcompdir}/
+%{_sysconfdir}/ndctl/monitor.conf
+%{_unitdir}/ndctl-monitor.service
+
+%files -n daxctl
+%license util/COPYING licenses/BSD-MIT licenses/CC0
+%{_bindir}/daxctl
+%{_mandir}/man1/daxctl*
+
+%files -n ndctl-libs
+%doc README.md
+%license COPYING licenses/BSD-MIT licenses/CC0
+%{_libdir}/libndctl.so.*
+
+%files -n daxctl-libs
+%doc README.md
+%license COPYING licenses/BSD-MIT licenses/CC0
+%{_libdir}/libdaxctl.so.*
+
+%files -n ndctl-devel
+%license COPYING
+%{_includedir}/ndctl/
+%{_libdir}/libndctl.so
+%{_libdir}/pkgconfig/libndctl.pc
+
+%files -n daxctl-devel
+%license COPYING
+%{_includedir}/daxctl/
+%{_libdir}/libdaxctl.so
+%{_libdir}/pkgconfig/libdaxctl.pc
+
+
+%changelog
+* Tue Oct 09 2018 Jeff Moyer <jmoyer@redhat.com - 62-2.el8
+- Remove faulty udev rule
+- Resolves: bz#1637624
+
+* Thu Aug 23 2018 Jeff Moyer <jmoyer@redhat.com> - 62-1
+- rebase to v62
+- Resolves: bz#1567756 bz#1497651 bz#1610650 bz#1511774 bz#1570548
+
+* Mon Apr 23 2018 Dan Williams <dan.j.williams@intel.com> - 60.1-1
+- release v60.1
+
+* Thu Apr 19 2018 Dan Williams <dan.j.williams@intel.com> - 60-1
+- release v60
+
+* Tue Mar 27 2018 Dan Williams <dan.j.williams@intel.com> - 59.3-1
+- release v59.3
+
+* Tue Mar 06 2018 Björn Esser <besser82@fedoraproject.org> - 59.2-2
+- Rebuilt for libjson-c.so.4 (json-c v0.13.1)
+
+* Fri Feb 09 2018 Dan Williams <dan.j.williams@intel.com> - 59.2-1
+- release v59.2
+
+* Fri Feb 09 2018 Dan Williams <dan.j.williams@intel.com> - 59.1-1
+- release v59.1
+
+* Fri Feb 09 2018 Dan Williams <dan.j.williams@intel.com> - 59-1
+- release v59
+
+* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 58.4-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
+
+* Sun Dec 10 2017 Björn Esser <besser82@fedoraproject.org> - 58.4-2
+- Rebuilt for libjson-c.so.3
+
+* Thu Nov 16 2017 Dan Williams <dan.j.williams@intel.com> - 58.4-1
+- release v58.4
+
+* Thu Sep 21 2017 Dan Williams <dan.j.williams@intel.com> - 58.2-1
+- release v58.2
+
+* Fri Sep 08 2017 Dan Williams <dan.j.williams@intel.com> - 58.1-2
+- gate libpmem dependency on x86_64
+
+* Fri Sep 08 2017 Dan Williams <dan.j.williams@intel.com> - 58.1-1
+- add libpmem dependency
+- release v58.1
+
+* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 57.1-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
+
+* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 57.1-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
+
+* Fri Jun 30 2017 Dan Williams <dan.j.williams@intel.com> - 57.1-1
+- Release v57.1
+
+* Sat May 27 2017 Dan Williams <dan.j.williams@intel.com> - 57-1
+- Release v57
+
+* Fri Feb 10 2017 Dan Williams <dan.j.williams@intel.com> - 56-1
+- Release v56
+
+* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 55-2
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
+
+* Fri Oct 21 2016 Dan Williams <dan.j.williams@intel.com> - 55-1
+- release v55
+
+* Fri Aug 05 2016 Dan Williams <dan.j.williams@intel.com> - 54-1
+- add explicit lib version dependencies
+
+* Sat May 28 2016 Dan Williams <dan.j.williams@intel.com> - 53.1-1
+- Fix up tag format vs source url confusion
+
+* Fri May 27 2016 Dan Williams <dan.j.williams@intel.com> - 53-1
+- add daxctl-libs + daxctl-devel packages
+- add bash completion
+
+* Mon Apr 04 2016 Dan Williams <dan.j.williams@intel.com> - 52-1
+- Initial rpm submission to Fedora