Initial Commit

- initial default booting image
This commit is contained in:
2026-11-06 20:45:42 +01:00
commit b8783708ae
15201 changed files with 602532 additions and 0 deletions

View File

@@ -0,0 +1,65 @@
From 383c80bf486f806438bb11a9c9a9567407cd47ab Mon Sep 17 00:00:00 2001
From: "E.V.Acacia" <624758472@qq.com>
Date: Fri, 3 Sep 2021 14:19:37 +0800
Subject: [PATCH] solve: Compile error when gcc version is less than 5
[Retrieved from:
https://github.com/lyonel/lshw/pull/70/commits/383c80bf486f806438bb11a9c9a9567407cd47ab]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
src/core/cpuinfo.cc | 8 ++++----
src/core/hw.cc | 2 +-
src/core/spd.cc | 4 ++--
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/src/core/cpuinfo.cc b/src/core/cpuinfo.cc
index 9e41a421..ed1c4164 100644
--- a/src/core/cpuinfo.cc
+++ b/src/core/cpuinfo.cc
@@ -465,13 +465,13 @@ string value)
if (id == "model name")
cpu->setProduct(value);
if (id == "microcode")
- cpu->setConfig(id, stoll(value, NULL, 0));
+ cpu->setConfig(id, strtoll(value.c_str(), NULL, 0));
if (id == "cpu family")
- cpu->addHint(id, stoll(value, NULL, 0));
+ cpu->addHint(id, strtoll(value.c_str(), NULL, 0));
if (id == "model")
- cpu->addHint(id, stoll(value, NULL, 0));
+ cpu->addHint(id, strtoll(value.c_str(), NULL, 0));
if (id == "stepping")
- cpu->addHint(id, stoll(value, NULL, 0));
+ cpu->addHint(id, strtoll(value.c_str(), NULL, 0));
family = cpu->getHint("cpu family");
model = cpu->getHint("model");
diff --git a/src/core/hw.cc b/src/core/hw.cc
index 1c1dad46..b266a863 100644
--- a/src/core/hw.cc
+++ b/src/core/hw.cc
@@ -2459,7 +2459,7 @@ long long value::asInteger() const
switch(This->type)
{
case hw::text:
- return stoll(This->s, NULL, 0);
+ return strtoll(This->s.c_str(), NULL, 0);
case hw::integer:
return This->ll;
case hw::boolean:
diff --git a/src/core/spd.cc b/src/core/spd.cc
index a304d061..2ad66b82 100644
--- a/src/core/spd.cc
+++ b/src/core/spd.cc
@@ -195,9 +195,9 @@ static bool scan_eeproms(hwNode & memory)
{
if (scan_eeprom(memory, namelist[i]->d_name))
current_bank++;
- free(namelist[i]);
+ delete(namelist[i]);
}
- free(namelist);
+ delete(namelist);
return true;
}

17
package/lshw/Config.in Normal file
View File

@@ -0,0 +1,17 @@
config BR2_PACKAGE_LSHW
bool "lshw"
depends on BR2_INSTALL_LIBSTDCPP
depends on BR2_USE_WCHAR
select BR2_PACKAGE_HWDATA # runtime
select BR2_PACKAGE_HWDATA_PCI_IDS
select BR2_PACKAGE_HWDATA_PNP_IDS
select BR2_PACKAGE_HWDATA_USB_IDS
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

3
package/lshw/lshw.hash Normal file
View File

@@ -0,0 +1,3 @@
# Locally calculated
sha256 6b8346a89fb0f0f1798e66f6a707a881d38b9b3a67256b30fc4628dac09f291a lshw-02.20.tar.gz
sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 COPYING

53
package/lshw/lshw.mk Normal file
View File

@@ -0,0 +1,53 @@
################################################################################
#
# lshw
#
################################################################################
LSHW_VERSION = 02.20
LSHW_SITE = $(call github,lyonel,lshw,B.$(LSHW_VERSION))
LSHW_LICENSE = GPL-2.0
LSHW_LICENSE_FILES = COPYING
LSHW_DEPENDENCIES = $(TARGET_NLS_DEPENDENCIES)
LSHW_MAKE_OPTS = \
CC="$(TARGET_CC)" \
CXX="$(TARGET_CXX)" \
AR="$(TARGET_AR)" \
LANGUAGES= \
RPM_OPT_FLAGS="$(TARGET_CFLAGS)"
LSHW_MAKE_ENV = \
$(TARGET_MAKE_ENV) \
LIBS=$(TARGET_NLS_LIBS)
ifeq ($(BR2_PACKAGE_SQLITE),y)
LSHW_DEPENDENCIES += host-pkgconf sqlite
LSHW_MAKE_OPTS += SQLITE=1
else
LSHW_MAKE_OPTS += SQLITE=0
endif
ifeq ($(BR2_PACKAGE_ZLIB),y)
LSHW_DEPENDENCIES += host-pkgconf zlib
LSHW_MAKE_OPTS += ZLIB=1
else
LSHW_MAKE_OPTS += ZLIB=0
endif
define LSHW_BUILD_CMDS
$(LSHW_MAKE_ENV) $(MAKE) -C $(@D)/src \
$(LSHW_MAKE_OPTS) \
all
endef
define LSHW_INSTALL_TARGET_CMDS
$(LSHW_MAKE_ENV) $(MAKE) -C $(@D)/src \
$(LSHW_MAKE_OPTS) \
DESTDIR=$(TARGET_DIR) \
install
$(RM) -rf $(TARGET_DIR)/usr/share/lshw
endef
$(eval $(generic-package))