Bug 1846152

Summary: missing static variable constructor calls
Product: Red Hat Enterprise Linux 8 Reporter: Uri Lublin <uril>
Component: mingw-binutilsAssignee: Uri Lublin <uril>
Status: CLOSED NEXTRELEASE QA Contact: SPICE QE bug list <spice-qe-bugs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 8.3CC: ailan, dblechte, elima, fziglio, tpelka, uril
Target Milestone: rcKeywords: Regression
Target Release: 8.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: mingw-binutils-2.30-2.el8 Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-10-29 07:39:15 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:
Bug Depends On:    
Bug Blocks: 1841952    

Description Uri Lublin 2020-06-10 22:26:31 UTC
Description of problem:
Bug on sourceware: https://sourceware.org/bugzilla/show_bug.cgi?id=22762

The reproducer on that bug, static-var.cpp, breaks (shows nothing)
on mingw-binutils-2.30-1 but works with mingw-binutils-2.29.1-1.

The suggested patch on sourceware bug is not part of 2.30-1.

I think this may be related to why when building mingw-virt-viewer with
mingw-binutils-2.30-1 the executable created aborts immediately with the error
  "Unspecified fatal error encountered, aborting"



static-var.cpp:
#include <stdio.h>

class Printer
{
  public:
    Printer()
    {
      printf("Printer()\n");
    }
};

static Printer printer;

int main()
{
  return 0;
}