# Build CGX without OpenGL or X headers

**URL:** <https://calculix.discourse.group/t/build-cgx-without-opengl-or-x-headers/2779>\
**Category:** CalculiX GraphiX\
**Created:** [June 24, 2025, 11:28am UTC](https://calculix.discourse.group/t/build-cgx-without-opengl-or-x-headers/2779 "2025-06-24T11:28:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![nlesquoy](https://avatars.discourse-cdn.com/v4/letter/n/3ab097/32.png) [@nlesquoy](https://calculix.discourse.group/u/nlesquoy)\
**Post date:** [June 24, 2025, 11:28am UTC](https://calculix.discourse.group/t/build-cgx-without-opengl-or-x-headers/2779/1 "2025-06-24T11:28:06Z")

</div>

Hi,

I want to generate meshes for CCX on a computing cluster for which I do not have access to X headers or OpenGL. In this context, I don’t need to visualization capabilities of CGX. **Is there a way to build CGX without its visualization toolkit and GUI ?**

Thanks in advance for your answers.

---

<div class="post-metadata">

**Author:** ![rsmith](https://yyz2.discourse-cdn.com/free1/user_avatar/calculix.discourse.group/rsmith/32/1684_2.png) [@rsmith](https://calculix.discourse.group/u/rsmith)\
**Post date:** [June 25, 2025, 6:20pm UTC](https://calculix.discourse.group/t/build-cgx-without-opengl-or-x-headers/2779/2 "2025-06-25T18:20:40Z")

</div>

Using the `-bg` flag, you _can_ run `cgx` without a graphics context.  
So that is possible.

You could try _building_ the binary on another machine (with the same hardware architacture) that _does_ have the X11 headers and OpenGL installed, and then statically link it with all the X11 related libraries.
