+ dnl #
+ dnl # ZFS exports dmu_offet_next
+ dnl #
+ AC_CACHE_CHECK([if ZFS exports 'dmu_offset_next'],
+ [lb_cv_dmu_offset_next], [
+ lb_cv_dmu_offset_next="no"
+ AS_IF([grep -q -E "EXPORT_SYMBOL.*\(dmu_offset_next\)" "$zfssrc/module/zfs/dmu.c" 2>/dev/null],
+ [lb_cv_dmu_offset_next="yes"])
+ ])
+ AS_IF([test "x$lb_cv_dmu_offset_next" = "xyes"], [
+ AC_DEFINE(HAVE_DMU_OFFSET_NEXT, 1,
+ [Have dmu_offset_next() exported])
+ ])
+ dnl #
+ dnl # ZFS 2.0 replaced .db_last_dirty / .dr_next with a list_t
+ dnl # and list_node_t named .db_dirty_records / .dr_dbuf_node.
+ dnl #
+ LB_CHECK_COMPILE([if ZFS has 'db_dirty_records' list_t],
+ db_dirty_records, [
+ #include <sys/dbuf.h>
+ ],[
+ dmu_buf_impl_t db;
+ dbuf_dirty_record_t *dr;
+ dr = list_head(&db.db_dirty_records);
+ ],[
+ AC_DEFINE(HAVE_DB_DIRTY_RECORDS_LIST, 1,
+ [Have db_dirty_records list_t])
+ ])