diff --git a/ChangeLog b/ChangeLog index 775d72e7eb1..4794e5e3c52 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2017-06-03 Eric Botcazou + + * configure.ac (*-*-linux-android*): Set target_makefile_frag. + * configure: Regenerate. + 2017-05-31 Martin Liska * configure.ac: Add handling of stage2_werror_flags to diff --git a/config/ChangeLog b/config/ChangeLog index 020032b62fa..4d543535007 100644 --- a/config/ChangeLog +++ b/config/ChangeLog @@ -1,3 +1,7 @@ +2017-06-03 Eric Botcazou + + * mt-android: New file. + 2017-02-13 Richard Biener * isl.m4: Remove support for ISL 0.14. diff --git a/config/mt-android b/config/mt-android new file mode 100644 index 00000000000..0db854f81d4 --- /dev/null +++ b/config/mt-android @@ -0,0 +1 @@ +CXXFLAGS_FOR_TARGET += -D_GNU_SOURCE -fexceptions -frtti diff --git a/configure b/configure index 2cbb4b7ab9d..084986f475e 100755 --- a/configure +++ b/configure @@ -6930,6 +6930,9 @@ case "${target}" in nios2-*-elf*) target_makefile_frag="config/mt-nios2-elf" ;; + *-*-linux-android*) + target_makefile_frag="config/mt-android" + ;; *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu) target_makefile_frag="config/mt-gnu" ;; diff --git a/configure.ac b/configure.ac index 82faf06946d..0cf052b2c75 100644 --- a/configure.ac +++ b/configure.ac @@ -2521,6 +2521,9 @@ case "${target}" in nios2-*-elf*) target_makefile_frag="config/mt-nios2-elf" ;; + *-*-linux-android*) + target_makefile_frag="config/mt-android" + ;; *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu) target_makefile_frag="config/mt-gnu" ;; diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 4d9148437d5..1f8ac8a267e 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,7 @@ +2017-06-03 Eric Botcazou + + * src/filesystem/dir.cc (fs::_Dir::advance): Use std::exchange. + 2017-06-02 Jonathan Wakely PR libstdc++/80624 diff --git a/libstdc++-v3/src/filesystem/dir.cc b/libstdc++-v3/src/filesystem/dir.cc index c8457bde102..9aecd8042a5 100644 --- a/libstdc++-v3/src/filesystem/dir.cc +++ b/libstdc++-v3/src/filesystem/dir.cc @@ -146,7 +146,8 @@ fs::_Dir::advance(error_code* ec, directory_options options) int err = std::exchange(errno, 0); const auto entp = readdir(dirp); - std::swap(errno, err); + // std::swap cannot be used with Bionic's errno + err = std::exchange(errno, err); if (entp) {