Skip to content

libcurl compiled on OS X 10.11 fails to load on 10.8 (and earlier) #1330

@markovicpp

Description

@markovicpp

I did this

Compiled libcurl on OS X 10.11 with base SDK 10.11 and deployment target 10.8 but the product linking the libcurl stopped working in OS X 10.8 with following message:

Symbol not found: _connectx
Expected in: /usr/lib/libSystem.B.dylib

The problem can be backtraced to introduction of TCP Fast open on OS X.
Officially connectx() is introduced in Darwin 15.0.0 (OS X 10.11 / iOS 9.0).
It looks like the condition based on CONNECT_DATA_IDEMPOTENT value assumes that the library is never going to be used on system with lower version than the base SDK.

I expected the following

The product compiled with base SDK 10.11 and linked with libcurl will work on OS X 10.8 with proper use availability macros.

curl/libcurl version

curl 7.52.1 (x86_64-apple-darwin15.5) libcurl/7.52.1 SecureTransport zlib/1.2.8

operating system

OS X 10.8

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions