Skip to content
Permalink
Browse files

mumble.pro: add opus-src/celt and opus-src/include as -isystem headers.

This fixes the build on OS X.

Before this change, 3rdparty/celt-0.7.0-src/libcelt was marked
as a system include path.

Which should be fine.

However, with the aforementioned directory being treated as
a system directory, clang would handle an include statement
such as

    #include <celt.h>

by first checking the non-system directories.

In this case, it would pick opus-src/celt/celt.h.

This lead to bad things happening, such as missing
preprocessor defines, and missing typedefs for CELT's
integer types.

To work around that, mark Opus's header locations as
system include directories as well, so they're ordered
correctly when doing #include.
  • Loading branch information...
mkrautz committed Nov 15, 2015
1 parent 8d2edb8 commit 8ebd51a6545574de1da6c3716c6f35e9fa5f3508
Showing with 4 additions and 0 deletions.
  1. +4 −0 src/mumble/mumble.pro
@@ -353,6 +353,10 @@ unix:!CONFIG(bundled-opus):system(pkg-config --exists opus) {
INCLUDEPATH *= ../../3rdparty/opus-src/celt ../../3rdparty/opus-src/include ../../3rdparty/opus-src/src ../../3rdparty/opus-build/src INCLUDEPATH *= ../../3rdparty/opus-src/celt ../../3rdparty/opus-src/include ../../3rdparty/opus-src/src ../../3rdparty/opus-build/src
DEFINES *= USE_OPUS DEFINES *= USE_OPUS
LIBS *= -lopus LIBS *= -lopus
unix {
QMAKE_CFLAGS *= "-isystem ../../3rdparty/opus-src/celt" "-isystem ../../3rdparty/opus-src/include"
QMAKE_CXXFLAGS *= "-isystem ../../3rdparty/opus-src/celt" "-isystem ../../3rdparty/opus-src/include"
}
} }
} }


0 comments on commit 8ebd51a

Please sign in to comment.
You can’t perform that action at this time.