Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | require qt4.inc |
| 2 | |
| 3 | SUMMARY = "Cross-platform UI toolkit and application framework (X11 version)" |
| 4 | DESCRIPTION = "Qt is a versatile cross-platform application framework -- this is the X11 version." |
| 5 | HOMEPAGE = "http://qt-project.org/" |
| 6 | SECTION = "x11/libs" |
| 7 | DEPENDS += "virtual/libx11 fontconfig libxft libxext libxrender libxrandr libxcursor" |
| 8 | DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'virtual/libgl', '', d)}" |
| 9 | PROVIDES += "qt4-x11" |
| 10 | QT4DEPENDS = "" |
| 11 | |
| 12 | QT_GLFLAGS ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', '-opengl', '-no-opengl', d)} " |
| 13 | QT_GLFLAGS_qemux86 = "-opengl" |
| 14 | QT_GLFLAGS_qemuppc = "-opengl" |
| 15 | QT_X11_FLAGS ?= "-no-xinerama -no-xkb -no-gtkstyle" |
| 16 | QT_CONFIG_FLAGS += "${QT_X11_FLAGS}" |
| 17 | QT_BASE_LIB ?= "libqt" |
| 18 | |
| 19 | # required by kdelibs4 |
| 20 | QT_KDE_FLAGS ?= "-accessibility -sm" |
| 21 | QT_DISTRO_FLAGS ?= "${QT_KDE_FLAGS}" |
| 22 | |
| 23 | inherit qt4x11 |
| 24 | |
| 25 | do_install_append() { |
| 26 | # fix pkgconfig, libtool and prl files |
| 27 | sed -i -e 's#I/usr/include#Iincludedir}#g' \ |
| 28 | -e 's#Iin#I${in#g' \ |
| 29 | ${D}${libdir}/*.la ${D}${libdir}/*.prl ${D}${libdir}/pkgconfig/*.pc |
| 30 | |
| 31 | # QT abuses $includedir to point to its headers, which breaks pkgconfig sysroot, so |
| 32 | # manually fix it up here: |
| 33 | for pc in ${D}${libdir}/pkgconfig/*.pc ; do |
| 34 | sed -i -e "s:prefix}include/${QT_BASE_NAME}/$(basename $pc .pc):prefix}/include:" \ |
| 35 | -e "s,Cflags: ,Cflags: -IP{includedir}/${QT_BASE_NAME}/$(basename $pc .pc) ," \ |
| 36 | -e 's:IP{:I${:g' $pc |
| 37 | done |
| 38 | } |