Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dff0ded43d |
+3
-1
@@ -1,3 +1,5 @@
|
|||||||
curses
|
curses
|
||||||
.config
|
.config
|
||||||
.config.old
|
.config.old
|
||||||
|
dl
|
||||||
|
output
|
||||||
|
|||||||
@@ -31,31 +31,11 @@ UC = $(shell echo $(Command) | tr '[:lower:]' '[:upper:]')
|
|||||||
# $(call CMD_INSTALL_$(call UC))
|
# $(call CMD_INSTALL_$(call UC))
|
||||||
|
|
||||||
all:
|
all:
|
||||||
$(call CMD_CONFIGURE_UCLIBC)
|
$(call download,busybox)
|
||||||
$(call CMD_BUILD_UCLIBC)
|
|
||||||
$(call CMD_INSTALL_UCLIBC)
|
|
||||||
|
|
||||||
$(call CMD_CONFIGURE_BUSYBOX)
|
$(call CMD_CONFIGURE_BUSYBOX)
|
||||||
$(call CMD_BUILD_BUSYBOX)
|
$(call CMD_BUILD_BUSYBOX)
|
||||||
$(call CMD_INSTALL_BUSYBOX)
|
$(call CMD_INSTALL_BUSYBOX)
|
||||||
|
|
||||||
$(call CMD_CONFIGURE_ZLIB)
|
|
||||||
$(call CMD_BUILD_ZLIB)
|
|
||||||
$(call CMD_INSTALL_ZLIB)
|
|
||||||
|
|
||||||
$(call CMD_CONFIGURE_DROPBEAR)
|
|
||||||
$(call CMD_BUILD_DROPBEAR)
|
|
||||||
$(call CMD_INSTALL_DROPBEAR)
|
|
||||||
ifeq (CONFIG_SIMPLE_SFTP_SERVER_DROPBEAR,y)
|
|
||||||
$(call CMD_CONFIGURE_SFTP_SERVER_DROPBEAR)
|
|
||||||
$(call CMD_BUILD_SFTP_SERVER_DROPBEAR)
|
|
||||||
$(call CMD_INSTALL_SFTP_SERVER_DROPBEAR)
|
|
||||||
endif
|
|
||||||
|
|
||||||
$(call CMD_CONFIGURE_UBOOT)
|
|
||||||
$(call CMD_BUILD_UBOOT)
|
|
||||||
$(call CMD_INSTALL_UBOOT)
|
|
||||||
|
|
||||||
list-defconfigs:
|
list-defconfigs:
|
||||||
$(call list-defconfigs,$(TOPDIR))
|
$(call list-defconfigs,$(TOPDIR))
|
||||||
|
|
||||||
@@ -68,4 +48,26 @@ list-defconfigs:
|
|||||||
)
|
)
|
||||||
$(call successmsg,Copy defconfig: $@ to .config is OK)
|
$(call successmsg,Copy defconfig: $@ to .config is OK)
|
||||||
|
|
||||||
.PHONY: %_defconfig
|
%-dirclean:
|
||||||
|
$(call msg,Deleting: $(call split-,$@,1) build directory)
|
||||||
|
$(if \
|
||||||
|
$(wildcard $(TOPDIR)/output/build/$(call split-,$@,1)), \
|
||||||
|
$(call delete,$(TOPDIR)/output/build/$(call split-,$@,1)), \
|
||||||
|
$(call msg,$(TOPDIR)/output/build/$(call split-,$@,1): not exists) \
|
||||||
|
)
|
||||||
|
$(call successmsg,Delete: $(call split-,$@,1) build directory)
|
||||||
|
|
||||||
|
source:
|
||||||
|
$(call msg,Downloading busybox)
|
||||||
|
$(call download,busybox)
|
||||||
|
$(call successmsg,Download busybox)
|
||||||
|
|
||||||
|
distclean:
|
||||||
|
@if [ -d $(TOPDIR)/dl ]; then \
|
||||||
|
rm -rv dl; \
|
||||||
|
fi
|
||||||
|
@if [ -d $(TOPDIR)/output ]; then \
|
||||||
|
rm -rv output; \
|
||||||
|
fi
|
||||||
|
|
||||||
|
.PHONY: %_defconfig source %-dirclean list-defconfigs
|
||||||
|
|||||||
@@ -1,8 +1,11 @@
|
|||||||
|
BUSYBOX_VERSION = 1.36.1
|
||||||
|
BUSYBOX_SITE = https://www.busybox.net/downloads
|
||||||
|
BUSYBOX_SOURCE = busybox-$(BUSYBOX_VERSION).tar.bz2
|
||||||
|
|
||||||
define CMD_CONFIGURE_BUSYBOX
|
define CMD_CONFIGURE_BUSYBOX
|
||||||
$(call msg,configure_busybox)
|
$(call msg,configure_busybox)
|
||||||
$(call warningmsg,configure_busybox)
|
$(call warningmsg,configure_busybox)
|
||||||
$(call successmsg,configure_busybox)
|
$(call successmsg,configure_busybox)
|
||||||
$(call errmsg,configure_busybox)
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define CMD_BUILD_BUSYBOX
|
define CMD_BUILD_BUSYBOX
|
||||||
|
|||||||
+24
-1
@@ -5,7 +5,6 @@ green_background_color = \033[42m
|
|||||||
high_intensity_yellow_background_color = \033[103m
|
high_intensity_yellow_background_color = \033[103m
|
||||||
high_intensity_red_background_color = \033[101m
|
high_intensity_red_background_color = \033[101m
|
||||||
|
|
||||||
|
|
||||||
define msg
|
define msg
|
||||||
@echo -e "$(black_color)$(white_background_color) Info: $1 $(reset_color)"
|
@echo -e "$(black_color)$(white_background_color) Info: $1 $(reset_color)"
|
||||||
endef
|
endef
|
||||||
@@ -26,3 +25,27 @@ endef
|
|||||||
define copy_file
|
define copy_file
|
||||||
@cp -v $1 $2
|
@cp -v $1 $2
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
define delete
|
||||||
|
@rm -rv $1
|
||||||
|
endef
|
||||||
|
|
||||||
|
packagename = $(shell echo $(1) | tr '[:lower:]' '[:upper:]')
|
||||||
|
|
||||||
|
define download_package_source_archive
|
||||||
|
$(if \
|
||||||
|
$(wildcard $(TOPDIR)/dl/$(1)),
|
||||||
|
$(if \
|
||||||
|
$(wildcard $(TOPDIR)/dl/$(1)/$($(packagename)_SOURCE)), \
|
||||||
|
$(call msg,$(1) already exists), \
|
||||||
|
$(shell wget $($(packagename)_SITE)/$($(packagename)_SOURCE) -O $(TOPDIR)/dl/$(1)/$($(packagename)_SOURCE);) \
|
||||||
|
), \
|
||||||
|
$(shell mkdir -p $(TOPDIR)/dl/$(1);wget $($(packagename)_SITE)/$($(packagename)_SOURCE) -O $(TOPDIR)/dl/$(1)/$($(packagename)_SOURCE);) \
|
||||||
|
)
|
||||||
|
endef
|
||||||
|
|
||||||
|
define download
|
||||||
|
$(call download_package_source_archive,$(1))
|
||||||
|
endef
|
||||||
|
|
||||||
|
split- = $(word $2,$(subst -, ,$1))
|
||||||
|
|||||||
Reference in New Issue
Block a user