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,47 @@
From 68d3b1dfbbd2f54bf81986d1d733deaf66658b15 Mon Sep 17 00:00:00 2001
From: Davide Viti <zinosat@tiscali.it>
Date: Thu, 14 Jul 2016 10:14:59 +0100
Subject: [PATCH] rename cmake rootfile
ctest fails on the target, because it cannot find CMake.cmake inside
CMAKE_DATA_DIR (typically set to "/usr/share/cmake-3.0"): all *.cmake
files are removed at build time via the target-finalize rule.
This buildroot-specific patch makes sure ctest looks also for
"Modules/CMake.cmake.ctest" before complaining
Upstream: N/A (specific to buildroot)
[Vincent: tweak patch for 3.6.3]
[James: tweak patch for 3.15.4]
[Bernd: rebased for 4.3.0]
Signed-off-by: Davide Viti <zinosat@tiscali.it>
Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
---
Source/cmake.cxx | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index 3772f09985..c317e4af38 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -1987,7 +1987,12 @@ int cmake::AddCMakePaths()
cmStateEnums::INTERNAL);
#endif
if (!cmSystemTools::FileExists(
- (cmSystemTools::GetCMakeRoot() + "/Modules/CMake.cmake"))) {
+ (cmSystemTools::GetCMakeRoot() + "/Modules/CMake.cmake")) &&
+ !cmSystemTools::FileExists(
+ (cmSystemTools::GetCMakeRoot()+"/Modules/CMake.cmake.ctest")
+ )
+ )
+ {
// couldn't find modules
cmSystemTools::Error(
cmStrCat("Could not find CMAKE_ROOT !!!\n"
--
2.20.1

49
package/cmake/Config.in Normal file
View File

@@ -0,0 +1,49 @@
config BR2_PACKAGE_CMAKE_ARCH_SUPPORTS
bool
default y
depends on BR2_arm || BR2_armeb || BR2_aarch64 || \
BR2_m68k || BR2_mips || BR2_mips64 || \
BR2_mipsel || BR2_mips64el || BR2_powerpc || \
BR2_powerpc64 || BR2_powerpc64le || BR2_sparc || \
BR2_i386 || BR2_x86_64 || BR2_xtensa || \
BR2_s390x || BR2_riscv
config BR2_PACKAGE_CMAKE
bool
config BR2_PACKAGE_CMAKE_CTEST
bool "ctest"
depends on BR2_PACKAGE_CMAKE_ARCH_SUPPORTS
depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # jsoncpp, libuv
depends on BR2_USE_WCHAR # libarchive
depends on BR2_INSTALL_LIBSTDCPP
depends on !BR2_STATIC_LIBS
depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # libuv
depends on BR2_USE_MMU # libuv
depends on BR2_TOOLCHAIN_HAS_SYNC_4 # libuv
select BR2_PACKAGE_CMAKE
select BR2_PACKAGE_ZLIB
select BR2_PACKAGE_JSONCPP
select BR2_PACKAGE_LIBCURL
select BR2_PACKAGE_LIBARCHIVE
select BR2_PACKAGE_EXPAT
select BR2_PACKAGE_BZIP2
select BR2_PACKAGE_XZ
select BR2_PACKAGE_LIBUV
select BR2_PACKAGE_RHASH
help
CTest is a testing tool distributed as a part of CMake. It
can be used to automate updating (using CVS for example),
configuring, building, testing, performing memory checking,
performing coverage, and submitting results to a CDash or
Dart dashboard system.
http://www.cmake.org/
comment "ctest needs a toolchain w/ C++, wchar, dynamic library, gcc >= 4.9, NPTL"
depends on BR2_PACKAGE_CMAKE_ARCH_SUPPORTS
depends on BR2_USE_MMU
depends on BR2_TOOLCHAIN_HAS_SYNC_4
depends on !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR || \
BR2_STATIC_LIBS || !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 || \
!BR2_TOOLCHAIN_HAS_THREADS_NPTL

View File

@@ -0,0 +1,108 @@
config BR2_PACKAGE_HOST_CMAKE
bool "host cmake"
help
CMake is an open-source, cross-platform family of tools
designed to build, test and package software. CMake is used
to control the software compilation process using simple
platform and compiler independent configuration files, and
generate native makefiles and workspaces that can be used in
the compiler environment of your choice.
http://www.cmake.org/
# The minimum system cmake version we expect if 3.18 as provided by
# Debian bullseye, that we use in our reference build docker image.
config BR2_HOST_CMAKE_AT_LEAST_3_19
bool
config BR2_HOST_CMAKE_AT_LEAST_3_20
bool
select BR2_HOST_CMAKE_AT_LEAST_3_19
config BR2_HOST_CMAKE_AT_LEAST_3_21
bool
select BR2_HOST_CMAKE_AT_LEAST_3_20
config BR2_HOST_CMAKE_AT_LEAST_3_22
bool
select BR2_HOST_CMAKE_AT_LEAST_3_21
config BR2_HOST_CMAKE_AT_LEAST_3_23
bool
select BR2_HOST_CMAKE_AT_LEAST_3_22
config BR2_HOST_CMAKE_AT_LEAST_3_24
bool
select BR2_HOST_CMAKE_AT_LEAST_3_23
config BR2_HOST_CMAKE_AT_LEAST_3_25
bool
select BR2_HOST_CMAKE_AT_LEAST_3_24
config BR2_HOST_CMAKE_AT_LEAST_3_26
bool
select BR2_HOST_CMAKE_AT_LEAST_3_25
config BR2_HOST_CMAKE_AT_LEAST_3_27
bool
select BR2_HOST_CMAKE_AT_LEAST_3_26
config BR2_HOST_CMAKE_AT_LEAST_3_28
bool
select BR2_HOST_CMAKE_AT_LEAST_3_27
config BR2_HOST_CMAKE_AT_LEAST_3_29
bool
select BR2_HOST_CMAKE_AT_LEAST_3_28
config BR2_HOST_CMAKE_AT_LEAST_3_30
bool
select BR2_HOST_CMAKE_AT_LEAST_3_29
config BR2_HOST_CMAKE_AT_LEAST_3_31
bool
select BR2_HOST_CMAKE_AT_LEAST_3_30
config BR2_HOST_CMAKE_AT_LEAST_4_0
bool
select BR2_HOST_CMAKE_AT_LEAST_3_31
config BR2_HOST_CMAKE_AT_LEAST_4_1
bool
select BR2_HOST_CMAKE_AT_LEAST_4_0
config BR2_HOST_CMAKE_AT_LEAST_4_2
bool
select BR2_HOST_CMAKE_AT_LEAST_4_1
config BR2_HOST_CMAKE_AT_LEAST_4_3
bool
select BR2_HOST_CMAKE_AT_LEAST_4_2
config BR2_HOST_CMAKE_AT_LEAST_4_4
bool
select BR2_HOST_CMAKE_AT_LEAST_4_3
# This order guarantees that the highest version is set, as kconfig
# stops affecting a value on the first matching default.
config BR2_HOST_CMAKE_AT_LEAST
string
default "4.4" if BR2_HOST_CMAKE_AT_LEAST_4_4
default "4.3" if BR2_HOST_CMAKE_AT_LEAST_4_3
default "4.2" if BR2_HOST_CMAKE_AT_LEAST_4_2
default "4.1" if BR2_HOST_CMAKE_AT_LEAST_4_1
default "4.0" if BR2_HOST_CMAKE_AT_LEAST_4_0
default "3.31" if BR2_HOST_CMAKE_AT_LEAST_3_31
default "3.30" if BR2_HOST_CMAKE_AT_LEAST_3_30
default "3.29" if BR2_HOST_CMAKE_AT_LEAST_3_29
default "3.28" if BR2_HOST_CMAKE_AT_LEAST_3_28
default "3.27" if BR2_HOST_CMAKE_AT_LEAST_3_27
default "3.26" if BR2_HOST_CMAKE_AT_LEAST_3_26
default "3.25" if BR2_HOST_CMAKE_AT_LEAST_3_25
default "3.24" if BR2_HOST_CMAKE_AT_LEAST_3_24
default "3.23" if BR2_HOST_CMAKE_AT_LEAST_3_23
default "3.22" if BR2_HOST_CMAKE_AT_LEAST_3_22
default "3.21" if BR2_HOST_CMAKE_AT_LEAST_3_21
default "3.20" if BR2_HOST_CMAKE_AT_LEAST_3_20
default "3.19" if BR2_HOST_CMAKE_AT_LEAST_3_19
default "3.18"

5
package/cmake/cmake.hash Normal file
View File

@@ -0,0 +1,5 @@
# From https://cmake.org/files/v4.4/cmake-4.4.0-SHA-256.txt
sha256 65757f442fdd242e27f1728fc26dc0cba4164f7a0791a5c788631c00080369bc cmake-4.4.0.tar.gz
# Locally calculated
sha256 4382e7c1879ac90e3f101a395d23846fa4dbcaa1eed7265b43681e348754825d LICENSE.rst

97
package/cmake/cmake.mk Normal file
View File

@@ -0,0 +1,97 @@
################################################################################
#
# cmake
#
################################################################################
# When updating the version, please also update BR2_HOST_CMAKE_AT_LEAST_X_Y
CMAKE_VERSION_MAJOR = 4.4
CMAKE_VERSION = $(CMAKE_VERSION_MAJOR).0
CMAKE_SITE = https://cmake.org/files/v$(CMAKE_VERSION_MAJOR)
CMAKE_LICENSE = BSD-3-Clause
CMAKE_LICENSE_FILES = LICENSE.rst
CMAKE_CPE_ID_VALID = YES
# The package is a dependency to ccache so ccache cannot be a dependency
HOST_CMAKE_ADD_CCACHE_DEPENDENCY = NO
# CMake is a particular package:
# * CMake can be built using the generic infrastructure or the cmake one.
# Since Buildroot has no requirement regarding the host system cmake
# program presence, it uses the generic infrastructure to build the
# host-cmake package, then the (target-)cmake package can be built
# using the cmake infrastructure;
# * CMake bundles its dependencies within its sources. This is the
# reason why the host-cmake package has no dependencies:, whereas
# the (target-)cmake package has a lot of dependencies, using only
# the system-wide libraries instead of rebuilding and statically
# linking with the ones bundled into the CMake sources.
CMAKE_DEPENDENCIES = zlib jsoncpp libcurl libarchive expat bzip2 xz libuv rhash
CMAKE_CONF_OPTS = \
-DKWSYS_LFS_WORKS=TRUE \
-DKWSYS_CHAR_IS_SIGNED=TRUE \
-DCMAKE_USE_SYSTEM_LIBRARIES=1 \
-DCTEST_USE_XMLRPC=OFF \
-DCMake_ENABLE_DEBUGGER=0 \
-DBUILD_CursesDialog=OFF
# Get rid of -I* options from $(HOST_CPPFLAGS) to prevent that a
# header available in $(HOST_DIR)/include is used instead of a
# CMake internal header, e.g. lzma* headers of the xz package
HOST_CMAKE_CFLAGS = $(shell echo $(HOST_CFLAGS) | sed -r "s%$(HOST_CPPFLAGS)%%")
HOST_CMAKE_CXXFLAGS = $(shell echo $(HOST_CXXFLAGS) | sed -r "s%$(HOST_CPPFLAGS)%%")
# We may be a ccache dependency, so we can't use ccache
HOST_CMAKE_CONFIGURE_OPTS = \
$(HOST_CONFIGURE_OPTS) \
CC="$(HOSTCC_NOCCACHE)" \
GCC="$(HOSTCC_NOCCACHE)" \
CXX="$(HOSTCXX_NOCCACHE)"
define HOST_CMAKE_CONFIGURE_CMDS
(cd $(@D); \
$(HOST_CMAKE_CONFIGURE_OPTS) \
CFLAGS="$(HOST_CMAKE_CFLAGS)" \
./bootstrap --prefix=$(HOST_DIR) \
--parallel=$(PARALLEL_JOBS) -- \
-DCMAKE_C_FLAGS="$(HOST_CMAKE_CFLAGS)" \
-DCMAKE_CXX_FLAGS="$(HOST_CMAKE_CXXFLAGS)" \
-DCMAKE_EXE_LINKER_FLAGS="$(HOST_LDFLAGS)" \
-DCMAKE_USE_OPENSSL:BOOL=OFF \
-DBUILD_CursesDialog=OFF \
)
endef
define HOST_CMAKE_BUILD_CMDS
$(HOST_MAKE_ENV) $(MAKE) -C $(@D)
endef
define HOST_CMAKE_INSTALL_CMDS
$(HOST_MAKE_ENV) $(MAKE) -C $(@D) install/fast
endef
define CMAKE_REMOVE_EXTRA_DATA
rm $(TARGET_DIR)/usr/bin/{cmake,cpack}
rm -fr $(TARGET_DIR)/usr/share/cmake-$(CMAKE_VERSION_MAJOR)/{completions,editors}
rm -fr $(TARGET_DIR)/usr/share/cmake-$(CMAKE_VERSION_MAJOR)/{Help,include}
endef
define CMAKE_INSTALL_CTEST_CFG_FILE
$(INSTALL) -m 0644 -D $(@D)/Modules/CMake.cmake \
$(TARGET_DIR)/usr/share/cmake-$(CMAKE_VERSION_MAJOR)/Modules/CMake.cmake.ctest
endef
CMAKE_POST_INSTALL_TARGET_HOOKS += CMAKE_REMOVE_EXTRA_DATA
CMAKE_POST_INSTALL_TARGET_HOOKS += CMAKE_INSTALL_CTEST_CFG_FILE
define CMAKE_INSTALL_TARGET_CMDS
(cd $(@D); \
$(HOST_MAKE_ENV) DESTDIR=$(TARGET_DIR) \
cmake -P cmake_install.cmake \
)
endef
$(eval $(cmake-package))
$(eval $(host-generic-package))