除了要在 DEPENDS:=+libxxx以外,
可能还需要在下面的define Package/$(PKG_NAME)/install里面增加copy lib命令
一般都是在打包时候出现错误
define Package/$(PKG_NAME)
SECTION:=utils
CATEGORY:=Utilities
DEPENDS:=+libpthread +libmad +libmp3lame
TITLE:=hello --hello hello app
endef
define Package/$(PKG_NAME)/install
#$(INSTALL_DIR) $(1)/usr/sbin
#$(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_NAME) $(1)/usr/sbin
$(INSTALL_DIR) $(1)/tmp
$(CP) /home/hekaifeng/SDK/SDK_BASE/staging_dir/target-mips_34kc_uClibc-0.9.33.2/usr/lib/libmp3lame.* $(1)/tmp
$(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_NAME) $(1)/tmp
endef
还有问题:
上面的是对于libmp3lame而言的,虽然上面这样写了可以编译也通过,但是发现在安装时候出现错误,一直提示:
Downloading http://192.168.0.11/hello_1.0.0-1_ar71xx.ipk.
Installing hello (1.0.0-1) to root...
Collected errors:
* satisfy_dependencies_for: Cannot satisfy the following dependencies for hello:
* libmp3lame *
* opkg_install_cmd: Cannot install package hello.
所以直接把上面 +libmp3lame去掉了