[Cross compilation two] libcoap

 

libcoap is a lib library of the coap protocol, and the CoAP protocol is based on the REST framework. In order to overcome the disadvantages of HTTP for restricted environments, CoAP considers both the optimization of datagram length and the provision of reliable communication. On the one hand, CoAP provides URI, REST-style methods such as GET, POST, PUT, and DELETE, as well as scalability provided by independently defined header options. On the other hand, CoAP is based on the lightweight UDP protocol and allows IP multicast.

                                                     

The following is our process of compiling the Ingenic platform

1. Download address https://github.com/obgm/libcoap/tree/release-4.2.0

2. Compilation process:

(1) Enter the directory after decompression

(2) First execute autogen.sh -i

(3) We create an output directory ISVP_lib of include and lib, execute

./configure --prefix=$(pwd)/ISVP_lib --disable-dtls --disable-tests --disable-examples --disable-documentation --host=mips-linux-uclibc CC=/opt/mips-gcc472-glibc216-64bit/bin/mips-linux-uclibc-gnu-gcc CXX=/opt/mips-gcc472-glibc216-64bit/bin/mips-linux-uclibc-gnu-g++ --with-pic=noCFLAGS="-O3 -ffunction-sections -fdata-sections" LDFLAGS="-Wl,--gc-sections"

(4) Later we will see the configuration options

(5)make && make install

Guess you like

Origin blog.csdn.net/Swallow_he/article/details/110127148