diff --git a/Gir_GstGL.toml b/Gir_GstGL.toml
index 79a9c7c78..c2eb5445d 100644
--- a/Gir_GstGL.toml
+++ b/Gir_GstGL.toml
@@ -15,3 +15,24 @@ external_libraries = [
gstreamer="Gst"
gstreamer-base="GstBase"
gstreamer-video="GstVideo"
+
+[[object]]
+name = "GstGL.GLDisplayEGL"
+status = "generate"
+cfg_condition = "feature = \"egl\""
+ [[object.function]]
+ pattern = ".*"
+ cfg_condition = "feature = \"egl\""
+
+[[object]]
+name = "GstGL.GLDisplayEGLClass"
+status = "generate"
+cfg_condition = "feature = \"egl\""
+
+[[object]]
+name = "GstGL.GL_DISPLAY_EGL_NAME"
+status = "generate"
+cfg_condition = "feature = \"egl\""
+ [[object.constant]]
+ pattern = ".*"
+ cfg_condition = "feature = \"egl\""
diff --git a/gir-files/GstGL-1.0.gir b/gir-files/GstGL-1.0.gir
index 728d48c0b..ae1ebda32 100644
--- a/gir-files/GstGL-1.0.gir
+++ b/gir-files/GstGL-1.0.gir
@@ -2558,8 +2558,70 @@ display's object lock held.
-
-
+
+ the contents of a #GstGLDisplayEGL are private and should only be accessed
+through the provided API
+
+ Create a new #GstGLDisplayEGL using the default EGL_DEFAULT_DISPLAY.
+
+ a new #GstGLDisplayEGL or %NULL
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Attempts to create a new #EGLDisplay from @display. If @type is
+%GST_GL_DISPLAY_TYPE_ANY, then @display must be 0. @type must not be
+%GST_GL_DISPLAY_TYPE_NONE.
+
+ A #EGLDisplay or %EGL_NO_DISPLAY
+
+
+
+
+ a #GstGLDisplayType
+
+
+
+ pointer to a display (or 0)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/gir-files/fix.sh b/gir-files/fix.sh
index 9adfc1af4..5b6527611 100755
--- a/gir-files/fix.sh
+++ b/gir-files/fix.sh
@@ -39,12 +39,6 @@ xmlstarlet ed --pf --inplace \
--delete '//_:record[@name="GLDisplayX11Class"]' \
GstGL-1.0.gir
-# Remove GstDisplayEGL
-xmlstarlet ed --pf --inplace \
- --delete '//_:class[@name="GLDisplayEGL"]' \
- --delete '//_:record[@name="GLDisplayEGLClass"]' \
- GstGL-1.0.gir
-
# Remove GstMemoryEGL
xmlstarlet ed --pf --inplace \
--delete '//_:record[@name="GLMemoryEGL"]' \
diff --git a/gstreamer-gl-sys/Cargo.toml b/gstreamer-gl-sys/Cargo.toml
index e5f2b773a..0d9699572 100644
--- a/gstreamer-gl-sys/Cargo.toml
+++ b/gstreamer-gl-sys/Cargo.toml
@@ -25,6 +25,7 @@ tempdir = "0.3"
[features]
dox = []
+egl = []
[lib]
name = "gstreamer_gl_sys"