If gluster is disabled in the build, the man page shouldn't contain
information on how to use the gluster block driver.

This patch is best viewed with whitespace changes ignored.

Signed-off-by: Kevin Wolf <kw...@redhat.com>
---
 docs/system/device-url-syntax.rst.inc | 64 ++++++++++++++-------------
 1 file changed, 33 insertions(+), 31 deletions(-)

diff --git a/docs/system/device-url-syntax.rst.inc 
b/docs/system/device-url-syntax.rst.inc
index d55622847a..79270c8709 100644
--- a/docs/system/device-url-syntax.rst.inc
+++ b/docs/system/device-url-syntax.rst.inc
@@ -89,44 +89,46 @@ special URL syntax.
        Currently authentication must be done using ssh-agent. Other
        authentication methods may be supported in future.
 
-``GlusterFS``
-   GlusterFS is a user space distributed file system. QEMU supports the
-   use of GlusterFS volumes for hosting VM disk images using TCP, Unix
-   Domain Sockets and RDMA transport protocols.
+.. only:: not DISABLE_GLUSTERFS
 
-   Syntax for specifying a VM disk image on GlusterFS volume is
+    ``GlusterFS``
+       GlusterFS is a user space distributed file system. QEMU supports the
+       use of GlusterFS volumes for hosting VM disk images using TCP, Unix
+       Domain Sockets and RDMA transport protocols.
 
-   .. parsed-literal::
+       Syntax for specifying a VM disk image on GlusterFS volume is
 
-      URI:
-      
gluster[+type]://[host[:port]]/volume/path[?socket=...][,debug=N][,logfile=...]
+       .. parsed-literal::
 
-      JSON:
-      
'json:{"driver":"qcow2","file":{"driver":"gluster","volume":"testvol","path":"a.img","debug":N,"logfile":"...",
-                                       
"server":[{"type":"tcp","host":"...","port":"..."},
-                                                 
{"type":"unix","socket":"..."}]}}'
+          URI:
+          
gluster[+type]://[host[:port]]/volume/path[?socket=...][,debug=N][,logfile=...]
 
-   Example
+          JSON:
+          
'json:{"driver":"qcow2","file":{"driver":"gluster","volume":"testvol","path":"a.img","debug":N,"logfile":"...",
+                                           
"server":[{"type":"tcp","host":"...","port":"..."},
+                                                     
{"type":"unix","socket":"..."}]}}'
 
-   .. parsed-literal::
+       Example
+
+       .. parsed-literal::
 
-      URI:
-      |qemu_system| --drive file=gluster://192.0.2.1/testvol/a.img,
-                                     
file.debug=9,file.logfile=/var/log/qemu-gluster.log
-
-      JSON:
-      |qemu_system| 'json:{"driver":"qcow2",
-                                "file":{"driver":"gluster",
-                                         "volume":"testvol","path":"a.img",
-                                         
"debug":9,"logfile":"/var/log/qemu-gluster.log",
-                                         
"server":[{"type":"tcp","host":"1.2.3.4","port":24007},
-                                                   
{"type":"unix","socket":"/var/run/glusterd.socket"}]}}'
-      |qemu_system| -drive 
driver=qcow2,file.driver=gluster,file.volume=testvol,file.path=/path/a.img,
-                                            
file.debug=9,file.logfile=/var/log/qemu-gluster.log,
-                                            
file.server.0.type=tcp,file.server.0.host=1.2.3.4,file.server.0.port=24007,
-                                            
file.server.1.type=unix,file.server.1.socket=/var/run/glusterd.socket
-
-   See also http://www.gluster.org.
+          URI:
+          |qemu_system| --drive file=gluster://192.0.2.1/testvol/a.img,
+                                         
file.debug=9,file.logfile=/var/log/qemu-gluster.log
+
+          JSON:
+          |qemu_system| 'json:{"driver":"qcow2",
+                                    "file":{"driver":"gluster",
+                                             "volume":"testvol","path":"a.img",
+                                             
"debug":9,"logfile":"/var/log/qemu-gluster.log",
+                                             
"server":[{"type":"tcp","host":"1.2.3.4","port":24007},
+                                                       
{"type":"unix","socket":"/var/run/glusterd.socket"}]}}'
+          |qemu_system| -drive 
driver=qcow2,file.driver=gluster,file.volume=testvol,file.path=/path/a.img,
+                                                
file.debug=9,file.logfile=/var/log/qemu-gluster.log,
+                                                
file.server.0.type=tcp,file.server.0.host=1.2.3.4,file.server.0.port=24007,
+                                                
file.server.1.type=unix,file.server.1.socket=/var/run/glusterd.socket
+
+       See also http://www.gluster.org.
 
 .. only:: not DISABLE_CURL
 
-- 
2.31.1


Reply via email to