Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6474073
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T06:32:36+00:00 2026-05-25T06:32:36+00:00

I am using Libcurl in my application with C and GNU compiler on a

  • 0

I am using Libcurl in my application with C and GNU compiler on a linux machine.
Application also uses OpenSSL libraries and some other libraries. I am trying to statically link the libraries, except for lcurl linking with other libraries works fine.

I am trying to compile as below.

gcc -static -I. -o test test.c -lz -lssl -lcrypto -lcurl

Am I doing anything wrong?
Is there a way to force static linking of some librairies (libc for exemple) ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T06:32:37+00:00Added an answer on May 25, 2026 at 6:32 am

    Libcurl is itself linked against a ton of other libraries, most of which aren’t included in your compile command line. For instance, mine (on Debian Squeeze) links against:

    • libc
    • libcom_err
    • libcrypto
    • libdl
    • libgcrypt
    • libgnutls
    • libgpg-error
    • libgssapi_krb5
    • libidn
    • libk5crypto
    • libkeyutils
    • libkrb5
    • libkrb5support
    • liblber-2.4
    • libldap_r-2.4
    • libpthread
    • libresolv
    • librt
    • libsasl2
    • libssh2
    • libssl
    • libtasn1
    • libz

    (You can get a similar list for yourself by running ldd on the library on Linux, or otool -L on Darwin.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using libcurl in a Win32 C++ application. I have the curllib.vcproj project added
I'm writing an application, and I'm currently using libcurl. The libcurl callback function works
Using C# .NET 3.5 and WCF, I'm trying to write out some of the
I'm trying to PUT data using libcurl to mimic the command curl -u test:test
I am making a c++ (windows devc++) application which downloads a file using libcurl.
I am trying to do a simple post using libcURL. I noticed that if
Is there any other variants to send http/https request from C/C++ except using libCurl?
I'm writing a mule application that implements some web services using Jersey. I'd like
Our application uses libcurl for HTTP, and we want to get access to Internet
I have a C application that uses LibCurl (LibCurl is a C API that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.