Opened 9 years ago

Closed 9 years ago

#48780 closed defect (invalid)

cmake @3.3.1_0 requires newer cUrl version and crash

Reported by: alexandre@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 2.3.3
Keywords: Cc:
Port: cmake

Description (last modified by ryandesign (Ryan Carsten Schmidt))

cmake 3.3.1 requires libcurl that isn't available in macports (at least at this moment)

# cmake .

dyld: Library not loaded: /opt/local/lib/libcurl.4.dylib
  Referenced from: /opt/local/bin/cmake
  Reason: Incompatible library version: cmake requires version 9.0.0 or later, but libcurl.4.dylib provides version 8.0.0
make: *** [cmake_check_build_system] Trace/BPT trap: 5

Reverting to cmake 3.3.1 works fine.

cmake @3.3.1_0 (active)

Change History (4)

comment:1 in reply to:  description Changed 9 years ago by alexandre@…

Sorry I've made a typo in my bug report, the version that works fine is 3.3.0,

Reverting to cmake 3.3.0 works fine.

cmake @3.3.0_0 (active)

Replying to alexandre@…:

cmake 3.3.1 requires libcurl that isn't available in macports (at least at this moment)

# cmake .

dyld: Library not loaded: /opt/local/lib/libcurl.4.dylib
  Referenced from: /opt/local/bin/cmake
  Reason: Incompatible library version: cmake requires version 9.0.0 or later, but libcurl.4.dylib provides version 8.0.0
make: *** [cmake_check_build_system] Trace/BPT trap: 5

Reverting to cmake 3.3.1 works fine.

cmake @3.3.1_0 (active)
Last edited 9 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:2 Changed 9 years ago by mdeaudelin (Mathieu Deaudelin-Lemay)

I cannot reproduce this here... I have curl @7.44.0 and the version of libcurl.4.dylib is 9.0.0 :

otool -l /opt/local/lib/libcurl.4.dylib
Load command 3
          cmd LC_ID_DYLIB
      cmdsize 56
         name /opt/local/lib/libcurl.4.dylib (offset 24)
   time stamp 1 Wed Dec 31 19:00:01 1969
      current version 9.0.0
compatibility version 9.0.0

The prebuilt binary packages distributed by MacPorts are of the same version:

wget http://packages.macports.org/curl/curl-7.44.0_0+ssl.darwin_14.x86_64.tbz2
tar xvjf curl-7.44.0_0+ssl.darwin_14.x86_64.tbz2
otool -l opt/local/lib/libcurl.4.dylib
Load command 3
          cmd LC_ID_DYLIB
      cmdsize 56
         name /opt/local/lib/libcurl.4.dylib (offset 24)
   time stamp 1 Wed Dec 31 19:00:01 1969
      current version 9.0.0
compatibility version 9.0.0

I have no problems with cmake @3.3.1 either. I suggest that you verify whether your port "curl" is up-to-date:

port sync
port upgrade --force curl

If the problem persists, please tell us which version of the curl port is installed with:

port installed curl

comment:3 Changed 9 years ago by alexandre@…

Thanks for the quick reply,

I do have latest curl from ports,
/opt/local/lib/libcurl.4.dylib
which is indeed 9.0.0 (verified by otool)

That was very confusing but I've figured out what had happened here: some other software has set up:

 export DYLD_LIBRARY_PATH=/some/other/path

pointing to a directory with libcurl 7.42 (8.0.0) so when I was running cmake it was actually loading libcurl from that directory, however, the most confusing thing is that the error message was stating it was trying to load libcurl from /opt/local/lib/libcurl.4.dylib

dyld: Library not loaded: /opt/local/lib/libcurl.4.dylib
  Referenced from: /opt/local/bin/curl
  Reason: Incompatible library version: curl requires version 9.0.0 or later, but libcurl.4.dylib provides version 8.0.0

Sorry for have filed this ticket anyway,
Regards

Last edited 9 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:4 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)
Resolution: invalid
Status: newclosed

Yup, that's what happens when you set DYLD_LIBRARY_PATH, which is why you should probably not set DYLD_LIBRARY_PATH.

Has duplicate #48779.

P.S: Please use WikiFormatting when writing in Trac in the future, and preview before submitting.

Note: See TracTickets for help on using tickets.