Bug 1828171

Summary: Wine broke mingw builds due to CR in winepath output
Product: [Fedora] Fedora Reporter: David Woodhouse <dwmw2>
Component: wineAssignee: Michael Cronenworth <mike>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 31CC: andreas.bierfert, besser82, ivazqueznet, jakub, karsten, kasal, mike, panovotn, praiskup, rhbugs
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: wine-5.7-1.fc32 wine-5.7-1.fc31 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-05-01 00:36:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description David Woodhouse 2020-04-27 08:21:25 UTC
Not quite sure how wine is even involved in a mingw cross-build (except that I do use it for *running* the tests, but it doesn't get that far because they don't build).

But last week, from one build to the next, the mingw builds of OpenConnect in CI just stopped working thus:

 ./.libs/lt-bad_dtls_test.c:165:33: warning: missing terminating " character
  165 | const char * EXE_PATH_VALUE   = "Z:\\usr\\i686-w64-mingw32\\sys-root\\mingw\\lib ;Z:\\usr\\i686-w64-mingw32\\sys-root\\mingw\\bin ;";
      |                                 ^

There are actually CR characters in that string, before each semicolon.

Last working build: 
https://gitlab.com/openconnect/openconnect/-/jobs/522413511

First failing build, only a few minutes later.
https://gitlab.com/openconnect/openconnect/-/jobs/523380153

Comparing the builds, the *only* difference in the environment is that the failing one has wine 5.6 while the working one has wine 5.5.

I can reproduce this on Fedora 31 by just cloning the openconnect git tree and building it with mingw.

Comment 1 David Woodhouse 2020-04-27 08:24:10 UTC
This could well be a libtool problem, as those files are generated by libtool.

Comment 2 David Woodhouse 2020-04-27 08:38:33 UTC
Downgrading wine to 4.17 (since dnf wouldn't give me 5.5) fixes it on my Fedora 31 system.
Remove wine, and it still works fine.
Install wine 5.6 again, and it breaks again.

Removing just the 'wine' package and/or disabling binfmt_misc doesn't fix it.

Removing wine-common makes it spit out this warning:
libtool:   error: Could not determine the host path corresponding to
libtool:   error:   '/home/dwmw2/openconnect/.libs'
libtool:   error: Continuing, but uninstalled executables may not work.
libtool:   error: Could not determine the host path corresponding to
libtool:   error:   '/usr/x86_64-w64-mingw32/sys-root/mingw/lib:/usr/x86_64-w64-mingw32/sys-root/mingw/bin:/home/dwmw2/openconnect/.libs'
libtool:   error: Continuing, but uninstalled executables may not work.

... but it does actually build.

Comment 3 David Woodhouse 2020-04-27 09:44:02 UTC
Aha, it's "winepath", which started emitting Windows line endings that libtool doesn't expect.

With wine 5.6:
$ winepath -w . | hexdump -C
00000000  5a 3a 5c 68 6f 6d 65 5c  64 77 6d 77 32 5c 6f 70  |Z:\home\dwmw2\op|
00000010  65 6e 63 6f 6e 6e 65 63  74 5c 2e 0d 0a           |enconnect\...|
0000001d

With 5.0:
$ winepath -w . | hexdump -C
00000000  5a 3a 5c 68 6f 6d 65 5c  64 77 6d 77 32 5c 6f 70  |Z:\home\dwmw2\op|
00000010  65 6e 63 6f 6e 6e 65 63  74 5c 2e 0a              |enconnect\..|
0000001c

Comment 4 Michael Cronenworth 2020-04-27 13:33:08 UTC
Thanks for the info, David. I'm trying to get wine-mono 5.0.0 built in order to get wine 5.7 pushed.

Comment 5 Fedora Update System 2020-04-27 18:09:02 UTC
FEDORA-2020-bd25c9ee79 has been submitted as an update to Fedora 32. https://bodhi.fedoraproject.org/updates/FEDORA-2020-bd25c9ee79

Comment 6 Fedora Update System 2020-04-27 18:09:35 UTC
FEDORA-2020-1ab58b829d has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2020-1ab58b829d

Comment 7 Fedora Update System 2020-04-28 03:24:02 UTC
FEDORA-2020-bd25c9ee79 has been pushed to the Fedora 32 testing repository.
In short time you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-bd25c9ee79`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-bd25c9ee79

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 8 Fedora Update System 2020-04-28 03:52:15 UTC
FEDORA-2020-1ab58b829d has been pushed to the Fedora 31 testing repository.
In short time you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-1ab58b829d`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-1ab58b829d

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 9 Fedora Update System 2020-05-01 00:36:26 UTC
FEDORA-2020-bd25c9ee79 has been pushed to the Fedora 32 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 10 Fedora Update System 2020-05-06 03:07:40 UTC
FEDORA-2020-1ab58b829d has been pushed to the Fedora 31 stable repository.
If problem still persists, please make note of it in this bug report.