extern crate gl_generator; use gl_generator::{Api, Fallbacks, Profile, Registry}; use std::env; use std::fs::File; use std::path::Path; fn main() { let dest = env::var("OUT_DIR").unwrap(); let mut file_gl = File::create(Path::new(&dest).join("gl_bindings.rs")).unwrap(); let gl_extensions = []; let gl_reg = Registry::new(Api::Gl, (3, 3), Profile::Core, Fallbacks::All, gl_extensions); gl_reg .write_bindings(gl_generator::StructGenerator, &mut file_gl) .unwrap(); }