Minor changes for macOS.

This commit is contained in:
Martín Lucas Golini
2022-05-22 00:35:40 -03:00
parent 2b1ff130f0
commit 1be7717196
2 changed files with 8 additions and 2 deletions

View File

@@ -1,6 +1,6 @@
#!/bin/sh
cd $(dirname "$0")
premake4 --file=../../premake4.lua gmake
premake4 --file=../../premake4.lua --with-mojoal gmake
cd ../../make/macosx/
sed -e "s/-Wl,-x//g" -i .make

View File

@@ -1,5 +1,8 @@
#include <eepp/window/backend/SDL2/base.hpp>
#include <eepp/window/backend/SDL2/platformhelpersdl2.hpp>
#include <eepp/system/log.hpp>
using namespace EE::System;
#if EE_PLATFORM == EE_PLATFORM_EMSCRIPTEN
#include <emscripten.h>
@@ -22,7 +25,10 @@ bool PlatformHelperSDL2::openURL( const std::string& url ) {
return true;
#else
#if SDL_VERSION_ATLEAST(2,0,14)
return SDL_OpenURL( url.c_str() ) == 0;
int res = SDL_OpenURL( url.c_str() );
if ( res != 0 )
Log::error( "PlatformHelperSDL2::openURL: Failed with error - %s", SDL_GetError() );
return res == 0;
#else
return false;
#endif