diff options
author | Yi Zhao <yi.zhao@windriver.com> | 2015-12-02 11:27:01 +0800 |
---|---|---|
committer | Martin Jansa <Martin.Jansa@gmail.com> | 2015-12-18 12:39:50 +0100 |
commit | 84e6322a0a3043d912e2bdc93a7190ed6680532e (patch) | |
tree | 7e66d677b1633a06ec35425254dcf1d2e970f37b | |
parent | 260fee6e0ce8c73270a0b3760cfdee33d445fcc6 (diff) | |
download | meta-openembedded-84e6322a0a3043d912e2bdc93a7190ed6680532e.tar.gz |
fltk: upgrade from version 1.1.10 to 1.3.3
- backport patch from trunk to fix build failure with jpeg-9 library
- add PACKAGECONFIG for opengl, xinerama, xfixes, xcursor to fix [build-deps] qa warnings
- rebase patches against the new version and drop the useless patches
- cleanup the host buildpaths from fltk-config
Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk-1.1.10/disable_test.patch | 13 | ||||
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk-1.1.10/dso-fix.patch | 13 | ||||
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk-1.1.10/libpng15.patch | 61 | ||||
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk/disable_test.patch | 11 | ||||
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk/fix-boolean-issue-with-jpeg9.patch | 40 | ||||
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk/fltk-no-freetype-config.patch (renamed from meta-oe/recipes-support/fltk/fltk-1.1.10/fltk-no-freetype-config.patch) | 14 | ||||
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk_1.1.10.bb | 41 | ||||
-rw-r--r-- | meta-oe/recipes-support/fltk/fltk_1.3.3.bb | 49 |
8 files changed, 108 insertions, 134 deletions
diff --git a/meta-oe/recipes-support/fltk/fltk-1.1.10/disable_test.patch b/meta-oe/recipes-support/fltk/fltk-1.1.10/disable_test.patch deleted file mode 100644 index 8c01a1f80..000000000 --- a/meta-oe/recipes-support/fltk/fltk-1.1.10/disable_test.patch +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | Index: fltk-1.1.9/Makefile | ||
2 | =================================================================== | ||
3 | --- fltk-1.1.9.orig/Makefile 2008-06-06 16:14:11.936736201 +0200 | ||
4 | +++ fltk-1.1.9/Makefile 2008-06-06 16:14:22.526357637 +0200 | ||
5 | @@ -27,7 +27,7 @@ | ||
6 | |||
7 | include makeinclude | ||
8 | |||
9 | -DIRS = $(IMAGEDIRS) src fluid test documentation | ||
10 | +DIRS = $(IMAGEDIRS) src fluid documentation | ||
11 | |||
12 | all: makeinclude fltk-config | ||
13 | for dir in $(DIRS); do\ | ||
diff --git a/meta-oe/recipes-support/fltk/fltk-1.1.10/dso-fix.patch b/meta-oe/recipes-support/fltk/fltk-1.1.10/dso-fix.patch deleted file mode 100644 index 867e9efcb..000000000 --- a/meta-oe/recipes-support/fltk/fltk-1.1.10/dso-fix.patch +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | src/fl_set_fonts_xft.cxx is using fontconfig symbols | ||
2 | |||
3 | --- a/makeinclude.in 2012-01-26 18:09:58.628799060 +0100 | ||
4 | +++ b/makeinclude.in 2012-01-26 18:08:58.115801758 +0100 | ||
5 | @@ -81,7 +81,7 @@ | ||
6 | AUDIOLIBS = @AUDIOLIBS@ | ||
7 | DSOFLAGS = -L. @DSOFLAGS@ | ||
8 | LDFLAGS = $(OPTIM) @LDFLAGS@ | ||
9 | -LDLIBS = @LIBS@ | ||
10 | +LDLIBS = @LIBS@ -lfontconfig | ||
11 | GLDLIBS = @GLLIB@ @LIBS@ | ||
12 | LINKFLTK = @LINKFLTK@ | ||
13 | LINKFLTKGL = @LINKFLTKGL@ | ||
diff --git a/meta-oe/recipes-support/fltk/fltk-1.1.10/libpng15.patch b/meta-oe/recipes-support/fltk/fltk-1.1.10/libpng15.patch deleted file mode 100644 index b2eb8d6fd..000000000 --- a/meta-oe/recipes-support/fltk/fltk-1.1.10/libpng15.patch +++ /dev/null | |||
@@ -1,61 +0,0 @@ | |||
1 | Imported from gentoo | ||
2 | http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/x11-libs/fltk/files/fltk-1.1.10-libpng15.patch | ||
3 | |||
4 | --- a/src/Fl_PNG_Image.cxx | ||
5 | +++ b/src/Fl_PNG_Image.cxx | ||
6 | @@ -66,7 +66,8 @@ Fl_PNG_Image::Fl_PNG_Image(const char *png) // I - File to read | ||
7 | png_structp pp; // PNG read pointer | ||
8 | png_infop info; // PNG info pointers | ||
9 | png_bytep *rows; // PNG row pointers | ||
10 | - | ||
11 | + png_byte color_type; // PNG color type | ||
12 | + png_byte bit_depth; // PNG bit depth | ||
13 | |||
14 | // Open the PNG file... | ||
15 | if ((fp = fopen(png, "rb")) == NULL) return; | ||
16 | @@ -75,7 +76,7 @@ Fl_PNG_Image::Fl_PNG_Image(const char *png) // I - File to read | ||
17 | pp = png_create_read_struct(PNG_LIBPNG_VER_STRING, NULL, NULL, NULL); | ||
18 | info = png_create_info_struct(pp); | ||
19 | |||
20 | - if (setjmp(pp->jmpbuf)) | ||
21 | + if (setjmp(png_jmpbuf(pp))) | ||
22 | { | ||
23 | Fl::warning("PNG file \"%s\" contains errors!\n", png); | ||
24 | return; | ||
25 | @@ -86,28 +87,24 @@ Fl_PNG_Image::Fl_PNG_Image(const char *png) // I - File to read | ||
26 | |||
27 | // Get the image dimensions and convert to grayscale or RGB... | ||
28 | png_read_info(pp, info); | ||
29 | + color_type = png_get_color_type(pp, info); | ||
30 | |||
31 | - if (info->color_type == PNG_COLOR_TYPE_PALETTE) | ||
32 | + if (color_type == PNG_COLOR_TYPE_PALETTE) | ||
33 | png_set_expand(pp); | ||
34 | |||
35 | - if (info->color_type & PNG_COLOR_MASK_COLOR) | ||
36 | - channels = 3; | ||
37 | - else | ||
38 | - channels = 1; | ||
39 | - | ||
40 | - if ((info->color_type & PNG_COLOR_MASK_ALPHA) || info->num_trans) | ||
41 | - channels ++; | ||
42 | + channels = png_get_channels(pp, info); | ||
43 | |||
44 | - w((int)(info->width)); | ||
45 | - h((int)(info->height)); | ||
46 | + w((int)(png_get_image_width(pp, info))); | ||
47 | + h((int)(png_get_image_height(pp, info))); | ||
48 | d(channels); | ||
49 | |||
50 | - if (info->bit_depth < 8) | ||
51 | + bit_depth = png_get_bit_depth(pp, info); | ||
52 | + if (bit_depth < 8) | ||
53 | { | ||
54 | png_set_packing(pp); | ||
55 | png_set_expand(pp); | ||
56 | } | ||
57 | - else if (info->bit_depth == 16) | ||
58 | + else if (bit_depth == 16) | ||
59 | png_set_strip_16(pp); | ||
60 | |||
61 | # if defined(HAVE_PNG_GET_VALID) && defined(HAVE_PNG_SET_TRNS_TO_ALPHA) | ||
diff --git a/meta-oe/recipes-support/fltk/fltk/disable_test.patch b/meta-oe/recipes-support/fltk/fltk/disable_test.patch new file mode 100644 index 000000000..1f5fd25e0 --- /dev/null +++ b/meta-oe/recipes-support/fltk/fltk/disable_test.patch | |||
@@ -0,0 +1,11 @@ | |||
1 | --- a/Makefile.orig 2015-11-26 15:35:31.485357862 +0800 | ||
2 | +++ b/Makefile 2015-11-26 15:35:37.037357764 +0800 | ||
3 | @@ -18,7 +18,7 @@ | ||
4 | |||
5 | include makeinclude | ||
6 | |||
7 | -DIRS = $(IMAGEDIRS) src $(CAIRODIR) fluid test documentation | ||
8 | +DIRS = $(IMAGEDIRS) src $(CAIRODIR) fluid documentation | ||
9 | |||
10 | all: makeinclude fltk-config | ||
11 | for dir in $(DIRS); do\ | ||
diff --git a/meta-oe/recipes-support/fltk/fltk/fix-boolean-issue-with-jpeg9.patch b/meta-oe/recipes-support/fltk/fltk/fix-boolean-issue-with-jpeg9.patch new file mode 100644 index 000000000..014184d53 --- /dev/null +++ b/meta-oe/recipes-support/fltk/fltk/fix-boolean-issue-with-jpeg9.patch | |||
@@ -0,0 +1,40 @@ | |||
1 | From 14c22398f8370e33a798360ed0dad513af8f1470 Mon Sep 17 00:00:00 2001 | ||
2 | From: AlbrechtS <AlbrechtS@ea41ed52-d2ee-0310-a9c1-e6b18d33e121> | ||
3 | Date: Sun, 15 Mar 2015 19:32:33 +0000 | ||
4 | Subject: [PATCH] Fix 'boolean' issue with jpeg-9 library compatibility (STR | ||
5 | #2920). | ||
6 | |||
7 | According to comments in STR #2920 and my own tests this is also | ||
8 | compatible with older jpeg libraries (at least jpeg-8). | ||
9 | |||
10 | Upstream-Status: Backport | ||
11 | |||
12 | --- | ||
13 | src/Fl_JPEG_Image.cxx | 4 ++-- | ||
14 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
15 | |||
16 | diff --git a/src/Fl_JPEG_Image.cxx b/src/Fl_JPEG_Image.cxx | ||
17 | index 47120a7..6cebe88 100644 | ||
18 | --- a/src/Fl_JPEG_Image.cxx | ||
19 | +++ b/src/Fl_JPEG_Image.cxx | ||
20 | @@ -155,7 +155,7 @@ Fl_JPEG_Image::Fl_JPEG_Image(const char *filename) // I - File to load | ||
21 | |||
22 | jpeg_create_decompress(&dinfo); | ||
23 | jpeg_stdio_src(&dinfo, fp); | ||
24 | - jpeg_read_header(&dinfo, 1); | ||
25 | + jpeg_read_header(&dinfo, TRUE); | ||
26 | |||
27 | dinfo.quantize_colors = (boolean)FALSE; | ||
28 | dinfo.out_color_space = JCS_RGB; | ||
29 | @@ -337,7 +337,7 @@ Fl_JPEG_Image::Fl_JPEG_Image(const char *name, const unsigned char *data) | ||
30 | |||
31 | jpeg_create_decompress(&dinfo); | ||
32 | jpeg_mem_src(&dinfo, data); | ||
33 | - jpeg_read_header(&dinfo, 1); | ||
34 | + jpeg_read_header(&dinfo, TRUE); | ||
35 | |||
36 | dinfo.quantize_colors = (boolean)FALSE; | ||
37 | dinfo.out_color_space = JCS_RGB; | ||
38 | -- | ||
39 | 1.7.9.5 | ||
40 | |||
diff --git a/meta-oe/recipes-support/fltk/fltk-1.1.10/fltk-no-freetype-config.patch b/meta-oe/recipes-support/fltk/fltk/fltk-no-freetype-config.patch index 5dbb0547d..4d13ffc5d 100644 --- a/meta-oe/recipes-support/fltk/fltk-1.1.10/fltk-no-freetype-config.patch +++ b/meta-oe/recipes-support/fltk/fltk/fltk-no-freetype-config.patch | |||
@@ -1,18 +1,20 @@ | |||
1 | --- a/configure.in.orig 2015-03-01 16:00:35.956432907 +0100 | 1 | --- a/configure.in.orig 2015-11-26 14:30:17.893426966 +0800 |
2 | +++ b/configure.in 2015-03-01 16:04:23.269580093 +0100 | 2 | +++ b/configure.in 2015-11-26 14:33:00.285424099 +0800 |
3 | @@ -865,11 +865,11 @@ | 3 | @@ -969,12 +969,12 @@ case $host_os_gui in |
4 | AC_ARG_ENABLE(xft, [ --enable-xft turn on Xft support [default=no]]) | 4 | AC_ARG_ENABLE(xft, [ --enable-xft turn on Xft support [[default=yes]]]) |
5 | 5 | ||
6 | if test x$enable_xft = xyes; then | 6 | if test x$enable_xft != xno; then |
7 | - AC_PATH_PROG(FTCONFIG,freetype-config) | 7 | - AC_PATH_PROG(FTCONFIG,freetype-config) |
8 | + AC_PATH_PROG(PKGCONFIG,pkg-config) | 8 | + AC_PATH_PROG(PKGCONFIG,pkg-config) |
9 | 9 | ||
10 | - if test "x$FTCONFIG" != x; then | 10 | - if test "x$FTCONFIG" != x; then |
11 | - CPPFLAGS="`$FTCONFIG --cflags` $CPPFLAGS" | 11 | - CPPFLAGS="`$FTCONFIG --cflags` $CPPFLAGS" |
12 | - CFLAGS="`$FTCONFIG --cflags` $CFLAGS" | ||
12 | - CXXFLAGS="`$FTCONFIG --cflags` $CXXFLAGS" | 13 | - CXXFLAGS="`$FTCONFIG --cflags` $CXXFLAGS" |
13 | + if test "x$PKGCONFIG" != x; then | 14 | + if test "x$PKGCONFIG" != x; then |
14 | + CPPFLAGS="`$PKGCONFIG --cflags xft` $CPPFLAGS" | 15 | + CPPFLAGS="`$PKGCONFIG --cflags xft` $CPPFLAGS" |
16 | + CFLAGS="`$PKGCONFIG --cflags xft` $CFLAGS" | ||
15 | + CXXFLAGS="`$PKGCONFIG --cflags xft` $CXXFLAGS" | 17 | + CXXFLAGS="`$PKGCONFIG --cflags xft` $CXXFLAGS" |
16 | 18 | ||
19 | AC_CHECK_LIB(fontconfig, FcPatternCreate) | ||
17 | AC_CHECK_HEADER(X11/Xft/Xft.h, | 20 | AC_CHECK_HEADER(X11/Xft/Xft.h, |
18 | AC_CHECK_LIB(Xft, XftDrawCreate, | ||
diff --git a/meta-oe/recipes-support/fltk/fltk_1.1.10.bb b/meta-oe/recipes-support/fltk/fltk_1.1.10.bb deleted file mode 100644 index 14049614a..000000000 --- a/meta-oe/recipes-support/fltk/fltk_1.1.10.bb +++ /dev/null | |||
@@ -1,41 +0,0 @@ | |||
1 | SUMMARY = "FLTK is a cross-platform C++ GUI toolkit" | ||
2 | HOMEPAGE = "http://www.fltk.org" | ||
3 | SECTION = "libs" | ||
4 | LICENSE = "LGPLv2 & FLTK" | ||
5 | LIC_FILES_CHKSUM = "file://COPYING;md5=1c0b73db66884b6a925e727400315130" | ||
6 | |||
7 | DEPENDS = "alsa-lib zlib jpeg libpng libxext libxft" | ||
8 | |||
9 | PR = "r2" | ||
10 | |||
11 | SRC_URI = "ftp://ftp.rz.tu-bs.de/pub/mirror/ftp.easysw.com/ftp/pub/fltk/${PV}/fltk-${PV}-source.tar.bz2 \ | ||
12 | file://disable_test.patch \ | ||
13 | file://dso-fix.patch \ | ||
14 | file://libpng15.patch \ | ||
15 | file://fltk-no-freetype-config.patch \ | ||
16 | " | ||
17 | |||
18 | S = "${WORKDIR}/fltk-${PV}" | ||
19 | |||
20 | inherit lib_package autotools-brokensep binconfig pkgconfig | ||
21 | |||
22 | TARGET_CC_ARCH += "${LDFLAGS} -DXFT_MAJOR=2" | ||
23 | |||
24 | EXTRA_OECONF = "--enable-shared \ | ||
25 | --enable-threads \ | ||
26 | --enable-xdbe --enable-xft --enable-gl \ | ||
27 | --x-includes=${STAGING_INCDIR} --x-libraries=${STAGING_LIBDIR}" | ||
28 | |||
29 | do_configure() { | ||
30 | oe_runconf | ||
31 | } | ||
32 | |||
33 | python populate_packages_prepend () { | ||
34 | if (d.getVar('DEBIAN_NAMES', 1)): | ||
35 | d.setVar('PKG_${BPN}', 'libfltk${PV}') | ||
36 | } | ||
37 | |||
38 | LEAD_SONAME = "libfltk.so" | ||
39 | |||
40 | SRC_URI[md5sum] = "a1765594bc427ff892e36089fe1fa672" | ||
41 | SRC_URI[sha256sum] = "37ada22bf2586b8dd30d84209b8b58bdcb864627e5d02ae3f2c323a29261b19a" | ||
diff --git a/meta-oe/recipes-support/fltk/fltk_1.3.3.bb b/meta-oe/recipes-support/fltk/fltk_1.3.3.bb new file mode 100644 index 000000000..117ecc366 --- /dev/null +++ b/meta-oe/recipes-support/fltk/fltk_1.3.3.bb | |||
@@ -0,0 +1,49 @@ | |||
1 | SUMMARY = "FLTK is a cross-platform C++ GUI toolkit" | ||
2 | HOMEPAGE = "http://www.fltk.org" | ||
3 | SECTION = "libs" | ||
4 | LICENSE = "LGPLv2 & FLTK" | ||
5 | LIC_FILES_CHKSUM = "file://COPYING;md5=f6b26344a24a941a01a5b0826e80b5ca" | ||
6 | |||
7 | DEPENDS = "alsa-lib zlib jpeg libpng libxext libxft" | ||
8 | |||
9 | SRC_URI = "http://fltk.org/pub/fltk/${PV}/${BP}-source.tar.gz \ | ||
10 | file://disable_test.patch \ | ||
11 | file://fltk-no-freetype-config.patch \ | ||
12 | file://fix-boolean-issue-with-jpeg9.patch \ | ||
13 | " | ||
14 | |||
15 | SRC_URI[md5sum] = "9ccdb0d19dc104b87179bd9fd10822e3" | ||
16 | SRC_URI[sha256sum] = "f8398d98d7221d40e77bc7b19e761adaf2f1ef8bb0c30eceb7beb4f2273d0d97" | ||
17 | |||
18 | inherit autotools-brokensep binconfig pkgconfig lib_package | ||
19 | |||
20 | TARGET_CC_ARCH += "${LDFLAGS} -DXFT_MAJOR=2" | ||
21 | |||
22 | EXTRA_OECONF = "--enable-shared \ | ||
23 | --enable-threads \ | ||
24 | --enable-xdbe \ | ||
25 | --enable-xft \ | ||
26 | " | ||
27 | |||
28 | PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'opengl', '', d)}" | ||
29 | |||
30 | PACKAGECONFIG[opengl] = "--enable-gl,--disable-gl,virtual/libgl" | ||
31 | PACKAGECONFIG[xinerama] = "--enable-xinerama,--disable-xinerama,libxinerama" | ||
32 | PACKAGECONFIG[xfixes] = "--enable-xfixes,--disable-xfixes,libxfixes" | ||
33 | PACKAGECONFIG[xcursor] = "--enable-xcursor,--disable-xcursor,libxcursor" | ||
34 | |||
35 | do_configure() { | ||
36 | oe_runconf | ||
37 | } | ||
38 | |||
39 | do_install_append_class-target() { | ||
40 | sed -i -e 's,${STAGING_DIR_HOST},,g' ${D}${bindir}/fltk-config | ||
41 | } | ||
42 | |||
43 | python populate_packages_prepend () { | ||
44 | if (d.getVar('DEBIAN_NAMES', 1)): | ||
45 | d.setVar('PKG_${BPN}', 'libfltk${PV}') | ||
46 | } | ||
47 | |||
48 | LEAD_SONAME = "libfltk.so" | ||
49 | |||