mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-06-01 15:28:21 -04:00
Switch atmosphere's build target to C++20. (#952)
* ams: update to build with gcc10/c++20 * remove mno-outline-atomics * ams: take care of most TODO C++20s * fusee/sept: update for gcc10 * whoosh, your code now uses pre-compiled headers * make: dependency fixes
This commit is contained in:
parent
17b6bcfd37
commit
3a1ccdd919
258 changed files with 723 additions and 804 deletions
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_config.hpp"
|
||||
|
||||
namespace ams::fatal::srv {
|
||||
|
@ -77,21 +78,21 @@ namespace ams::fatal::srv {
|
|||
|
||||
/* Setup messages. */
|
||||
{
|
||||
this->error_msg = u8"Error Code: 2%03d-%04d (0x%x)\n";
|
||||
this->error_msg = "Error Code: 2%03d-%04d (0x%x)\n";
|
||||
|
||||
this->error_desc = u8"An error has occured.\n\n"
|
||||
u8"Please press the POWER Button to restart the console normally, or a VOL button\n"
|
||||
u8"to reboot to a payload (or RCM, if none is present). If you are unable to\n"
|
||||
u8"restart the console, hold the POWER Button for 12 seconds to turn the console off.\n\n"
|
||||
u8"If the problem persists, refer to the Nintendo Support Website.\n"
|
||||
u8"support.nintendo.com/switch/error\n";
|
||||
this->error_desc = "An error has occured.\n\n"
|
||||
"Please press the POWER Button to restart the console normally, or a VOL button\n"
|
||||
"to reboot to a payload (or RCM, if none is present). If you are unable to\n"
|
||||
"restart the console, hold the POWER Button for 12 seconds to turn the console off.\n\n"
|
||||
"If the problem persists, refer to the Nintendo Support Website.\n"
|
||||
"support.nintendo.com/switch/error\n";
|
||||
|
||||
/* If you're running Atmosphere on a quest unit for some reason, talk to me on discord. */
|
||||
this->quest_desc = u8"Please call 1-800-875-1852 for service.\n\n"
|
||||
u8"Also, please be aware that running Atmosphere on a Quest device is not fully\n"
|
||||
u8"supported. Perhaps try booting your device without Atmosphere before calling\n"
|
||||
u8"an official Nintendo service hotline. If you encounter further issues, please\n"
|
||||
u8"contact SciresM#0524 on Discord, or via some other means.\n";
|
||||
this->quest_desc = "Please call 1-800-875-1852 for service.\n\n"
|
||||
"Also, please be aware that running Atmosphere on a Quest device is not fully\n"
|
||||
"supported. Perhaps try booting your device without Atmosphere before calling\n"
|
||||
"an official Nintendo service hotline. If you encounter further issues, please\n"
|
||||
"contact SciresM#0524 on Discord, or via some other means.\n";
|
||||
|
||||
/* TODO: Try to load dynamically? */
|
||||
/* FsStorage message_storage; */
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_debug.hpp"
|
||||
#include "fatal_config.hpp"
|
||||
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_event_manager.hpp"
|
||||
|
||||
namespace ams::fatal::srv {
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_config.hpp"
|
||||
#include "fatal_font.hpp"
|
||||
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_service.hpp"
|
||||
#include "fatal_config.hpp"
|
||||
#include "fatal_repair.hpp"
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_repair.hpp"
|
||||
#include "fatal_service_for_self.hpp"
|
||||
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_scoped_file.hpp"
|
||||
|
||||
namespace ams::fatal::srv {
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_config.hpp"
|
||||
#include "fatal_debug.hpp"
|
||||
#include "fatal_service.hpp"
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_task.hpp"
|
||||
|
||||
#include "fatal_task_error_report.hpp"
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_task_clock.hpp"
|
||||
|
||||
namespace ams::fatal::srv {
|
||||
|
|
|
@ -13,8 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <sys/stat.h>
|
||||
#include <sys/types.h>
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_config.hpp"
|
||||
#include "fatal_task_error_report.hpp"
|
||||
#include "fatal_scoped_file.hpp"
|
||||
|
@ -79,13 +78,13 @@ namespace ams::fatal::srv {
|
|||
std::snprintf(file_path, sizeof(file_path) - 1, "sdmc:/atmosphere/fatal_reports/%011lu_%016lx.log", timestamp, static_cast<u64>(this->context->program_id));
|
||||
ScopedFile file(file_path);
|
||||
if (file.IsOpen()) {
|
||||
file.WriteFormat(u8"Atmosphère Fatal Report (v1.1):\n");
|
||||
file.WriteFormat("Atmosphère Fatal Report (v1.1):\n");
|
||||
file.WriteFormat("Result: 0x%X (2%03d-%04d)\n\n", this->context->result.GetValue(), this->context->result.GetModule(), this->context->result.GetDescription());
|
||||
file.WriteFormat("Program ID: %016lx\n", static_cast<u64>(this->context->program_id));
|
||||
if (strlen(this->context->proc_name)) {
|
||||
file.WriteFormat("Process Name: %s\n", this->context->proc_name);
|
||||
}
|
||||
file.WriteFormat(u8"Firmware: %s (Atmosphère %u.%u.%u-%s)\n", GetFatalConfig().GetFirmwareVersion().display_version, ATMOSPHERE_RELEASE_VERSION, ams::GetGitRevision());
|
||||
file.WriteFormat("Firmware: %s (Atmosphère %u.%u.%u-%s)\n", GetFatalConfig().GetFirmwareVersion().display_version, ATMOSPHERE_RELEASE_VERSION, ams::GetGitRevision());
|
||||
|
||||
if (this->context->cpu_ctx.architecture == CpuContext::Architecture_Aarch32) {
|
||||
file.WriteFormat("General Purpose Registers:\n");
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_config.hpp"
|
||||
#include "fatal_task_power.hpp"
|
||||
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_task_screen.hpp"
|
||||
#include "fatal_config.hpp"
|
||||
#include "fatal_font.hpp"
|
||||
|
@ -213,18 +214,18 @@ namespace ams::fatal::srv {
|
|||
font::AddSpacingLines(0.5f);
|
||||
font::PrintFormatLine( "Program: %016lX", static_cast<u64>(this->context->program_id));
|
||||
font::AddSpacingLines(0.5f);
|
||||
font::PrintFormatLine(u8"Firmware: %s (Atmosphère %u.%u.%u-%s)", config.GetFirmwareVersion().display_version, ATMOSPHERE_RELEASE_VERSION, ams::GetGitRevision());
|
||||
font::PrintFormatLine("Firmware: %s (Atmosphère %u.%u.%u-%s)", config.GetFirmwareVersion().display_version, ATMOSPHERE_RELEASE_VERSION, ams::GetGitRevision());
|
||||
font::AddSpacingLines(1.5f);
|
||||
if (!exosphere::ResultVersionMismatch::Includes(this->context->result)) {
|
||||
font::Print(config.GetErrorDescription());
|
||||
} else {
|
||||
/* Print a special message for atmosphere version mismatch. */
|
||||
font::Print(u8"Atmosphère version mismatch detected.\n\n"
|
||||
u8"Please press the POWER Button to restart the console normally, or a VOL button\n"
|
||||
u8"to reboot to a payload (or RCM, if none is present). If you are unable to\n"
|
||||
u8"restart the console, hold the POWER Button for 12 seconds to turn the console off.\n\n"
|
||||
u8"Please ensure that all Atmosphère components are updated.\n"
|
||||
u8"github.com/Atmosphere-NX/Atmosphere/releases\n");
|
||||
font::Print("Atmosphère version mismatch detected.\n\n"
|
||||
"Please press the POWER Button to restart the console normally, or a VOL button\n"
|
||||
"to reboot to a payload (or RCM, if none is present). If you are unable to\n"
|
||||
"restart the console, hold the POWER Button for 12 seconds to turn the console off.\n\n"
|
||||
"Please ensure that all Atmosphère components are updated.\n"
|
||||
"github.com/Atmosphere-NX/Atmosphere/releases\n");
|
||||
}
|
||||
|
||||
/* Add a line. */
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include <stratosphere.hpp>
|
||||
#include "fatal_task_sound.hpp"
|
||||
|
||||
namespace ams::fatal::srv {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue