I did
LMMS uses CMake to configure and build the project and both the 1.2.2 and git versions call FIND_PACKAGE(Wine) in the CMakeLists.txt to check for VST support
FIND_PACKAGE(Wine) pulls cmake/modules/FindWine.cmake,
this file differs significantly between the 1.2.2 and git version
1.2.2's FindWine.cmake calls FIND_LIBRARY(WINE_LIBRARY NAMES wine ...), which doesn't make sense for me since there is no such thing as libwine.so, version 1.2.2 was released mid 2020 so I suppose this is deprecated functionality since then.
git LMMS's FindWine.cmake instead searches for winegcc (and wineg++) and then extracts the necessary flags to build for wine from
it, however, currently it does not find winegcc on Gentoo since it searches on /opt/wine-staging, /opt/wine-devel, /opt/wine-stable (Debian and Ubuntu folders for wine) and /usr/lib/wine
while Gentoo's winegcc resides on /etc/eselect/wine, for the sake of eselect shenanigans
simply adding /etc/eselect/wine on the list(APPEND WINE_LOCATIONS ...) line on git LMMS's FindWine.cmake
just works, which deserves a pull request I have already made:
https://github.com/LMMS/lmms/pull/7665