winegcc attempts to guess the libdir which doesn't work with the prefixed installation directories. The default symlinks for plain old wine's libdir work with winegcc's autodetection code, however no other symlinks work (ie for /usr/bin/winegcc-2.2 or /usr/bin/winegcc-vanilla, etc). The only consumer that would have really caused a problem for this was www-plugins/pipelight (since we'd be using the -staging variant), but since that was recently removed from the tree, I'm adding this as a reminder to fix this bug, and won't be holding up unmasking of the slotted packaging based on this bug report. The issue is in the get_lib_dir function. I haven't come up with the best way to resolve it yet.
Created attachment 485980 [details, diff] wine-winegcc-verbose.patch NP, I've had a dive into this issue... However I can't seem to reproduce it. The variant winegcc-* wrappers appears to work on my system. I used the attached patch to verify the operation of the get_lib_dir() function.
Created attachment 485982 [details] C test program Test program - C source code.
Created attachment 485992 [details] winegcc-staging-2.12-variant_build_log Build log from compilation: /usr/bin/winegcc-staging-2.12 -v main.c &> winegcc-staging-2.12-variant_build_log.txt