I have created a custom package for buildroot and put it in an external buildroot tree.
I have enabled it by using make menuconfig BR_EXTERNAL=../buildroot-external
It is build successfully when triggered with make mypackage
.
However when run make clean && make BR_EXTERNAL=../buildroot-external
everything rebuilds while my custom package is simply forgotten.
I want it to be automatically compiled as all the other packages.
As I am still developing that package the sourcecode is stored locally which is configured in the ../buildroot-external/locals.mk
For completeness those are the config-files for defining the package:
config BR2_PACKAGE_MY_PACKAGE
bool "MyPackage"
help
Some help about MyPackage
################################################################################
#
# mypackage
#
################################################################################
MYPACKAGE_VERSION = 1.0
MYPACKAGE_SOURCE = mypackage
# PACKAGE_OVERRIDE_SRC_DIR set in buildroot-external/local.mk
# sources are taken from local folder to ease development
MYPACKAGE_LICENSE = GPL-3.0+
MYPACKAGE_LICENSE_FILES = COPYING
define MYPACKAGE_BUILD_CMDS
$(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(@D)/Buildserver all
endef
define MYPACKAGE_INSTALL_TARGET_CMDS
$(INSTALL) -D -m 0755 $(@D)/Buildserver/MyPackage $(TARGET_DIR)/root/MyPackageBamboo
endef
$(eval $(generic-package))
Enter make menuconfig
, enable your package, exit saving changes.
Now make
will build your package too.
This is because by default nearly all packages are disabled since Buildroot cannot know what you need on your target root filesystem.