Modify Makefile of easy-soc-libs to add libdsl test application

This commit is contained in:
Yalu Zhang 2019-01-24 14:07:27 +01:00
parent af11c1b407
commit b480ca039c
2 changed files with 14 additions and 0 deletions

View file

@ -15,5 +15,9 @@ config LIBDSL_DEBUG
bool "Enable xdsl debugging"
default n
config LIBDSL_TEST
depends on PACKAGE_libdsl
bool "Libdsl test program"
default n
endmenu
endif

View file

@ -118,6 +118,12 @@ define Build/InstallDev/libethernet
$(CP) $(PKG_BUILD_DIR)/libethernet/libethernet.so $(1)/usr/lib/
endef
define Build/Compile
$(call Build/Compile/Default)
ifeq ($(CONFIG_LIBDSL_TEST),y)
$(MAKE) -C "$(PKG_BUILD_DIR)/libdsl/test" $(MAKE_FLAGS)
endif
endef
define Build/InstallDev
$(foreach dir,$(subdirs),$(call Build/InstallDev/$(dir),$(1),$(2));)
@ -135,7 +141,11 @@ endef
define Package/libdsl/install
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_DIR) $(1)/usr/bin
$(CP) $(PKG_BUILD_DIR)/libdsl/libdsl.so* $(1)/usr/lib/
ifeq ($(CONFIG_LIBDSL_TEST),y)
$(CP) $(PKG_BUILD_DIR)/libdsl/test/libdsl_test $(1)/usr/bin/
endif
endef
$(eval $(call BuildPackage,libwifi))