Author: kevans
Date: Sat Mar 28 17:00:38 2020
New Revision: 359397
URL: https://svnweb.freebsd.org/changeset/base/359397

Log:
  zfs: fix -fno-common issues
  
  A similar (or identical?) fix has already landed in OpenZFS.
  
  -fno-common will become the default in GCC10/LLVM11.
  
  MFC after:    3 days

Modified:
  head/cddl/contrib/opensolaris/cmd/zfs/zfs_util.h
  head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.c
  head/cddl/contrib/opensolaris/cmd/zpool/zpool_util.h

Modified: head/cddl/contrib/opensolaris/cmd/zfs/zfs_util.h
==============================================================================
--- head/cddl/contrib/opensolaris/cmd/zfs/zfs_util.h    Sat Mar 28 16:26:47 
2020        (r359396)
+++ head/cddl/contrib/opensolaris/cmd/zfs/zfs_util.h    Sat Mar 28 17:00:38 
2020        (r359397)
@@ -33,7 +33,7 @@ extern "C" {
 
 void * safe_malloc(size_t size);
 void nomem(void);
-libzfs_handle_t *g_zfs;
+extern libzfs_handle_t *g_zfs;
 
 #ifdef __cplusplus
 }

Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.c
==============================================================================
--- head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.c        Sat Mar 28 
16:26:47 2020        (r359396)
+++ head/cddl/contrib/opensolaris/cmd/zpool/zpool_main.c        Sat Mar 28 
17:00:38 2020        (r359397)
@@ -64,6 +64,8 @@
 
 #include "statcommon.h"
 
+libzfs_handle_t *g_zfs;
+
 static int zpool_do_create(int, char **);
 static int zpool_do_destroy(int, char **);
 

Modified: head/cddl/contrib/opensolaris/cmd/zpool/zpool_util.h
==============================================================================
--- head/cddl/contrib/opensolaris/cmd/zpool/zpool_util.h        Sat Mar 28 
16:26:47 2020        (r359396)
+++ head/cddl/contrib/opensolaris/cmd/zpool/zpool_util.h        Sat Mar 28 
17:00:38 2020        (r359397)
@@ -64,7 +64,7 @@ void pool_list_free(zpool_list_t *);
 int pool_list_count(zpool_list_t *);
 void pool_list_remove(zpool_list_t *, zpool_handle_t *);
 
-libzfs_handle_t *g_zfs;
+extern libzfs_handle_t *g_zfs;
 
 #ifdef __cplusplus
 }
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to