Curl library C language curl programming, curl Library

Source: Internet
Author: User

Curl library C language curl programming, curl Library

Curl programming in C Language

[Linux @ centos-64-min exercise] # gcc-Wall-o curltest. c
/Tmp/ccosVANi. o: In function 'main ':
Curltest. c :(. text + 0x2a): undefined reference to 'curl _ easy_init'
Curltest. c :(. text + 0x53): undefined reference to 'curl _ easy_setopt'
Curltest. c :(. text + 0x5c): undefined reference to 'curl _ easy_perform'
Curltest. c :(. text + 0x68): undefined reference to 'curl _ easy_cleanup'

Collect2: ld returned 1 exit status

Cause: the compiler cannot find the curl library file.

Solution: Determine the gcc-Wall-o curltest. c-l curl after the library is installed.

 

Install curl

1. Enter the directory of the compressed package

# Cd/root/soft

2. decompress the installation package

# Tar-zxf curl-7.42.1.tar.gz

3. Enter the decompressed installation package directory.

# Cdcurl-7.42.1

4. Configuration

#./Configure -- prefix =/usr/local/curl

5. Installation

# Make; make install

 

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.