mirror of
https://github.com/italicsjenga/winit-sonoma-fix.git
synced 2024-12-23 22:01:31 +11:00
Switch to new I/O in build.rs
This commit is contained in:
parent
183d96b44e
commit
896c8b11af
|
@ -1,7 +1,7 @@
|
||||||
[package]
|
[package]
|
||||||
|
|
||||||
name = "glutin"
|
name = "glutin"
|
||||||
version = "0.0.7"
|
version = "0.0.8"
|
||||||
authors = ["tomaka <pierre.krieger1708@gmail.com>"]
|
authors = ["tomaka <pierre.krieger1708@gmail.com>"]
|
||||||
description = "Cross-plaform OpenGL context provider. Important: the crates.io only supports Windows and Linux for the moment."
|
description = "Cross-plaform OpenGL context provider. Important: the crates.io only supports Windows and Linux for the moment."
|
||||||
keywords = ["windowing", "opengl"]
|
keywords = ["windowing", "opengl"]
|
||||||
|
|
7
build.rs
7
build.rs
|
@ -1,13 +1,14 @@
|
||||||
#![feature(old_io,old_path,os)]
|
#![feature(path)]
|
||||||
extern crate gl_generator;
|
extern crate gl_generator;
|
||||||
extern crate khronos_api;
|
extern crate khronos_api;
|
||||||
|
|
||||||
use std::env;
|
use std::env;
|
||||||
use std::old_io::File;
|
use std::fs::File;
|
||||||
|
use std::path::PathBuf;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
let target = env::var("TARGET").unwrap();
|
let target = env::var("TARGET").unwrap();
|
||||||
let dest = Path::new(env::var("OUT_DIR").unwrap());
|
let dest = PathBuf::new(&env::var("OUT_DIR").unwrap());
|
||||||
|
|
||||||
if target.contains("windows") {
|
if target.contains("windows") {
|
||||||
let mut file = File::create(&dest.join("wgl_bindings.rs")).unwrap();
|
let mut file = File::create(&dest.join("wgl_bindings.rs")).unwrap();
|
||||||
|
|
Loading…
Reference in a new issue