1################################################################################
2#
3# webp
4#
5################################################################################
6
7WEBP_VERSION = 1.3.2
8WEBP_SOURCE = libwebp-$(WEBP_VERSION).tar.gz
9WEBP_SITE = http://downloads.webmproject.org/releases/webp
10WEBP_LICENSE = BSD-3-Clause
11WEBP_LICENSE_FILES = COPYING
12WEBP_CPE_ID_VENDOR = webmproject
13WEBP_CPE_ID_PRODUCT = libwebp
14WEBP_INSTALL_STAGING = YES
15
16WEBP_CONF_OPTS += \
17	--disable-sdl
18
19HOST_WEBP_CONF_OPTS += \
20	--enable-libwebpdemux \
21	--enable-libwebpmux \
22	--disable-gif \
23	--disable-gl \
24	--disable-jpeg \
25	--disable-png \
26	--disable-sdl \
27	--disable-tiff
28
29ifeq ($(BR2_PACKAGE_WEBP_DEMUX),y)
30WEBP_CONF_OPTS += --enable-libwebpdemux
31else
32WEBP_CONF_OPTS += --disable-libwebpdemux
33endif
34
35ifeq ($(BR2_PACKAGE_WEBP_MUX),y)
36WEBP_CONF_OPTS += --enable-libwebpmux
37else
38WEBP_CONF_OPTS += --disable-libwebpmux
39endif
40
41ifeq ($(BR2_PACKAGE_GIFLIB),y)
42WEBP_DEPENDENCIES += giflib
43WEBP_CONF_OPTS += --enable-gif
44else
45WEBP_CONF_OPTS += --disable-gif
46endif
47
48ifeq ($(BR2_PACKAGE_JPEG),y)
49WEBP_DEPENDENCIES += jpeg
50WEBP_CONF_OPTS += \
51	--enable-jpeg \
52	--with-jpegincludedir=$(STAGING_DIR)/usr/include \
53	--with-jpeglibdir=$(STAGING_DIR)/usr/lib
54else
55WEBP_CONF_OPTS += --disable-jpeg
56endif
57
58ifeq ($(BR2_PACKAGE_LIBFREEGLUT),y)
59WEBP_DEPENDENCIES += libfreeglut
60WEBP_CONF_OPTS += --enable-gl
61else
62WEBP_CONF_OPTS += --disable-gl
63endif
64
65ifeq ($(BR2_PACKAGE_LIBPNG),y)
66WEBP_DEPENDENCIES += libpng
67WEBP_CONF_OPTS += --enable-png
68WEBP_CONF_ENV += ac_cv_path_LIBPNG_CONFIG=$(STAGING_DIR)/usr/bin/libpng-config
69else
70WEBP_CONF_OPTS += --disable-png
71endif
72
73ifeq ($(BR2_PACKAGE_TIFF),y)
74WEBP_DEPENDENCIES += tiff
75WEBP_CONF_OPTS += \
76	--enable-tiff \
77	--with-tiffincludedir=$(STAGING_DIR)/usr/include \
78	--with-tifflibdir=$(STAGING_DIR)/usr/lib
79else
80WEBP_CONF_OPTS += --disable-tiff
81endif
82
83$(eval $(autotools-package))
84$(eval $(host-autotools-package))
85