defaults write org.xquartz.X11 enable_iglx -bool true
Note: The error below hasn't been reported to happen on High Sierra. It may or may not be a problem, just haven't had a system to verify. If you have problems, reach out to hpcops@ps.uci.edu!
$ gv
libGL error: No matching fbConfigs or visuals found
libGL error: failed to load driver: swrast
[xcb] Unknown sequence number while processing queue
[xcb] Most likely this is a multi-threaded client and XInitThreads has not been called
[xcb] Aborting, sorry about that.
gview.exe: xcb_io.c:259: poll_for_event: Assertion `!xcb_xlib_threads_sequence_lost' failed.
Abort
$
For one user that is running El Capitan or Mojave here is the fix
defaults write org.macosforge.xquartz.X11 enable_iglx -bool true
OR
sudo defaults write org.macosforge.xquartz.X11 enable_iglx -bool true