2
0
mirror of https://github.com/boostorg/build.git synced 2026-02-16 13:22:11 +00:00
Commit Graph

45 Commits

Author SHA1 Message Date
NeroBurner
3a8593fa9e Handle spaces in CXX path in config_toolset.bat (#13)
Surround the `CXX` path with double quotes to support spaces in the path.
Otherwise if the `CXX` variable is set to a path containing spaces like

```
C:/Program Files (x86)/Microsoft Visual Studio/2017/BuildTools/VC/Tools/MSVC/14.16.27023/bin/Hostx64/x64/cl.exe
```

the following error message is printed:

```
'C:/Program' is not recognized as an internal or external command,
operable program or batch file.
```
2021-03-26 20:02:30 -05:00
Tanzinul Islam
c7016328c3 Update "borland" toolset to bcc32c for building B2 (#680)
For bootstrapping `b2` itself, the current `borland` toolset is broken
now as `bcc32.exe` doesn't support C++11. Update that toolset to use
the Clang-based `bcc32c.exe`, which has largely the same cmdline args.
2020-12-14 11:36:54 -06:00
Rene Rivera
2a7844ee35 As we are using std lib we need exception handling in msvc.
fixes #654
2020-09-13 09:17:07 -05:00
Gei0r
1c3636e8ed Enable building with clang on Windows (#651) 2020-09-07 20:01:18 -05:00
Nikita Kniazev
7fb91652ca Parallel B2 engine compilation on MSVC (#598) 2020-05-08 22:43:50 -05:00
Nikita Kniazev
f3f2b103d4 Fix config_toolset.bat VC14 flags (#595) 2020-05-06 20:52:04 -05:00
Nikita Kniazev
ae6f588f92 Replace /Ox with /O2 and remove /Zi (#572)
Reduces b2 executable size for 60% (1174KiB vs 465KiB)

/O2 is essentially /Ox /GF /Gy
/Zi implies /debug which disables /opt optimizations
2020-04-19 17:17:39 -05:00
Nikita Kniazev
c84805991d Build B2 using native arch MSVC (#565) 2020-04-18 13:06:03 -05:00
Rene Rivera
8e3edfb0d6 Remove temp debug echo-s. 2020-03-31 22:16:18 -05:00
Rene Rivera
f414639736 Remove vc11 engine build. 2020-03-31 21:47:38 -05:00
Rene Rivera
24626819c2 Temp: print config_toolset execution. 2020-03-31 20:15:50 -05:00
Rene Rivera
d799bcc52a Avoid warning from STL during build on msvc14. 2020-03-30 22:33:19 -05:00
Rene Rivera
cf21e34e70 Fix msvc compile, lib links must be last.
[skip travis]
2019-04-03 07:19:32 -05:00
Rene Rivera
76663ef722 Cleanup of Windows build scripts.
[skip travis]
2019-04-02 23:25:36 -05:00
Rene Rivera
b2c553914a Don't run compiler on config.
[skip travis]
2019-04-02 16:30:35 -05:00
Rene Rivera
eb92f67532 Remove need to define YY syms in build scripts. 2019-04-01 17:19:48 -05:00
Rene Rivera
053afa5e05 Tweak path extract syntax to work with mingw.
[skip travis]
2019-03-22 21:22:26 -05:00
Rene Rivera
0ce41b8bd6 Some debugging of FOR.
[skip travis]
2019-03-22 20:12:51 -05:00
Rene Rivera
f5587c1f91 Undo command extensions, as it just fails.
[skip travis]
2019-03-22 09:27:30 -05:00
Rene Rivera
9e499e300a Maybe cmd extensions are disabled? 2019-03-22 08:06:22 -05:00
Rene Rivera
505c8eacfd Try and fix dirname logic for mingw CXX.
[skip travis]
2019-03-21 21:52:42 -05:00
Rene Rivera
0d993b8d1b Fix bad var name in for loop.
[skip travis]
2019-03-21 21:02:08 -05:00
Rene Rivera
b03828cc3c Fix mingw by the silly addition to PATH.
[skip travis]
2019-03-21 21:00:30 -05:00
Rene Rivera
20f7efd042 Fix incorrect vc142 label.
[skip travis]
2019-03-21 19:16:33 -05:00
Rene Rivera
8c0faa3796 Attempt to fix vc2019 build. 2019-03-21 19:11:01 -05:00
Rene Rivera
3eceb036ef Internalize build options into config header. 2019-03-21 09:53:02 -05:00
Rene Rivera
5ee7ebcf16 Merge origin/develop 2019-03-20 19:38:36 -05:00
Thomas Kent
0a93cc2b97 Added support for actually building with msvc-14.2 2019-03-01 16:06:03 -06:00
Tanzinul Islam
ccb9a97efb Fix build with Embarcadero C++ Builder ("borland" toolset) (#398)
* Fix "bootstrap.bat borland" failing to find label "Test_Path"

If an override toolset is given in the `bootstrap.bat` command-line,
`bootstrap.bat` -> `src/engine/build.bat` bypasses loading
`src/engine/guess_toolset.bat` entirely. Later on the call to
`Test_Path` from `build.bat` -> `config_toolset.bat` fails to find that
label.

Fix this by making a new parameterized entry-point `test_path` inside
`guess_toolset.bat` for this caller in `config_toolset.bat`.

Fixes: #382.

* Handle spaces in C++Builder toolchain path

Nowadays a default installation goes into %PROGRAMFILES%, e.g.
"C:\Program Files (x86)\Embarcadero\Studio\20.0\Bin".

* Add "-Nd" before "/D"-options for bcc32.exe

The preprocessor of the old Borland/C++Builder compiler (bcc32.exe) by
default does not accept preprocessor statements of the form:

    #if SYMBOL_NAME

where `SYMBOL_NAME` was `#define`-ed without a value. It insists on the
`#if defined(SYMBOL_NAME)` or `#ifdef SYMBOL_NAME` forms (emitting error
E2188 "expression syntax"). The workaround is to specify the `-Nd`
option before the offending `/D` options, which effectively provides a
value of "1" to the symbols being #define-ed. Apply this workaround in
the recipes of `bjam` and `b2` to satisfy the preprocessor.

The alternative here would be to migrate to the Clang-based (and much
more standard-compliant) bcc32c.exe, but that would be a more involved
change.

* Separate :Guess_Yacc logic from :Guess_Toolset in build.bat

This was an existing benign issue introduced in 00c2358, but it became
apparent after 9339693.
2019-02-26 19:32:53 -06:00
Rene Rivera
f8f885f8cd Add debug output for script calls.
[skip travis]
2018-11-18 20:37:39 -06:00
Rene Rivera
641b56f890 Allow customizing the compiler even for detected ones.
This allows using multiple cofigurations and alternate installs.
[skip travis]
2018-11-18 17:29:20 -06:00
Rene Rivera
a1132974f3 See if we need a path to make -o option work.
[skip travis]
2018-11-15 23:09:20 -06:00
Rene Rivera
a43f819176 Fix inverted CXX env test.
[skip travis]
2018-11-15 21:37:20 -06:00
Rene Rivera
a699fd9dc5 Add CXX for mingw building.
[skip travis]
2018-11-15 21:29:38 -06:00
Rene Rivera
b1ec9524e1 Fill in the options for non-msvc compilers. [skip ci] 2018-10-23 21:37:25 -05:00
Rene Rivera
bed38148c0 Rrewrite config to hopefully avoid missing label errors. 2018-10-23 21:17:46 -05:00
Rene Rivera
de23ca928f Compile fixes for Windows (msvc). 2018-10-22 22:15:06 -05:00
Jürgen Hunold
e07c805e31 Workaround vsdevcmd_end.bat switching to %USERPROFILE%\Source
Fixs #236 and PR #252
2017-11-17 13:54:46 +01:00
Ion Gaztañaga
5377199473 More fixes for MSVC 7.1:
- Add missing WINVER=0x0501 and _WIN32_WINNT=0x0501 to config_toolset.bat
- Add needed -D_WIN32_WINNT=0x0501 for vc7 to fix unresolved symbols
- Added alternatives to va_copy and vsnprintf in debugger.c
- Add missing fix from previous patch in strings.c
2017-08-13 22:24:57 -05:00
Refael Ackermann
99b01d131b extra ERRORLEVEL reset 2017-08-09 09:03:05 -05:00
Refael Ackermann
6f63489198 Try to detect VS2017 using vswhere 2017-05-06 12:08:53 -04:00
Rene Rivera
838c622939 Remove use of VS2017 detection helpers in favor of ENV+path detection. 2017-04-05 16:50:53 -05:00
Arkadiy Shapkin
d2ff572c23 Fix error handling for VS2017 detection in GetCLPath.ps1. Closes #186 2017-03-30 12:32:13 +03:00
Thomas Kent
33024da7a8 Found changes moved out of build.bat 2017-03-20 21:45:31 -05:00
Arkadiy Shapkin
00c23580af Check Visual Studio 2017+ version in script
* Fixed `build.bat` stack overflow on some machines by splitting up to several files
* CSharp script simplified and now will check VC++ toolset version
2017-03-19 00:59:40 +08:00