Add BR2_EXTERNAL skeleton

This commit is contained in:
2026-03-27 20:57:59 -03:00
parent 27cfa662a3
commit 162a815132
16 changed files with 632 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
config BR2_PACKAGE_MY_COMMON_TOOL
bool "my-common-tool"
select BR2_PACKAGE_MY_SHARED_LIB
help
A command-line utility shared across multiple Raspberry Pi
projects. Depends on my-shared-lib.
Installs the 'my-common-tool' binary into /usr/bin on the target.
https://github.com/your-org/my-common-tool

View File

@@ -0,0 +1,22 @@
################################################################################
#
# my-common-tool
#
################################################################################
MY_COMMON_TOOL_VERSION = 1.0.0
MY_COMMON_TOOL_SITE = https://github.com/your-org/my-common-tool.git
MY_COMMON_TOOL_SITE_METHOD = git
MY_COMMON_TOOL_LICENSE = MIT
MY_COMMON_TOOL_LICENSE_FILES = LICENSE
MY_COMMON_TOOL_DEPENDENCIES = my-shared-lib
define MY_COMMON_TOOL_BUILD_CMDS
$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)
endef
define MY_COMMON_TOOL_INSTALL_TARGET_CMDS
$(INSTALL) -D -m 0755 $(@D)/my-common-tool $(TARGET_DIR)/usr/bin/my-common-tool
endef
$(eval $(generic-package))

View File

@@ -0,0 +1,9 @@
config BR2_PACKAGE_MY_SHARED_LIB
bool "my-shared-lib"
help
A shared library providing common functionality used across
multiple Raspberry Pi projects.
Installs libmyshared.so into /usr/lib on the target.
https://github.com/your-org/my-shared-lib

View File

@@ -0,0 +1,22 @@
################################################################################
#
# my-shared-lib
#
################################################################################
# IMPORTANT: Update this version and hash when upgrading the package.
# The hash file (my-shared-lib.hash) should also be updated accordingly.
MY_SHARED_LIB_VERSION = 1.0.0
MY_SHARED_LIB_SITE = https://github.com/your-org/my-shared-lib.git
MY_SHARED_LIB_SITE_METHOD = git
MY_SHARED_LIB_LICENSE = MIT
MY_SHARED_LIB_LICENSE_FILES = LICENSE
MY_SHARED_LIB_INSTALL_STAGING = YES
# CMake options passed to the package's build.
# Add any project-specific CMake definitions here.
MY_SHARED_LIB_CONF_OPTS = \
-DBUILD_TESTS=OFF \
-DBUILD_EXAMPLES=OFF
$(eval $(cmake-package))