Error when trying to build boost

When trying to run the bootstrap.bat for boost_1_65 (Windows 10 64bit) I get this error:

C:\Users\User\Source>cl /nologo /RTC1 /Zi /MTd /Fobootstrap/ /Fdbootstrap/ -DNT -DYYDEBUG -wd4996 kernel32.lib advapi32.lib user32.lib /Febootstrap\yyacc0 yyacc.c
yyacc.c
c1: fatal error C1083: Cannot open source file: 'yyacc.c': No such file or directory

When trying to google the yyacc.c it comes up with nothing, so hoping one of you may be able to help, the full error for the bootstrap.log:

**********************************************************************
** Visual Studio 2017 Developer Command Prompt v15.0.26730.10
** Copyright (c) 2017 Microsoft Corporation
**********************************************************************
[vcvarsall.bat] Environment initialized for: 'x86'
###
### Using 'vc141' toolset.
###

C:\Users\\User\Source>if exist bootstrap rd /S /Q bootstrap

C:\Users\\User\Source>md bootstrap

C:\Users\User\Source>cl /nologo /RTC1 /Zi /MTd /Fobootstrap/ /Fdbootstrap/ -DNT -DYYDEBUG -wd4996 kernel32.lib advapi32.lib user32.lib /Febootstrap\yyacc0 yyacc.c
yyacc.c
c1: fatal error C1083: Cannot open source file: 'yyacc.c': No such file or directory
Last edited on
The same Problem here. Any solutions?

I’m afraid I don’t have any solution, but in this post
https://github.com/boostorg/build/issues/236
it’s recommended to execute bootstrap.bat from within the vs2017 native tools command prompt:
BurningEnlightenment wrote:
I can reproduce this failure with powershell and a "plain" cmd, but using the native tools command prompt does work for me, so I'm wondering whether it works for you, too. Maybe this is intentional and just poorly documented


I’d also have a look at boost documentation:
http://www.boost.org/doc/libs/1_65_1/more/getting_started/windows.html
3 - Header-Only Libraries
The first thing many people want to know is, “how do I build Boost?” The good news is that often, there's nothing to build.
Nothing to Build?
Most Boost libraries are header-only: they consist entirely of header files containing templates and inline functions, and require no separately-compiled library binaries or special treatment when linking.

I had the same issue but my compiler was MinGW.
I found the solution here https://gist.github.com/sim642/29caef3cc8afaa273ce6
Try to do the same, but instead
bootstrap.bat mingw
do
bootstrap.bat <your compiler (supported by bootstrap)>
e.g.
bootstrap.bat msvc
Topic archived. No new replies allowed.