about summary refs log tree commit diff
diff options
context:
space:
mode:
authorQuietMisdreavus <grey@quietmisdreavus.net>2017-05-18 22:24:34 -0500
committerQuietMisdreavus <grey@quietmisdreavus.net>2017-05-18 22:24:34 -0500
commitdd0855d44b61a979983ae329eb84d1928b5f7eb7 (patch)
treee203965aa5d498ca6002ac4db2a4fc7e05a0da99
parent4f881065270ee481114faee82ceef251ef9ea2dd (diff)
downloadrust-dd0855d44b61a979983ae329eb84d1928b5f7eb7.tar.gz
rust-dd0855d44b61a979983ae329eb84d1928b5f7eb7.zip
fix casting of PRIO_PGRP
-rw-r--r--src/bootstrap/lib.rs10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs
index a9f53cda7ed..081e1e52645 100644
--- a/src/bootstrap/lib.rs
+++ b/src/bootstrap/lib.rs
@@ -115,17 +115,9 @@ mod job;
 mod job {
     use libc;
 
-    //apparently glibc defines their own enum for this parameter, in a different type
-    #[cfg(not(any(target_env = "musl", target_env = "musleabi", target_env = "musleabihf",
-                  target_os = "emscripten", target_arch = "mips", target_arch = "mipsel")))]
-    const PRIO_PGRP: libc::c_uint = libc::PRIO_PGRP as libc::c_uint;
-    #[cfg(any(target_env = "musl", target_env = "musleabi", target_env = "musleabihf",
-              target_os = "emscripten", target_arch = "mips", target_arch = "mipsel"))]
-    const PRIO_PGRP: libc::c_int = libc::PRIO_PGRP;
-
     pub unsafe fn setup(build: &mut ::Build) {
         if build.config.low_priority {
-            libc::setpriority(PRIO_PGRP, 0, 10);
+            libc::setpriority(libc::PRIO_PGRP as _, 0, 10);
         }
     }
 }