[Bug driver/67062] -no-pie check breaks cross compilation of GCC [OS X -> Windows]
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67062 --- Comment #2 from Luke Allardyce --- --host=x86_64-w64-mingw32 --target=x86_64-w64-mingw32 or i686-w64-mingw32 I can't remember if it broke on either or both of the above targets and don't have access to an OSX machine any more. --build was left unspecified, the auto detection worked.
[Bug libstdc++/78050] New: Missing define for cross *-mingw32*
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78050 Bug ID: 78050 Summary: Missing define for cross *-mingw32* Product: gcc Version: 7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: lukeallardyce at gmail dot com Target Milestone: --- Created attachment 39849 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=39849&action=edit crossconfig patch Cross compiling for mingw required an extra define for the new overaligned support, patch attached.
[Bug c++/60642] New: abi_tag attribute doesn't work on explicit specializations of class templates
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60642 Bug ID: 60642 Summary: abi_tag attribute doesn't work on explicit specializations of class templates Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: lukeallardyce at gmail dot com This seems to not be working again in trunk? (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55275) template class __attribute((abi_tag("foo"))) test{ }; template class __attribute((abi_tag("foo"))) test; int main() { } abi_test.cpp:4:46: error: redeclaration of ‘class test’ adds abi tag "foo" template class __attribute((abi_tag("foo"))) test; ^ abi_test.cpp:2:37: note: previous declaration here class __attribute((abi_tag("foo"))) test{ };
[Bug c++/60642] Unclear diagnostic with invalid use of abi_tag attribute on explicit instantiation
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60642 --- Comment #2 from Luke Allardyce --- I thought the symbols weren't being mangled with the attribute on the instantiation without the extra tag, but as it turns out they are, sorry.
[Bug c++/60642] Unclear diagnostic with invalid use of abi_tag attribute on explicit instantiation
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60642 --- Comment #3 from Luke Allardyce --- On further inspection it looks like vtable symbols for template classes are not being tagged struct __attribute((abi_tag("test"))) foo { void f(); virtual ~foo(); }; template struct __attribute((abi_tag("test"))) bar { void f(); virtual ~bar(); }; extern template class bar; int main() { foo f; f.f(); bar b; b.f(); } $ g++ test.cpp -c $ nm test.o 0108 s EH_frame1 00c2 s GCC_except_table0 U __Unwind_Resume U __ZN3barB4testIiE1fEv 00a6 S __ZN3barB4testIiEC1Ev U __ZN3barB4testIiED1Ev U __ZN3fooB4test1fEv 008a S __ZN3fooB4testC1Ev U __ZN3fooB4testD1Ev U __ZTV3barIiE U __ZTV3fooB4test U ___gxx_personality_v0 T _main
[Bug c++/65127] New: internal compiler error: tree check: expected tree that contains 'decl minimal' structure, have 'addr_expr' in parsing_nsdmi, at cp/parser.c:18311
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65127 Bug ID: 65127 Summary: internal compiler error: tree check: expected tree that contains 'decl minimal' structure, have 'addr_expr' in parsing_nsdmi, at cp/parser.c:18311 Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: lukeallardyce at gmail dot com void make_item() { static int i{100}; struct { int id{i++}; } item; } int main() { make_item<0>(); } -- g++ -std=c++11 bug.cpp -c bug.cpp: In instantiation of 'void make_item() [with int sz = 0]': bug.cpp:14:16: required from here bug.cpp:9:5: internal compiler error: tree check: expected tree that contains 'decl minimal' structure, have 'addr_expr' in parsing_nsdmi, at cp/parser.c:18311 } item; ^ bug.cpp:9:5: internal compiler error: Abort trap: 6 g++: internal compiler error: Abort trap: 6 (program cc1plus) GCC built from trunk on 2/16
[Bug c++/65127] internal compiler error: tree check: expected tree that contains 'decl minimal' structure, have 'addr_expr' in parsing_nsdmi, at cp/parser.c:18311
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65127 --- Comment #1 from Luke Allardyce --- Sorry, make_item() should be template make_item()
[Bug libstdc++/64064] New: basic_filebuf seekoff return value is unusable for files opened in text mode on Windows
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64064 Bug ID: 64064 Summary: basic_filebuf seekoff return value is unusable for files opened in text mode on Windows Product: gcc Version: 4.9.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: lukeallardyce at gmail dot com Discussion here https://gcc.gnu.org/ml/libstdc++/2014-11/msg00145.html #include #include int main(int, char* argv[]) { using traits = std::filebuf::traits_type; using int_type = std::filebuf::int_type; std::filebuf fb; fb.open(argv[1], std::ios::in); while (!traits::eq_int_type(fb.sbumpc(), traits::eof())) std::cout << fb.pubseekoff(0, std::ios::cur, std::ios::in) << ' '; std::cout << '\n'; fb.close(); fb.pubsetbuf(nullptr, 0); fb.open(argv[1], std::ios::in); while (!traits::eq_int_type(fb.sbumpc(), traits::eof())) std::cout << fb.pubseekoff(0, std::ios::cur, std::ios::in) << ' '; } With the following 3-line Windows-style text file: hello world Produces the following: 4 5 6 7 8 9 10 11 12 13 14 15 16 1 2 3 4 5 7 8 9 10 11 12 14 16 On a buffered stream, the value returned by pubseekoff cannot be used to seek back to that point due to the way Windows implements the POSIX read and lseek64 functions (i.e. read performs end of line conversion, lseek64 doesn't). The value is off by one for each unconsumed end of line in the buffer. It is still unclear whether this should be fixed, if possible, by libstdc++ or mingw-w64.
[Bug c++/63151] New: Accessibility error when brace-constructing base class with protected defaulted constructor and member variable
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63151 Bug ID: 63151 Summary: Accessibility error when brace-constructing base class with protected defaulted constructor and member variable Product: gcc Version: 4.9.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: lukeallardyce at gmail dot com struct Foo { protected: Foo() = default; int t; }; struct Bar : public Foo { Bar(): Foo{} { } }; g++ -std=c++1y -c test.cpp test.cpp: In constructor 'Bar::Bar()': test.cpp:4:3: error: 'Foo::Foo()' is protected Foo() = default; ^ test.cpp:12:14: error: within this context Bar(): Foo{} { } The problem seems to be an astral conjunction of the braces, the defaulted base class constructor, and the presence of a member variable in the base class. Removing any one of these gives no error: class Foo { protected: Foo() {} // Fine int t; }; class Foo { protected: Foo() = default; // Also fine }; class Bar : public Foo { Bar(): Foo() { } // Also fine }; Tested on: Linux (Arch): gcc version 4.9.1 (GCC) OSX: gcc version 4.9.1 (MacPorts gcc49 4.9.1_0) Windows: gcc version 4.9.0 (x86_64-win32-seh-rev2, Built by MinGW-W64 project)
[Bug driver/67062] New: -no-pie check breaks cross compilation of GCC [OS X -> Windows]
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67062 Bug ID: 67062 Summary: -no-pie check breaks cross compilation of GCC [OS X -> Windows] Product: gcc Version: 6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: driver Assignee: unassigned at gcc dot gnu.org Reporter: lukeallardyce at gmail dot com Target Milestone: --- When cross building GCC for windows on OS X the -no-pie flag is being passed to the native linker for some of the build tools (e.g. genhooks) which breaks the build, it looks like the flag test is being performed by the cross compiler but the result is used for both the cross linker and the native linker. I can work around it for now by deleting the "BUILD_LDFLAGS += -no-pie" line in the generated gcc/Makefile.