protonscr

steam-runtime bison package too old to compile wine 4.7+

protonclosed
ValveSoftware/Proton#2742 · opened 2019-05-26 by GloriousEggroll · updated 2019-07-31 · 6 comments · github
GGloriousEggroll 2019-05-26 github

As I regularly make custom builds of proton, I came across this today while attempting to compile 4.9:

configure: error: Your bison version is too old. Please install bison version 3.0 or newer. ../proton/build/makefile_base.mak:755: recipe for target 'obj-wine32/Makefile' failed make[1]: *** [obj-wine32/Makefile] Error 1
So this was apparently a change between wine 4.6 and 4.7:

https://github.com/wine-mirror/wine/commit/a4c93936c9493f7619e1877b522eeb809a390dfe

And when we check the steam runtime version:

vagrant@debian9:~/proton$ docker run steam-proton-dev bash -c "bison --version"
bison (GNU Bison) 2.5

vagrant@debian9:~/proton$ docker run steam-proton-dev32 bash -c "bison --version"
bison (GNU Bison) 2.5

Further investigation after reverting the commit mentioned above also shows this error when compiling:

../../../../proton/wine/tools/widl/parser.y:321.9-19: %define variable `parse.error' is not used
tools/winebuild/winebuild -w -o dlls/netapi32/libnetapi32.def --def -m32 --export \
  ../../proton/wine/dlls/netapi32/netapi32.spec
make[1]: *** [Makefile:395: parser.tab.h] Error 1

and later also:

../../../../proton/wine/dlls/d3dcompiler_38/../d3dcompiler_43/hlsl.y:906.9-19: %define variable `parse.error' is not used
make[1]: *** [Makefile:541: hlsl.tab.h] Error 1

So... I figured already there may be more files affected by this change:

$ grep -rnw . -e "define parse.error verbose"

./dlls/wbemprox/wql.y:190:%define parse.error verbose

Caused by these commits:
https://github.com/wine-mirror/wine/commit/5ea4d5971bff3430c29f1da31166b0a2565347ab
https://github.com/wine-mirror/wine/commit/2d27c13d5ea76ec80e2a67272c8eafe8527e6af0
https://github.com/wine-mirror/wine/commit/6d4cdeb658e1cfd7c73643f674a0043006970b44

So for future proofing, you'll either have to revert the commits, or update the steam runtime, or add bison to the build process.

Just lookin' out for future proofing.

Aaeikum 2019-05-28 github

Yup, good spot. I think the right thing to do would be build bison like we do cmake. (Well the "right" thing to do would be update the Steam runtime, but that's a big ask.)

Ddreamer 2019-05-28 github

Maybe there's also an option of running bison outside of steam runtime/docker images - in Vagrant or on host, just like fontforge is being run right now? (same applies to cmake)

Aaeikum 2019-05-28 github

Using the host's binaries might be an option, yeah. It doesn't strike me as obviously easier/better than just building it.

GGloriousEggroll 2019-05-30 github

I can at least confirm that the debian vagrant image used for proton has bison 3.0.4, might be an easy workaround to remove bison from steamrt-bootstrap.sh and add it to Vagrantfile instead based on dreamer's suggestion

edit: needs to be added to make file, initial comment didnt work

(tfw a debian base package is newer than your runtime, lol)

Aaeikum 2019-07-31 github

Fixed by d7819c7bc5489b4e30c3b0782ccde78c5cd41cd8.

Upstream links