diff --git a/rbutil/rbutilqt/rbutilqt.pro b/rbutil/rbutilqt/rbutilqt.pro index 4b170cd01e..e705497b1e 100644 --- a/rbutil/rbutilqt/rbutilqt.pro +++ b/rbutil/rbutilqt/rbutilqt.pro @@ -28,8 +28,11 @@ RBBASE_DIR = $$replace(RBBASE_DIR,/rbutil/rbutilqt,) message("Rockbox Base dir: "$$RBBASE_DIR) # check for system speex. Add a custom rule for pre-building librbspeex if not found. -LIBSPEEX = $$system(pkg-config --libs speex) -!static:!isEmpty(LIBSPEEX) { +LIBSPEEX = $$system(pkg-config --silence-errors --libs speex) +!static:!isEmpty(LIBSPEEX) + # newer versions of speex are split up into libspeex and libspeexdsp. + # avoid checking twice if libspeex is missing. + LIBSPEEX += $$system(pkg-config --silence-errors --libs speexdsp) LIBS += $$LIBSPEEX } !mac { diff --git a/tools/rbspeex/Makefile b/tools/rbspeex/Makefile index 8c46677ce8..87ce08f3e7 100644 --- a/tools/rbspeex/Makefile +++ b/tools/rbspeex/Makefile @@ -33,7 +33,10 @@ endif # don't try to use the systems libspeex when building a static binary. ifndef STATIC -SYS_SPEEX = $(shell pkg-config --libs speex) +SYS_SPEEX = $(shell pkg-config --silence-errors --libs speex) +ifneq ($(SYS_SPEEX),) +SYS_SPEEX += $(shell pkg-config --silence-errors --libs speexdsp) +endif endif # fall back to our own librbspeex if no suitable found.