update buildroot to 2017.02.11
This commit is contained in:
@@ -0,0 +1,44 @@
|
||||
From 5af98ca8135ac411364b16720d795224a9b4a178 Mon Sep 17 00:00:00 2001
|
||||
From: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
||||
Date: Sat, 30 Jul 2016 15:15:14 +0200
|
||||
Subject: [PATCH] Makefile: allow to pass additional LIBS
|
||||
|
||||
We need to be able to pass extra LIBS when our toolchain lacks NLS
|
||||
support, this way we can build libintl and link to it. A good example
|
||||
is uClibc with locale support disabled.
|
||||
|
||||
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
||||
---
|
||||
src/Makefile | 2 +-
|
||||
src/gui/Makefile | 2 +-
|
||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/Makefile b/src/Makefile
|
||||
index b50586b..acbdbfa 100644
|
||||
--- a/src/Makefile
|
||||
+++ b/src/Makefile
|
||||
@@ -30,7 +30,7 @@ ifneq ($(shell $(LD) --help 2| grep -- --as-needed), )
|
||||
LDFLAGS+= -Wl,--as-needed
|
||||
endif
|
||||
LDSTATIC=-static
|
||||
-LIBS=-llshw -lresolv
|
||||
+LIBS+=-llshw -lresolv
|
||||
ifeq ($(SQLITE), 1)
|
||||
LIBS+= $(shell pkg-config --libs sqlite3)
|
||||
endif
|
||||
diff --git a/src/gui/Makefile b/src/gui/Makefile
|
||||
index 332ce57..7f72e3f 100644
|
||||
--- a/src/gui/Makefile
|
||||
+++ b/src/gui/Makefile
|
||||
@@ -11,7 +11,7 @@ INCLUDES=-I../core $(GTKINCLUDES)
|
||||
CXXFLAGS=-g -Wall $(INCLUDES) $(DEFINES) $(RPM_OPT_FLAGS)
|
||||
CFLAGS=$(CXXFLAGS) $(DEFINES)
|
||||
GTKLIBS=$(shell pkg-config gtk+-2.0 gmodule-2.0 --libs)
|
||||
-LIBS=-L../core -llshw -lresolv $(GTKLIBS)
|
||||
+LIBS+=-L../core -llshw -lresolv $(GTKLIBS)
|
||||
LDFLAGS=
|
||||
ifneq ($(shell $(LD) --help 2| grep -- --as-needed), )
|
||||
LDFLAGS+= -Wl,--as-needed
|
||||
--
|
||||
2.7.4
|
||||
|
||||
@@ -0,0 +1,78 @@
|
||||
From 016bdb133a44bdf42c268ff72ee7aa04af19cfd3 Mon Sep 17 00:00:00 2001
|
||||
From: "Arnout Vandecappelle (Essensium/Mind)" <arnout@mind.be>
|
||||
Date: Sat, 27 Aug 2016 01:11:56 +0200
|
||||
Subject: [PATCH] Fix musl build: basename() is in libgen.h.
|
||||
|
||||
Also, its argument is not const, so add const_cast. This is risky
|
||||
because in fact basename() will modify the argument if it ends with /
|
||||
but that's not the case here.
|
||||
|
||||
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
|
||||
---
|
||||
src/core/dasd.cc | 1 +
|
||||
src/core/sysfs.cc | 9 +++++----
|
||||
2 files changed, 6 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/core/dasd.cc b/src/core/dasd.cc
|
||||
index 626b8a8..6276101 100644
|
||||
--- a/src/core/dasd.cc
|
||||
+++ b/src/core/dasd.cc
|
||||
@@ -9,6 +9,7 @@
|
||||
#include <sys/ioctl.h>
|
||||
#include <linux/fs.h>
|
||||
#include <map>
|
||||
+#include <libgen.h>
|
||||
|
||||
using namespace std;
|
||||
|
||||
diff --git a/src/core/sysfs.cc b/src/core/sysfs.cc
|
||||
index acc9d00..bdd69e3 100644
|
||||
--- a/src/core/sysfs.cc
|
||||
+++ b/src/core/sysfs.cc
|
||||
@@ -16,6 +16,7 @@
|
||||
#include <sys/stat.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/mount.h>
|
||||
+#include <libgen.h>
|
||||
|
||||
__ID("@(#) $Id$");
|
||||
|
||||
@@ -99,7 +100,7 @@ static string sysfs_getbustype(const string & path)
|
||||
{
|
||||
devname =
|
||||
string(fs.path + "/bus/") + string(namelist[i]->d_name) +
|
||||
- "/devices/" + basename(path.c_str());
|
||||
+ "/devices/" + basename(const_cast<char*>(path.c_str()));
|
||||
|
||||
if (samefile(devname, path))
|
||||
return string(namelist[i]->d_name);
|
||||
@@ -139,7 +140,7 @@ static string sysfstobusinfo(const string & path)
|
||||
|
||||
if (bustype == "virtio")
|
||||
{
|
||||
- string name = basename(path.c_str());
|
||||
+ string name = basename(const_cast<char*>(path.c_str()));
|
||||
if (name.compare(0, 6, "virtio") == 0)
|
||||
return "virtio@" + name.substr(6);
|
||||
else
|
||||
@@ -207,7 +208,7 @@ string entry::driver() const
|
||||
string driverlink = This->devpath + "/driver";
|
||||
if (!exists(driverlink))
|
||||
return "";
|
||||
- return basename(readlink(driverlink).c_str());
|
||||
+ return basename(const_cast<char*>(readlink(driverlink).c_str()));
|
||||
}
|
||||
|
||||
|
||||
@@ -288,7 +289,7 @@ string entry::name_in_class(const string & classname) const
|
||||
|
||||
string entry::name() const
|
||||
{
|
||||
- return basename(This->devpath.c_str());
|
||||
+ return basename(const_cast<char*>(This->devpath.c_str()));
|
||||
}
|
||||
|
||||
|
||||
--
|
||||
2.9.3
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
From 50284ac4400ac3d7562f4765726492caee8ff547 Mon Sep 17 00:00:00 2001
|
||||
From: "Arnout Vandecappelle (Essensium/Mind)" <arnout@mind.be>
|
||||
Date: Sat, 27 Aug 2016 01:15:13 +0200
|
||||
Subject: [PATCH] Fix use of LONG_BIT
|
||||
|
||||
LONG_BIT is not a sysconf value, it is either 32 or 64. Using it as
|
||||
a sysconf value will give weird results.
|
||||
|
||||
Originally it was sysconf(_SC_LONG_BIT) (before it was "fixed" by the
|
||||
gentoo guys). But this is useless: it will always return a value
|
||||
equal to LONG_BIT: it's either compiled 32-bit or 64-bit so a runtime
|
||||
lookup doesn't make sense. For this reason, musl has removed the
|
||||
definition of _SC_LONG_BIT.
|
||||
|
||||
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
|
||||
---
|
||||
src/core/abi.cc | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/core/abi.cc b/src/core/abi.cc
|
||||
index 76e5082..a13daaa 100644
|
||||
--- a/src/core/abi.cc
|
||||
+++ b/src/core/abi.cc
|
||||
@@ -19,8 +19,7 @@ __ID("@(#) $Id: mem.cc 1352 2006-05-27 23:54:13Z ezix $");
|
||||
|
||||
bool scan_abi(hwNode & system)
|
||||
{
|
||||
- // are we compiled as 32- or 64-bit process ?
|
||||
- system.setWidth(sysconf(LONG_BIT));
|
||||
+ system.setWidth(LONG_BIT);
|
||||
|
||||
pushd(PROC_SYS);
|
||||
|
||||
--
|
||||
2.9.3
|
||||
|
||||
13
bsp/buildroot-2017.02.11/package/lshw/Config.in
Normal file
13
bsp/buildroot-2017.02.11/package/lshw/Config.in
Normal file
@@ -0,0 +1,13 @@
|
||||
config BR2_PACKAGE_LSHW
|
||||
bool "lshw"
|
||||
depends on BR2_INSTALL_LIBSTDCPP
|
||||
depends on BR2_USE_WCHAR
|
||||
select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE
|
||||
help
|
||||
lshw (Hardware Lister) is a small tool to provide
|
||||
detailed information on the hardware configuration of the machine.
|
||||
|
||||
http://ezix.org/project/wiki/HardwareLiSter
|
||||
|
||||
comment "lshw needs a toolchain w/ C++, wchar"
|
||||
depends on !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR
|
||||
2
bsp/buildroot-2017.02.11/package/lshw/lshw.hash
Normal file
2
bsp/buildroot-2017.02.11/package/lshw/lshw.hash
Normal file
@@ -0,0 +1,2 @@
|
||||
# Locally calculated
|
||||
sha256 ae22ef11c934364be4fd2a0a1a7aadf4495a0251ec6979da280d342a89ca3c2f lshw-B.02.18.tar.gz
|
||||
33
bsp/buildroot-2017.02.11/package/lshw/lshw.mk
Normal file
33
bsp/buildroot-2017.02.11/package/lshw/lshw.mk
Normal file
@@ -0,0 +1,33 @@
|
||||
################################################################################
|
||||
#
|
||||
# lshw
|
||||
#
|
||||
################################################################################
|
||||
|
||||
LSHW_VERSION = B.02.18
|
||||
LSHW_SITE = http://ezix.org/software/files
|
||||
LSHW_LICENSE = GPLv2
|
||||
LSHW_LICENSE_FILES = COPYING
|
||||
|
||||
LSHW_CFLAGS = $(TARGET_CFLAGS)
|
||||
ifeq ($(BR2_ENABLE_LOCALE),)
|
||||
LSHW_CFLAGS += -DNONLS
|
||||
endif
|
||||
|
||||
LSHW_MAKE_OPTS = CC="$(TARGET_CC)" CXX="$(TARGET_CXX)" AR="$(TARGET_AR)" \
|
||||
RPM_OPT_FLAGS="$(LSHW_CFLAGS)" all
|
||||
LSHW_MAKE_ENV = \
|
||||
$(TARGET_MAKE_ENV) \
|
||||
LIBS="$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),-lintl)"
|
||||
LSHW_DEPENDENCIES = $(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
|
||||
|
||||
define LSHW_BUILD_CMDS
|
||||
$(LSHW_MAKE_ENV) $(MAKE) -C $(@D)/src $(LSHW_MAKE_OPTS)
|
||||
endef
|
||||
|
||||
define LSHW_INSTALL_TARGET_CMDS
|
||||
$(LSHW_MAKE_ENV) $(MAKE) -C $(@D)/src DESTDIR=$(TARGET_DIR) \
|
||||
$(LSHW_MAKE_OPTS) install
|
||||
endef
|
||||
|
||||
$(eval $(generic-package))
|
||||
Reference in New Issue
Block a user