aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--LICENSE2
-rw-r--r--README21
-rw-r--r--build/root.build3
-rw-r--r--buildfile8
-rw-r--r--manifest8
-rw-r--r--msvc-common/msvc-filter.cxx10
6 files changed, 36 insertions, 16 deletions
diff --git a/LICENSE b/LICENSE
index 2cf3738..61ddaac 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,6 +1,6 @@
MIT License
-Copyright (c) 2014-2020 the build2 authors (see the AUTHORS file).
+Copyright (c) 2014-2021 the build2 authors (see the AUTHORS file).
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
diff --git a/README b/README
index eb244c0..def94df 100644
--- a/README
+++ b/README
@@ -1,2 +1,19 @@
-Note that while this project is called msvc-linux, you may be able to use it
-on other UNIX-like systems supported by Wine.
+Cross-compiling from UNIX to Windows with MSVC using Wine.
+
+NOTE: we no longer recommend using this approach unless you absolutely
+must. Firstly, the whole setup is very hacky and brittle (and potentially
+illegal: we were told it's against the license to run MSVC like that) and
+often doesn't work with the most recent versions of MSVC (because Wine hasn't
+caught up on the new APIs yet). Also, there are edge cases where build2 does
+not fully support this "mode" of running MSVC. It works for projects that
+don't do anything unusual, but, for example, you won't be able to build
+anything that requires MASM. We believe if you must test with MSVC, the only
+sane way to do it is with a Windows VM (which is what we do on our CI). If you
+just need to test that your code builds for Windows, another option is to use
+Clang and the LLVM linker (lld-link) as a cross-compiler. With this approach
+you will only need to copy the MSVC standard library and PlatformSDK (and
+won't need to mess with Wine).
+
+See INSTALL for setup instructions. Note that while this project is called
+msvc-linux, you may be able to use it on other UNIX-like systems supported
+by Wine.
diff --git a/build/root.build b/build/root.build
index f572d78..badb530 100644
--- a/build/root.build
+++ b/build/root.build
@@ -10,4 +10,7 @@ ixx{*}: extension = ixx
txx{*}: extension = txx
cxx{*}: extension = cxx
+if ($cxx.id == 'gcc')
+ cxx.coptions += -Wno-maybe-uninitialized -Wno-free-nonheap-object # libbutl
+
cxx.poptions =+ "-I$out_root" "-I$src_root"
diff --git a/buildfile b/buildfile
index 04c7053..e9e2c10 100644
--- a/buildfile
+++ b/buildfile
@@ -9,10 +9,10 @@ sh{*}:
install = bin/
}
-./: msvc-common/exe{msvc-filter} \
- sh{cl-* lib-* link-* mt-* rc-*} \
- sh{msvc-** -msvc-common/msvc-filter*} \
- doc{INSTALL LICENSE AUTHORS NEWS README} \
+./: msvc-common/exe{msvc-filter} \
+ sh{cl-* lib-* link-* mt-* rc-*} \
+ sh{msvc-** -msvc-common/msvc-filter*} \
+ doc{INSTALL NEWS README} legal{LICENSE AUTHORS} \
manifest
msvc-common/
diff --git a/manifest b/manifest
index f03688b..72d1095 100644
--- a/manifest
+++ b/manifest
@@ -1,6 +1,6 @@
: 1
name: msvc-linux
-version: 0.13.0-a.0.z
+version: 0.17.0-a.0.z
project: build2
summary: MS Visual C++ as cross-compiler driver scripts
license: MIT
@@ -14,6 +14,6 @@ src-url: https://git.build2.org/cgit/etc/msvc-linux/tree/
email: users@build2.org
build-warning-email: builds@build2.org
requires: c++14
-depends: * build2 >= 0.13.0-
-depends: * bpkg >= 0.13.0-
-depends: libbutl [0.13.0-a.0.1 0.13.0-a.1)
+depends: * build2 >= 0.16.0-
+depends: * bpkg >= 0.16.0-
+depends: libbutl [0.17.0-a.0.1 0.17.0-a.1)
diff --git a/msvc-common/msvc-filter.cxx b/msvc-common/msvc-filter.cxx
index b2db75f..feff7d8 100644
--- a/msvc-common/msvc-filter.cxx
+++ b/msvc-common/msvc-filter.cxx
@@ -14,11 +14,11 @@
#include <system_error>
#include <unordered_map>
-#include <libbutl/path.mxx> // path::traits::realize()
-#include <libbutl/utility.mxx> // alpha(), throw_*_error()
-#include <libbutl/process.mxx>
-#include <libbutl/optional.mxx>
-#include <libbutl/fdstream.mxx>
+#include <libbutl/path.hxx> // path::traits::realize()
+#include <libbutl/utility.hxx> // alpha(), throw_*_error()
+#include <libbutl/process.hxx>
+#include <libbutl/optional.hxx>
+#include <libbutl/fdstream.hxx>
#include <msvc-common/version.hxx>