Update buidlroot to version 2016.08.1
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
From 5da1f631bc753655ac94b08a6233eecd0d451327 Mon Sep 17 00:00:00 2001
|
||||
From: "Arnout Vandecappelle (Essensium/Mind)" <arnout@mind.be>
|
||||
Date: Fri, 26 Aug 2016 21:55:06 +0200
|
||||
Subject: [PATCH] Fix LTO support for cross-compilation.
|
||||
|
||||
When cross-compiling, the ar and ranlib to be used for LTO are prefixed
|
||||
by the cross-tuple. gcc-ar and gcc-ranlib may not exist. Cfr.
|
||||
http://autobuild.buildroot.net/results/f3c/f3c48da3a9706cd366c0e0a96c3cd0ff959f2a78/
|
||||
|
||||
Therefore, search for an appropriate lto-ar and lto-ranlib before
|
||||
enabling LTO.
|
||||
|
||||
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
|
||||
---
|
||||
Submitted upstream: https://github.com/tomba/kmsxx/pull/14
|
||||
---
|
||||
CMakeLists.txt | 12 +++++++++---
|
||||
1 file changed, 9 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index e5b5ea5..c61c81d 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -39,9 +39,15 @@ if (NOT ${U_CMAKE_BUILD_TYPE} MATCHES DEBUG)
|
||||
CHECK_CXX_COMPILER_FLAG("-flto" HAS_LTO_FLAG)
|
||||
|
||||
if (HAS_LTO_FLAG)
|
||||
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -flto")
|
||||
- set(CMAKE_AR gcc-ar)
|
||||
- set(CMAKE_RANLIB gcc-ranlib)
|
||||
+ find_program(LTO_AR NAMES "${CMAKE_C_COMPILER}-ar" gcc-ar)
|
||||
+ find_program(LTO_RANLIB NAMES "${CMAKE_C_COMPILER}-ranlib" gcc-ranlib)
|
||||
+ if (LTO_AR AND LTO_RANLIB)
|
||||
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -flto")
|
||||
+ set(CMAKE_AR "${LTO_AR}")
|
||||
+ set(CMAKE_RANLIB "${LTO_RANLIB}")
|
||||
+ else()
|
||||
+ message(STATUS "gcc-ar or gcc-ranlib not found, disabling LTO")
|
||||
+ endif()
|
||||
endif()
|
||||
endif()
|
||||
|
||||
--
|
||||
2.9.3
|
||||
|
||||
26
bsp/buildroot/package/kmsxx/Config.in
Normal file
26
bsp/buildroot/package/kmsxx/Config.in
Normal file
@@ -0,0 +1,26 @@
|
||||
config BR2_PACKAGE_KMSXX
|
||||
bool "kms++"
|
||||
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_8
|
||||
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_8
|
||||
depends on BR2_INSTALL_LIBSTDCPP
|
||||
depends on BR2_TOOLCHAIN_HAS_THREADS # libdrm
|
||||
select BR2_PACKAGE_LIBDRM
|
||||
help
|
||||
libkms++ is a C++11 library for kernel mode setting.
|
||||
|
||||
Also included are simple test tools for KMS.
|
||||
|
||||
https://github.com/tomba/kmsxx
|
||||
|
||||
if BR2_PACKAGE_KMSXX
|
||||
|
||||
config BR2_PACKAGE_KMSXX_INSTALL_TESTS
|
||||
bool "Install test programs"
|
||||
help
|
||||
This option allows to install the kmsxx test programs.
|
||||
|
||||
endif
|
||||
|
||||
comment "kms++ needs a toolchain w/ threads, C++, gcc >= 4.8, headers >= 3.8"
|
||||
depends on !BR2_TOOLCHAIN_HAS_THREADS || !BR2_INSTALL_LIBSTDCPP || \
|
||||
!BR2_TOOLCHAIN_GCC_AT_LEAST_4_8 || !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_8
|
||||
2
bsp/buildroot/package/kmsxx/kmsxx.hash
Normal file
2
bsp/buildroot/package/kmsxx/kmsxx.hash
Normal file
@@ -0,0 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 ff8bdb84a738477a8740c835e23c5bb59aac750e9e72a4afcad4ec8820ec7da2 kmsxx-bd5f6471e619a6ba2987bc7f66ef78a531f94d6c.tar.gz
|
||||
54
bsp/buildroot/package/kmsxx/kmsxx.mk
Normal file
54
bsp/buildroot/package/kmsxx/kmsxx.mk
Normal file
@@ -0,0 +1,54 @@
|
||||
################################################################################
|
||||
#
|
||||
# kmsxx
|
||||
#
|
||||
################################################################################
|
||||
|
||||
KMSXX_VERSION = bd5f6471e619a6ba2987bc7f66ef78a531f94d6c
|
||||
KMSXX_SITE = $(call github,tomba,kmsxx,$(KMSXX_VERSION))
|
||||
KMSXX_LICENSE = MPLv2.0
|
||||
KMSXX_LICENSE_FILES = LICENSE
|
||||
KMSXX_INSTALL_STAGING = YES
|
||||
KMSXX_DEPENDENCIES = libdrm host-pkgconf
|
||||
KMSXX_CONF_OPTS = -DKMSXX_ENABLE_PYTHON=OFF
|
||||
|
||||
ifeq ($(BR2_PACKAGE_KMSXX_INSTALL_TESTS),y)
|
||||
KMSXX_TESTS = \
|
||||
fbtestpat kmsblank kmscapture \
|
||||
kmsprint kmsview testpat wbcap \
|
||||
wbm2m
|
||||
|
||||
define KMSXX_INSTALL_TARGET_TESTS
|
||||
$(foreach t,$(KMSXX_TESTS),\
|
||||
$(INSTALL) -D -m 0755 $(@D)/bin/$(t) \
|
||||
$(TARGET_DIR)/usr/bin/$(t)
|
||||
)
|
||||
endef
|
||||
endif
|
||||
|
||||
KMSXX_LIBS = kms++ kms++util
|
||||
|
||||
define KMSXX_INSTALL_TARGET_CMDS
|
||||
$(if $(BR2_SHARED_LIBS)$(BR2_SHARED_STATIC_LIBS),
|
||||
$(foreach l,$(KMSXX_LIBS),\
|
||||
$(INSTALL) -D -m 0755 $(@D)/lib/lib$(l).so \
|
||||
$(TARGET_DIR)/usr/lib/lib$(l).so
|
||||
)
|
||||
)
|
||||
$(KMSXX_INSTALL_TARGET_TESTS)
|
||||
endef
|
||||
|
||||
define KMSXX_INSTALL_STAGING_CMDS
|
||||
$(foreach l,$(KMSXX_LIBS),\
|
||||
$(if $(BR2_SHARED_LIBS)$(BR2_SHARED_STATIC_LIBS),
|
||||
$(INSTALL) -D -m 0755 $(@D)/lib/lib$(l).so \
|
||||
$(STAGING_DIR)/usr/lib/lib$(l).so)
|
||||
$(if $(BR2_STATIC_LIBS)$(BR2_SHARED_STATIC_LIBS),
|
||||
$(INSTALL) -D -m 0755 $(@D)/lib/lib$(l).a \
|
||||
$(STAGING_DIR)/usr/lib/lib$(l).a)
|
||||
mkdir -p $(STAGING_DIR)/usr/include/$(l)
|
||||
cp -dpfr $(@D)/$(l)/inc/$(l)/* $(STAGING_DIR)/usr/include/$(l)/
|
||||
)
|
||||
endef
|
||||
|
||||
$(eval $(cmake-package))
|
||||
Reference in New Issue
Block a user