]> git.lizzy.rs Git - rust.git/commitdiff
rustc_back: Learn about i686-pc-windows-msvc
authorAlex Crichton <alex@alexcrichton.com>
Thu, 25 Jun 2015 22:32:10 +0000 (15:32 -0700)
committerAlex Crichton <alex@alexcrichton.com>
Sat, 27 Jun 2015 20:02:18 +0000 (13:02 -0700)
This commit adds the i686-pc-windows-msvc triple to the compiler's repertoire of
triples to prepare for targeting 32-bit MSVC.

src/librustc_back/target/i686_pc_windows_msvc.rs [new file with mode: 0644]
src/librustc_back/target/mod.rs

diff --git a/src/librustc_back/target/i686_pc_windows_msvc.rs b/src/librustc_back/target/i686_pc_windows_msvc.rs
new file mode 100644 (file)
index 0000000..d71aa15
--- /dev/null
@@ -0,0 +1,27 @@
+// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use target::Target;
+
+pub fn target() -> Target {
+    let mut base = super::windows_msvc_base::opts();
+    base.cpu = "i686".to_string();
+
+    Target {
+        data_layout: "e-p:32:32-f64:64:64-i64:64:64-f80:32:32-n8:16:32".to_string(),
+        llvm_target: "i686-pc-windows-msvc".to_string(),
+        target_endian: "little".to_string(),
+        target_pointer_width: "32".to_string(),
+        arch: "x86".to_string(),
+        target_os: "windows".to_string(),
+        target_env: "msvc".to_string(),
+        options: base,
+    }
+}
index 402fbcd8d8d8e6ebf74007072b47f546314cb38b..a42f861d19056d6d55d00ec613d243ede9a58693 100644 (file)
@@ -381,7 +381,8 @@ macro_rules! load_specific {
             x86_64_pc_windows_gnu,
             i686_pc_windows_gnu,
 
-            x86_64_pc_windows_msvc
+            x86_64_pc_windows_msvc,
+            i686_pc_windows_msvc
         );