qt4-select.patch 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. https://gist.github.com/karolherbst/fb9e3d8f6ba05f1f5d54
  2. For use until upstream ever accepts this patch or fixes it themsleves
  3. --- configure.ac.orig 2015-03-01 02:28:48.983932684 +0100
  4. +++ configure.ac 2015-03-01 02:41:29.641927072 +0100
  5. @@ -3709,7 +3709,8 @@
  6. ])
  7. ])
  8. AS_IF([test "${enable_qt}" != "no"], [
  9. - PKG_CHECK_MODULES([QT], [Qt5Core >= 5.1.0 Qt5Widgets Qt5Gui], [
  10. + AS_IF([test "${enable_qt}" != "4"], [
  11. + PKG_CHECK_MODULES([QT], [Qt5Core >= 5.1.0 Qt5Widgets Qt5Gui], [
  12. PKG_CHECK_MODULES([QTX11], [Qt5X11Extras], [
  13. VLC_ADD_LIBS([qt4],[${QTX11_LIBS}])
  14. VLC_ADD_CXXFLAGS([qt4],[${QTX11_CFLAGS} -DQT5_HAS_X11])
  15. @@ -3721,20 +3722,23 @@
  16. AC_PATH_PROGS(MOC, [moc-qt5 moc], moc, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
  17. AC_PATH_PROGS(RCC, [rcc-qt5 rcc], rcc, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
  18. AC_PATH_PROGS(UIC, [uic-qt5 uic], uic, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
  19. + enable_qt="5"
  20. - ], [
  21. - PKG_CHECK_MODULES([QT], [QtCore QtGui >= 4.6.0],, [
  22. - AS_IF([test -n "${enable_qt}"],[
  23. - AC_MSG_ERROR([${QT_PKG_ERRORS}.])
  24. - ],[
  25. - AC_MSG_WARN([${QT_PKG_ERRORS}.])
  26. - ])
  27. - enable_qt="no"
  28. + ])
  29. + ])
  30. + AS_IF([test "${enable_qt}" != "5"], [
  31. + PKG_CHECK_MODULES([QT], [QtCore QtGui >= 4.6.0],, [
  32. + AS_IF([test -n "${enable_qt}"],[
  33. + AC_MSG_ERROR([${QT_PKG_ERRORS}.])
  34. + ],[
  35. + AC_MSG_WARN([${QT_PKG_ERRORS}.])
  36. ])
  37. - QT_PATH="$(eval $PKG_CONFIG --variable=exec_prefix QtCore)"
  38. - AC_PATH_PROGS(MOC, [moc-qt4 moc], moc, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
  39. - AC_PATH_PROG(RCC, rcc, rcc, [${QT_PATH}/bin ${CONTRIB_DIR}/bin])
  40. - AC_PATH_PROGS(UIC, [uic-qt4 uic], uic, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
  41. + enable_qt="no"
  42. ])
  43. + QT_PATH="$(eval $PKG_CONFIG --variable=exec_prefix QtCore)"
  44. + AC_PATH_PROGS(MOC, [moc-qt4 moc], moc, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
  45. + AC_PATH_PROG(RCC, rcc, rcc, [${QT_PATH}/bin ${CONTRIB_DIR}/bin])
  46. + AC_PATH_PROGS(UIC, [uic-qt4 uic], uic, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
  47. + ])
  48. ])
  49. AS_IF([test "${enable_qt}" != "no"], [
  50. VLC_ADD_PLUGIN([qt4])