interface: Fix macOS build (#485)
* Compile macOS interface with clang * Fix OpenGL dependency on macOS
This commit is contained in:
parent
599c981481
commit
1cec82613b
|
@ -44,14 +44,14 @@ jobs:
|
|||
cd desmume/src/frontend/interface/
|
||||
meson build
|
||||
env:
|
||||
CC: gcc-10
|
||||
CXX: g++-10
|
||||
CC: clang
|
||||
CXX: clang++
|
||||
|
||||
- name: Build - ninja
|
||||
run: ninja -C desmume/src/frontend/interface/build
|
||||
env:
|
||||
CC: gcc-10
|
||||
CXX: g++-10
|
||||
CC: clang
|
||||
CXX: clang++
|
||||
|
||||
- name: Upload artificat
|
||||
uses: actions/upload-artifact@v2
|
||||
|
|
|
@ -40,6 +40,11 @@ else
|
|||
have_jit = false
|
||||
endif
|
||||
|
||||
# Clang refuses to compile with this warning
|
||||
if meson.get_compiler('cpp').get_id() == 'clang'
|
||||
add_global_arguments('-Wno-c++11-narrowing', language: ['c', 'cpp'])
|
||||
endif
|
||||
|
||||
includes = include_directories(
|
||||
'../../../src',
|
||||
'../../../src/libretro-common/include',
|
||||
|
@ -168,7 +173,9 @@ if have_jit
|
|||
]
|
||||
endif
|
||||
|
||||
if dep_gl.found()
|
||||
if host_machine.system() == 'darwin'
|
||||
dependencies += dependency('appleframeworks', modules: 'OpenGL')
|
||||
elif dep_gl.found()
|
||||
dependencies += dep_gl
|
||||
libdesmume_src += [
|
||||
'../../OGLRender.cpp',
|
||||
|
|
|
@ -18,8 +18,13 @@
|
|||
|
||||
#ifndef WIN32
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <OpenAL/al.h>
|
||||
#include <OpenAL/alc.h>
|
||||
#else
|
||||
#include <AL/al.h>
|
||||
#include <AL/alc.h>
|
||||
#endif
|
||||
|
||||
#include "types.h"
|
||||
#include "mic.h"
|
||||
|
|
Loading…
Reference in New Issue