Move buildroot to bsp directory.

This commit is contained in:
2016-11-16 22:05:33 +01:00
parent 317c040ea8
commit 807ab03547
7408 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,109 @@
From 18078feecc8da0ab2693d0bb5423489fa62920ef Mon Sep 17 00:00:00 2001
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Date: Tue, 22 Dec 2015 21:25:19 +0100
Subject: [PATCH] configure: allow to override the location of the *-config
scripts
Currently, the configure.ac calls a number of *-config scripts to get
details about installed libraries. It assumes that those *-config
scripts are readily available in the PATH.
While this is true in most situations, it may not be true when
cross-compiling: you may have the *-config scripts matching the target
environment in a location that isn't in the PATH. For such situations,
it is very useful to be able to override the location of such *-config
scripts using environment variables.
The proposed changes does not introduce any functional difference if
you don't pass those new environment variables: if they are not
passed, it falls back to the current value.
However, if those *_CONFIG variables are passed, then they are used as
the path to the corresponding *-config script.
The ${FOO_CONFIG:-foo-config} construct is POSIX compliant, so it is
available in all shells.
(Patch submitted upstream.)
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
---
configure.ac | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/configure.ac b/configure.ac
index 86f12c5..37ceab5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1191,7 +1191,7 @@ dnl **** Check for libxml2 ****
if test "x$with_xml" != "xno"
then
WINE_PACKAGE_FLAGS(XML2,[libxml-2.0],[-lxml2],
- [`xml2-config --cflags 2>/dev/null`],[`xml2-config --libs 2>/dev/null`],
+ [`${XML2_CONFIG:-xml2-config} --cflags 2>/dev/null`],[`${XML2_CONFIG:-xml2-config} --libs 2>/dev/null`],
[AC_CHECK_HEADERS([libxml/parser.h libxml/xmlsave.h libxml/SAX2.h])
if test "$ac_cv_header_libxml_parser_h" = "yes" -a "$ac_cv_header_libxml_xmlsave_h" = "yes" -a "$ac_cv_header_libxml_SAX2_h" = "yes"
then
@@ -1220,7 +1220,7 @@ WINE_WARNING_WITH(xml,[test "$ac_cv_lib_xml2_xmlParseMemory" != "yes"],
if test "x$with_xslt" != "xno"
then
WINE_PACKAGE_FLAGS(XSLT,[libxslt],[-lxml2],
- [`xslt-config --cflags 2>/dev/null`],[`xslt-config --libs 2>/dev/null`],
+ [`${XSLT_CONFIG:-xslt-config} --cflags 2>/dev/null`],[`${XSLT_CONFIG:-xslt-config} --libs 2>/dev/null`],
[AC_CHECK_HEADERS([libxslt/pattern.h libxslt/transform.h],,,
[#ifdef HAVE_LIBXSLT_PATTERN_H
# include <libxslt/pattern.h>
@@ -1291,7 +1291,7 @@ WINE_NOTICE_WITH(curses,[test "x$ac_cv_lib_soname_curses$ac_cv_lib_soname_ncurse
dnl **** Check for SANE ****
if test "x$with_sane" != "xno"
then
- WINE_PACKAGE_FLAGS(SANE,[libsane],,[`sane-config --cflags 2>/dev/null`],[`sane-config --ldflags 2>/dev/null`],
+ WINE_PACKAGE_FLAGS(SANE,[libsane],,[`${SANE_CONFIG:-sane-config} --cflags 2>/dev/null`],[`${SANE_CONFIG:-sane-config} --ldflags 2>/dev/null`],
[AC_CHECK_HEADER(sane/sane.h,
[WINE_CHECK_SONAME(sane,sane_init,,[SANE_CFLAGS=""],[$SANE_LIBS])],
[SANE_CFLAGS=""])])
@@ -1311,7 +1311,7 @@ dnl **** Check for libgphoto2 ****
if test "x$with_gphoto" != "xno"
then
WINE_PACKAGE_FLAGS(GPHOTO2,[libgphoto2],[-lgphoto2],
- [`gphoto2-config --cflags 2>/dev/null`],[`gphoto2-config --libs 2>/dev/null`],
+ [`${GPHOTO2_CONFIG:-gphoto2-config} --cflags 2>/dev/null`],[`${GPHOTO2_CONFIG:-gphoto2-config} --libs 2>/dev/null`],
[AC_CHECK_HEADER(gphoto2-camera.h,
[AC_CHECK_LIB(gphoto2,gp_camera_new,
[AC_DEFINE(HAVE_GPHOTO2, 1, [Define if we have the libgphoto2 development environment])],
@@ -1319,8 +1319,8 @@ then
[$GPHOTO2_LIBS])],
[GPHOTO2_LIBS=""; GPHOTO2_CFLAGS=""])])
WINE_PACKAGE_FLAGS(GPHOTO2_PORT,[libgphoto2_port],[-lgphoto2_port],
- [`gphoto2-port-config --cflags 2>/dev/null`],
- [`gphoto2-port-config --libs 2>/dev/null`],
+ [`${GPHOTO2_PORT_CONFIG:-gphoto2-port-config} --cflags 2>/dev/null`],
+ [`${GPHOTO2_PORT_CONFIG:-gphoto2-port-config} --libs 2>/dev/null`],
[AC_CHECK_HEADER(gphoto2-port.h,
[AC_CHECK_LIB(gphoto2_port,gp_port_info_list_new,
[AC_DEFINE(HAVE_GPHOTO2_PORT, 1, [Define if we have the libgphoto2_port development environment])],
@@ -1382,8 +1382,8 @@ dnl **** Check for FreeType 2 ****
if test "x$with_freetype" != "xno"
then
WINE_PACKAGE_FLAGS(FREETYPE,[freetype2],[-lfreetype],
- [`(freetype-config --cflags || freetype2-config --cflags) 2>/dev/null`],
- [`(freetype-config --libs || freetype2-config --libs) 2>/dev/null`],
+ [`(${FREETYPE_CONFIG:-freetype-config} --cflags || ${FREETYPE2_CONFIG:-freetype2-config} --cflags) 2>/dev/null`],
+ [`(${FREETYPE_CONFIG:-freetype-config} --libs || ${FREETYPE2_CONFIG:-freetype2-config} --libs) 2>/dev/null`],
[AC_CHECK_HEADERS([ft2build.h])
if test "$ac_cv_header_ft2build_h" = "yes"
then
@@ -1538,8 +1538,8 @@ AC_SUBST(CUPS_CFLAGS,"")
if test "x$with_cups" != "xno"
then
ac_save_CPPFLAGS="$CPPFLAGS"
- ac_cups_cflags=`cups-config --cflags 2>/dev/null`
- ac_cups_libs=`cups-config --ldflags 2>/dev/null`
+ ac_cups_cflags=`${CUPS_CONFIG:-cups-config} --cflags 2>/dev/null`
+ ac_cups_libs=`${CUPS_CONFIG:-cups-config} --ldflags 2>/dev/null`
CPPFLAGS="$CPPFLAGS $ac_cups_cflags"
AC_CHECK_HEADERS(cups/cups.h,
[WINE_CHECK_SONAME(cups,cupsGetDefault,
--
2.6.4

View File

@@ -0,0 +1,23 @@
config BR2_PACKAGE_WINE
bool "wine"
depends on BR2_TOOLCHAIN_USES_GLIBC
# Wine only builds on certain architectures
depends on BR2_HOSTARCH = "x86_64" || BR2_HOSTARCH = "x86" || \
BR2_HOSTARCH = "powerpc" || BR2_HOSTARCH = "arm" || \
BR2_HOSTARCH = "aarch64"
# Wine has much CPU specific code and mostly makes sense on x86
depends on BR2_i386
help
Wine is a compatibility layer capable of running Windows
applications on Linux. Instead of simulating internal
Windows logic like a virtual machine or emulator, Wine
translates Windows API calls into POSIX calls on-the-fly,
eliminating the performance and memory penalties of other
methods.
http://www.winehq.org
comment "wine needs a (e)glibc toolchain"
depends on BR2_HOSTARCH = "x86_64" || BR2_HOSTARCH = "x86"
depends on BR2_i386
depends on !BR2_TOOLCHAIN_USES_GLIBC

View File

@@ -0,0 +1,2 @@
# Locally calculated after checking pgp signature
sha256 f33b45c18112b2071fbf9edee0e8c575407f9e2a9855ca4ee918ed33efa7c6f4 wine-1.8.tar.bz2

View File

@@ -0,0 +1,375 @@
################################################################################
#
# wine
#
################################################################################
WINE_VERSION = 1.8
WINE_SOURCE = wine-$(WINE_VERSION).tar.bz2
WINE_SITE = https://dl.winehq.org/wine/source/1.8
WINE_LICENSE = LGPLv2.1+
WINE_LICENSE_FILES = COPYING.LIB LICENSE
WINE_DEPENDENCIES = host-bison host-flex host-wine
# For 0001-sane-config-fix.patch
WINE_AUTORECONF = YES
# Wine needs its own directory structure and tools for cross compiling
WINE_CONF_OPTS = \
--with-wine-tools=../host-wine-$(WINE_VERSION) \
--disable-tests \
--disable-win64 \
--without-capi \
--without-coreaudio \
--without-gettext \
--without-gettextpo \
--without-gphoto \
--without-gsm \
--without-hal \
--without-opencl \
--without-oss
# Wine uses a wrapper around gcc, and uses the value of --host to
# construct the filename of the gcc to call. But for external
# toolchains, the GNU_TARGET_NAME tuple that we construct from our
# internal variables may differ from the actual gcc prefix for the
# external toolchains. So, we have to override whatever the gcc
# wrapper believes what the real gcc is named, and force the tuple of
# the external toolchain, not the one we compute in GNU_TARGET_NAME.
ifeq ($(BR2_TOOLCHAIN_EXTERNAL),y)
WINE_CONF_OPTS += TARGETFLAGS="-b $(call qstrip,$(BR2_TOOLCHAIN_EXTERNAL_PREFIX))"
endif
ifeq ($(BR2_PACKAGE_ALSA_LIB)$(BR2_PACKAGE_ALSA_LIB_SEQ)$(BR2_PACKAGE_ALSA_LIB_RAWMIDI),yyy)
WINE_CONF_OPTS += --with-alsa
WINE_DEPENDENCIES += alsa-lib
else
WINE_CONF_OPTS += --without-alsa
endif
ifeq ($(BR2_PACKAGE_CUPS),y)
WINE_CONF_OPTS += --with-cups
WINE_DEPENDENCIES += cups
WINE_CONF_ENV += CUPS_CONFIG=$(STAGING_DIR)/usr/bin/cups-config
else
WINE_CONF_OPTS += --without-cups
endif
ifeq ($(BR2_PACKAGE_DBUS),y)
WINE_CONF_OPTS += --with-dbus
WINE_DEPENDENCIES += dbus
else
WINE_CONF_OPTS += --without-dbus
endif
ifeq ($(BR2_PACKAGE_FONTCONFIG),y)
WINE_CONF_OPTS += --with-fontconfig
WINE_DEPENDENCIES += fontconfig
else
WINE_CONF_OPTS += --without-fontconfig
endif
# To support freetype in wine we also need freetype in host-wine for the cross compiling tools
ifeq ($(BR2_PACKAGE_FREETYPE),y)
WINE_CONF_OPTS += --with-freetype
HOST_WINE_CONF_OPTS += --with-freetype
WINE_DEPENDENCIES += freetype
HOST_WINE_DEPENDENCIES += host-freetype
WINE_CONF_ENV += FREETYPE_CONFIG=$(STAGING_DIR)/usr/bin/freetype-config
else
WINE_CONF_OPTS += --without-freetype
HOST_WINE_CONF_OPTS += --without-freetype
endif
ifeq ($(BR2_PACKAGE_GNUTLS),y)
WINE_CONF_OPTS += --with-gnutls
WINE_DEPENDENCIES += gnutls
else
WINE_CONF_OPTS += --without-gnutls
endif
ifeq ($(BR2_PACKAGE_GST_PLUGINS_BASE),y)
WINE_CONF_OPTS += --with-gstreamer
WINE_DEPENDENCIES += gst-plugins-base
else
WINE_CONF_OPTS += --without-gstreamer
endif
ifeq ($(BR2_PACKAGE_JPEG),y)
WINE_CONF_OPTS += --with-jpeg
WINE_DEPENDENCIES += jpeg
else
WINE_CONF_OPTS += --without-jpeg
endif
ifeq ($(BR2_PACKAGE_LCMS2),y)
WINE_CONF_OPTS += --with-cms
WINE_DEPENDENCIES += lcms2
else
WINE_CONF_OPTS += --without-cms
endif
ifeq ($(BR2_PACKAGE_HAS_LIBGL),y)
WINE_CONF_OPTS += --with-opengl
WINE_DEPENDENCIES += libgl
else
WINE_CONF_OPTS += --without-opengl
endif
ifeq ($(BR2_PACKAGE_LIBGLU),y)
WINE_CONF_OPTS += --with-glu
WINE_DEPENDENCIES += libglu
else
WINE_CONF_OPTS += --without-glu
endif
ifeq ($(BR2_PACKAGE_LIBPCAP),y)
WINE_CONF_OPTS += --with-pcap
WINE_DEPENDENCIES += libpcap
else
WINE_CONF_OPTS += --without-pcap
endif
ifeq ($(BR2_PACKAGE_LIBPNG),y)
WINE_CONF_OPTS += --with-png
WINE_DEPENDENCIES += libpng
else
WINE_CONF_OPTS += --without-png
endif
ifeq ($(BR2_PACKAGE_LIBV4L),y)
WINE_CONF_OPTS += --with-v4l
WINE_DEPENDENCIES += libv4l
else
WINE_CONF_OPTS += --without-v4l
endif
ifeq ($(BR2_PACKAGE_LIBXML2),y)
WINE_CONF_OPTS += --with-xml
WINE_DEPENDENCIES += libxml2
WINE_CONF_ENV += XML2_CONFIG=$(STAGING_DIR)/usr/bin/xml2-config
else
WINE_CONF_OPTS += --without-xml
endif
ifeq ($(BR2_PACKAGE_LIBXSLT),y)
WINE_CONF_OPTS += --with-xslt
WINE_DEPENDENCIES += libxslt
WINE_CONF_ENV += XSLT_CONFIG=$(STAGING_DIR)/usr/bin/xslt-config
else
WINE_CONF_OPTS += --without-xslt
endif
ifeq ($(BR2_PACKAGE_MPG123),y)
WINE_CONF_OPTS += --with-mpg123
WINE_DEPENDENCIES += mpg123
else
WINE_CONF_OPTS += --without-mpg123
endif
ifeq ($(BR2_PACKAGE_NCURSES),y)
WINE_CONF_OPTS += --with-curses
WINE_DEPENDENCIES += ncurses
else
WINE_CONF_OPTS += --without-curses
endif
ifeq ($(BR2_PACKAGE_OPENAL),y)
WINE_CONF_OPTS += --with-openal
WINE_DEPENDENCIES += openal
else
WINE_CONF_OPTS += --without-openal
endif
ifeq ($(BR2_PACKAGE_OPENLDAP),y)
WINE_CONF_OPTS += --with-ldap
WINE_DEPENDENCIES += openldap
else
WINE_CONF_OPTS += --without-ldap
endif
ifeq ($(BR2_PACKAGE_MESA3D_OSMESA),y)
WINE_CONF_OPTS += --with-osmesa
WINE_DEPENDENCIES += mesa3d
else
WINE_CONF_OPTS += --without-osmesa
endif
ifeq ($(BR2_PACKAGE_PULSEAUDIO),y)
WINE_CONF_OPTS += --with-pulse
WINE_DEPENDENCIES += pulseaudio
else
WINE_CONF_OPTS += --without-pulse
endif
ifeq ($(BR2_PACKAGE_SAMBA4),y)
WINE_CONF_OPTS += --with-netapi
WINE_DEPENDENCIES += samba4
else
WINE_CONF_OPTS += --without-netapi
endif
ifeq ($(BR2_PACKAGE_SANE_BACKENDS),y)
WINE_CONF_OPTS += --with-sane
WINE_DEPENDENCIES += sane-backends
WINE_CONF_ENV += SANE_CONFIG=$(STAGING_DIR)/usr/bin/sane-config
else
WINE_CONF_OPTS += --without-sane
endif
ifeq ($(BR2_PACKAGE_TIFF),y)
WINE_CONF_OPTS += --with-tiff
WINE_DEPENDENCIES += tiff
else
WINE_CONF_OPTS += --without-tiff
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBX11),y)
WINE_CONF_OPTS += --with-x
WINE_DEPENDENCIES += xlib_libX11
else
WINE_CONF_OPTS += --without-x
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXCOMPOSITE),y)
WINE_CONF_OPTS += --with-xcomposite
WINE_DEPENDENCIES += xlib_libXcomposite
else
WINE_CONF_OPTS += --without-xcomposite
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXCURSOR),y)
WINE_CONF_OPTS += --with-xcursor
WINE_DEPENDENCIES += xlib_libXcursor
else
WINE_CONF_OPTS += --without-xcursor
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXEXT),y)
WINE_CONF_OPTS += --with-xshape --with-xshm
WINE_DEPENDENCIES += xlib_libXext
else
WINE_CONF_OPTS += --without-xshape --without-xshm
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXI),y)
WINE_CONF_OPTS += --with-xinput --with-xinput2
WINE_DEPENDENCIES += xlib_libXi
else
WINE_CONF_OPTS += --without-xinput --without-xinput2
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXINERAMA),y)
WINE_CONF_OPTS += --with-xinerama
WINE_DEPENDENCIES += xlib_libXinerama
else
WINE_CONF_OPTS += --without-xinerama
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXRANDR),y)
WINE_CONF_OPTS += --with-xrandr
WINE_DEPENDENCIES += xlib_libXrandr
else
WINE_CONF_OPTS += --without-xrandr
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXRENDER),y)
WINE_CONF_OPTS += --with-xrender
WINE_DEPENDENCIES += xlib_libXrender
else
WINE_CONF_OPTS += --without-xrender
endif
ifeq ($(BR2_PACKAGE_XLIB_LIBXXF86VM),y)
WINE_CONF_OPTS += --with-xxf86vm
WINE_DEPENDENCIES += xlib_libXxf86vm
else
WINE_CONF_OPTS += --without-xxf86vm
endif
ifeq ($(BR2_PACKAGE_ZLIB),y)
WINE_CONF_OPTS += --with-zlib
WINE_DEPENDENCIES += zlib
else
WINE_CONF_OPTS += --without-zlib
endif
# host-gettext is essential for .po file support in host-wine wrc
HOST_WINE_DEPENDENCIES += host-gettext
HOST_WINE_CONF_OPTS += --with-gettext --with-gettextpo
# Wine needs to enable 64-bit build tools on 64-bit host
ifeq ($(HOSTARCH),x86_64)
HOST_WINE_CONF_OPTS += --enable-win64
endif
# Wine only needs the host tools to be built, so cut-down the
# build time by building just what we need.
define HOST_WINE_BUILD_CMDS
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) \
tools \
tools/sfnt2fon \
tools/widl \
tools/winebuild \
tools/winegcc \
tools/wmc \
tools/wrc
endef
# Wine only needs its host variant to be built, not that it is
# installed, as it uses the tools from the build directory. But
# we have no way in Buildroot to state that a host package should
# not be installed. So, just provide an noop install command.
define HOST_WINE_INSTALL_CMDS
:
endef
# We are focused on the cross compiling tools, disable everything else
HOST_WINE_CONF_OPTS += \
--disable-tests \
--disable-win16 \
--without-alsa \
--without-capi \
--without-cms \
--without-coreaudio \
--without-cups \
--without-curses \
--without-dbus \
--without-fontconfig \
--without-gphoto \
--without-glu \
--without-gnutls \
--without-gsm \
--without-gstreamer \
--without-hal \
--without-jpeg \
--without-ldap \
--without-mpg123 \
--without-netapi \
--without-openal \
--without-opencl \
--without-opengl \
--without-osmesa \
--without-oss \
--without-pcap \
--without-pulse \
--without-png \
--without-sane \
--without-tiff \
--without-v4l \
--without-x \
--without-xcomposite \
--without-xcursor \
--without-xinerama \
--without-xinput \
--without-xinput2 \
--without-xml \
--without-xrandr \
--without-xrender \
--without-xshape \
--without-xshm \
--without-xslt \
--without-xxf86vm \
--without-zlib
$(eval $(autotools-package))
$(eval $(host-autotools-package))