Remove HAVE_ZPL from commands and libraries

Thanks to the previous few commits we can now build all of the
user space commands and libraries with support for the zpl.
This commit is contained in:
Brian Behlendorf
2010-12-16 15:11:40 -08:00
parent 9a616b5d17
commit b4ead57cfb
7 changed files with 0 additions and 139 deletions
-10
View File
@@ -716,9 +716,7 @@ zpool_do_create(int argc, char **argv)
(strcmp(mountpoint, ZFS_MOUNTPOINT_LEGACY) != 0 &&
strcmp(mountpoint, ZFS_MOUNTPOINT_NONE) != 0)) {
char buf[MAXPATHLEN];
#ifdef HAVE_ZPL
DIR *dirp;
#endif
if (mountpoint && mountpoint[0] != '/') {
(void) fprintf(stderr, gettext("invalid mountpoint "
@@ -743,7 +741,6 @@ zpool_do_create(int argc, char **argv)
mountpoint);
}
#ifdef HAVE_ZPL
if ((dirp = opendir(buf)) == NULL && errno != ENOENT) {
(void) fprintf(stderr, gettext("mountpoint '%s' : "
"%s\n"), buf, strerror(errno));
@@ -766,7 +763,6 @@ zpool_do_create(int argc, char **argv)
goto errout;
}
}
#endif /* HAVE_ZPL */
}
if (dryrun) {
@@ -797,12 +793,8 @@ zpool_do_create(int argc, char **argv)
zfs_prop_to_name(
ZFS_PROP_MOUNTPOINT),
mountpoint) == 0);
#ifdef HAVE_ZPL
if (zfs_mount(pool, NULL, 0) == 0)
ret = zfs_shareall(pool);
#else
ret = 0;
#endif /* HAVE_ZPL */
zfs_close(pool);
}
} else if (libzfs_errno(g_zfs) == EZFS_INVALIDNAME) {
@@ -1579,14 +1571,12 @@ do_import(nvlist_t *config, const char *newname, const char *mntopts,
if ((zhp = zpool_open_canfail(g_zfs, name)) == NULL)
return (1);
#if HAVE_ZPL
if (zpool_get_state(zhp) != POOL_STATE_UNAVAIL &&
!(flags & ZFS_IMPORT_ONLY) &&
zpool_enable_datasets(zhp, mntopts, 0) != 0) {
zpool_close(zhp);
return (1);
}
#endif /* HAVE_ZPL */
zpool_close(zhp);
return (0);