From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 73676 invoked by alias); 11 Dec 2017 01:08:27 -0000 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org Received: (qmail 73643 invoked by uid 48); 11 Dec 2017 01:08:22 -0000 From: "mysecondaccountabc at gmail dot com" To: systemtap@sourceware.org Subject: [Bug runtime/22572] systemtap 3.2 failed to compile on ARM Date: Mon, 11 Dec 2017 01:08:00 -0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: systemtap X-Bugzilla-Component: runtime X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: mysecondaccountabc at gmail dot com X-Bugzilla-Status: WAITING X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: systemtap at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2017-q4/txt/msg00184.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=3D22572 --- Comment #7 from Gustavo Moreira -= -- (In reply to Torsten.Polle from comment #5) > Hi, >=20 > I had a similar problem with gcc 4.5.2 and fixed it as follows. >=20 > --------------------------------- staptree.h > ---------------------------------- > index a376a43..d1e2da4 100644 > @@ -519,9 +519,9 @@ struct print_format: public expression > unsigned width; > unsigned precision; > unsigned flags : 8; > - width_type widthtype : 8; > - precision_type prectype : 8; > - conversion_type type : 8; > + unsigned char widthtype : 8; > + unsigned char prectype : 8; > + unsigned char type : 8; > interned_string literal_string; > bool is_empty() const > { >=20 > Additionally, I build staprun for an ARM target with > arm-unknown-linux-gnueabi-gcc (crosstool-NG 1.12.1 - buildroot 2011.08) > 4.4.3. Here I need an additional patch. >=20 > Hack: std::string is missing. >=20=20=20=20=20 > Provide std::string as part of util.h as it missing in string.h. >=20 > ------------------------------------ util.h > ------------------------------------ > index e642c5e..e4fdae4 100644 > @@ -144,6 +144,15 @@ inline std::string lex_cast(IN const & in) >=20=20 > #if __cplusplus < 201103L > // Older C++0x only had the "long long" implementations, so we cast up. > +# if (__GNUC__ =3D=3D 4 && __GNUC_MINOR__ =3D=3D 4) > +namespace std { > + static std::string to_string(size_t n) { > + std::ostringstream s; > + s << n; > + return s.str(); > + } > +} > +# endif > #define INT_TO_STRING(IN) \ > LEX_CAST_TO_STRING(signed IN, long long) \ > LEX_CAST_TO_STRING(unsigned IN, unsigned long long) >=20 >=20 > Kind Regards, > Torsten Thanks Torsten, awesome.=20 I wonder why it's failing, because it's not due to the CXX11's "Strongly-ty= ped enums" feature. Actually, I've tested it separately and this feature works = with G++ 4.7 (have a look to my response to David@). It seems to be failing insi= de STL.=20 PS: The 8bit bit-field is redundant for char type, but yeah it doesn't hurt= ;) Thanks again, Gus --=20 You are receiving this mail because: You are the assignee for the bug.