Openwrt dependency cannot be found

Source: Internet
Author: User

Openwrt report library not found
Package * is missing dependencies for the following libraries:
Libc. so.6 or others
First check whether there is any inventory in the system. If not, install it (in/lib/lib64 and other directories)
Then add the compiling environment of the library openwrt.
Different libc. Provides platforms may have different directories. Find./stagging_dir-name libc. Provides
Generally in stagging_dir/target-mipsel_r2_uClibc-0.9.33.2/pkginfo/libc. Provides
Add at the bottom
Libc. so.6
Or other required libraries, so will be converted into the library of the openwrt platform during compilation.
Finally, add the dependency in the makefile of the corresponding openwrt.

If not, use

Added in define package/SC/install

$ (CP)/Your Lib. So $ (1)/usr/bin/

Or...

Makefile example of openwrt

Include $ (topdir)/rules. mkinclude $ (include_dir)/kernel. MK # Your package name pkg_name: = scpkg_release: = 1pkg_build_dir: = $ (build_dir)/$ (pkg_name) include $ (include_dir)/package. MK # package information define package/SC # The following two classification sections used in the compilation interface during compilation: = utils category: = utilities title: = certain information SC customer # dependent database depends: = + libpthread + libpcap endefdefine package/SC/description # package introduction if you can't figure out what this program does, you're probably brain-dead and need immediate medical attention. endefdefine build/prepare mkdir-p $ (pkg_build_dir) $ (CP ). /src/* $ (pkg_build_dir)/endef # package installation run define package/SC/install $ (install_dir) $ (1)/usr/bin $ (install_bin) $ (pkg_build_dir) /SC $ (1)/usr/bin/endef $ (eval $ (call buildpackage, SC ))

Generally, the written code is stored in/Your openwrt source/package /.

Create a directory, such as SC. The directory structure is as follows:

Package/SC

Package/SC/makefile (the file above)

Package/SC/src/Your. c

Package/SC/src/makefile

Package/SC/src/... # other files

Run sudo make menuconfig to find the definition of section and category in define package/SC.

Note: In your makefile, do not use GCC to use $ (CC); otherwise, it cannot be compiled ..

Makefile example:

SC: SC. o $ (CC) SC. o-o SC-lpthread-lpcapsc. o: SC. c SC. h $ (CC)-c SC. cclean: Rm-RF *. O SC

The front is tab subtraction, and non-space... $ (CC) must not be replaced by GCC...

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.