Centos make install package installation case

Source: Internet
Author: User

Centos make install package installation case
Prepare the written c file

1. ws. h [header file, declare function name, not implemented] 2. wso. c [contains the function body. To implement the function, you need to compile it into a dynamic link library.] 3. ws. h [main program execution file]
Create makefile
Toucu makefile create makefile vi makefile edit makefile,
Code that can be executed by the make command in makefile
Newws: ws. c libme. so gcc-L. /-l me ws. c-o newwslibme. so: ws. c gcc-shared wso. c-o libme. soinstall: cp. /libme. so/lib64 ldconfig

Command Parsing: 1. The final file newws in makefile format depends on shenyi. c libme. so 2. gcc command to generate the compilation file-L. /current directory-l mewso. c generates the final newws 3 and libme. so depends on ws. c 4. Generate the compilation file. so command (ws. c is changed to libme. so) 5. install make install

5.1 merge the compiled files into the core library 5.2 and update the cache

Related Article

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.