Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Robert_Bell
Beginner
165 Views

IPP 7.0 Mac OS X rebinding dylibs.

Hi all,
This has been an issue for us for a while, and methods to fix the issue seem to have varied. I have posted a number of times on the subject myself. The issue is that for many applications in the Mac OS X environment, it is not easy to set the dynamic library path. For example, it used to be possible to set the environment variables using ~/.MacOS/environment.plist, or in the package plist of the application itself; both of these have been switched off for security reasons in recent versions of Mac OS X.In at least some versions of IPP, we were able to rebind the install locations of the libraries using install_name_tool. For example:
otool -L libippcore-7.0.dylib
libippcore-7.0.dylib:
libippcore-7.0.dylib (compatibility version 7.0.0, current version 7.0.0)
libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.3)
libippcore-7.0.dylib: libippcore-7.0.dylib (compatibility version 7.0.0, current version 7.0.0) libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0) /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.3)
Then:
install_name_tool -change libiomp5.dylib /Library/Frameworks/Intel_IPP.framework/Libraries/libiomp5.dylib libippcore-7.0.dylib
For at least the recent revisions of IPP, including IPP 7.0, running install_name_tool as above gives the following (or similar) error:
install_name_tool: for architecture i386 object: libippcore-7.0.dylib malformed object (section contents at offset 0 with a size of 172, overlaps Mach-O headers at offset 0 with a size of 1336)
I noticed that the rebind scripts (which attempted to do much the same) seem to pop on and off the radar depending on the version, and I cannot find them in the IPP 7.0 for the Mac.
Since this is an issue that many have posted on for years, I imagine that we are doing something wrong. What exactly should we be doing? Being able to rebind the libraries used to work flawlessly for us, and so it has been a disappointment to see the above error pop up. At least one poster has reported this error before, and the reply was that it would be fixed in IPP 7.0, but clearly that does not seem to be the case.
Thanks in advance for any advice.
Best,
Robert.
0 Kudos
11 Replies
Chao_Y_Intel
Employee
165 Views

Robert,

thanks for your report. We will check this problem.

Chao

Robert_Bell
Beginner
165 Views

Hi Chao,
Here is some more history on this:
One of my original posts regarding library location:


And a report where this new error was indicated would be fixed in IPP 7.0. (the post by Pavel indicates that it could be fixed)

Best,

Robert.
Robert_Bell
Beginner
165 Views

Hi Chao,
Note that I can do this on Mac OS 10.5 with Xcode version 3.1.3. I am testing doing this, then moving the libraries back to 10.6 at the moment. I have not tested with all version of 10.6, or all versions of Xcode for 10.6, but at least this seems to be related in some way to the different versions of Xcode, OS, or install_name_tool.
Thanks,
Robert.
Robert_Bell
Beginner
165 Views

Another update ...
So, I can use install_name_tool successfully onMac OS 10.5 with Xcode version 3.1.3, and then transfer the libraries back to 10.6 machine from whence they came. Not ideal, but it works.
Thanks,
Robert.
Pavel_B_Intel1
Employee
165 Views

Hello Robert!

I've tried to reproduce your problem and all ok on my MacOS X 10.6.1 systemwith IPP 7.0 gold update1 and update2:

$ otool -L libippcore-7.0.dylib
libippcore-7.0.dylib:
libippcore-7.0.dylib (compatibility version 7.0.0, current version 7.0.0)
libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.1)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
$
$
$ install_name_tool -change libiomp5.dylib /Library/Frameworks/Intel_IPP.framework/Libraries/libiomp5.dylib libippcore-7.0.dylib
$
$ otool -L libippcore-7.0.dylib
libippcore-7.0.dylib:
libippcore-7.0.dylib (compatibility version 7.0.0, current version 7.0.0)
/Library/Frameworks/Intel_IPP.framework/Libraries/libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.1)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
$
$ libtool -V
Apple Computer, Inc. version cctools-750
$
$ sw_vers
ProductName: Mac OS X
ProductVersion: 10.6.1
$

Please compare your version of cctools with mine and could you give me your version of cctools?
Once I've met the problem with cctools and upgrading them helps me.

Pavel

Pavel_B_Intel1
Employee
165 Views

Hello Robert!
I've tried to reproduce your issue on my MacOS X 10.6.1 with XCode 3.2 and all ok for IPP 7.0 update1 and update2:

$ otool -L libippcore-7.0.dylib
libippcore-7.0.dylib:
libippcore-7.0.dylib (compatibility version 7.0.0, current version 7.0.0)
libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.1)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
$
$ install_name_tool -change libiomp5.dylib /Library/Frameworks/Intel_IPP.framework/Libraries/libiomp5.dylib libippcore-7.0.dylib
$
$ otool -L libippcore-7.0.dylib
libippcore-7.0.dylib:
libippcore-7.0.dylib (compatibility version 7.0.0, current version 7.0.0)
/Library/Frameworks/Intel_IPP.framework/Libraries/libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.1)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
$
$ libtool -V
Apple Computer, Inc. version cctools-750
$
$ sw_vers
ProductName: Mac OS X
ProductVersion: 10.6.1
$

What is your version of cctools? Once I've meta problem with cctools and upgrating them helps me.

Pavel

Robert_Bell
Beginner
165 Views

Here is the information:

Last login: Mon Mar 7 16:29:37 on ttys004
rbell:~ bertie$ libtool -V
Apple Computer, Inc. version cctools-782

ProductName: Mac OS X
ProductVersion: 10.6.6
BuildVersion: 10J567

Also, my Xcode versions is:

Version 3.2.3

64-bit

Component versions
Xcode IDE: 1688.0
Xcode Core: 1691.0
ToolSupport: 1591.0
Robert_Bell
Beginner
165 Views

Hi Pavel,

Just to make sure, I ran the same attemp again since I have probably updated my machine since the post. I usually keep my machines quite up to date. Here is the latest output:

Last login: Tue Mar 8 05:11:21 on ttys005
rbell:~ bertie$ mkdir ipp_test
rbell:~ bertie$ cd ipp_test/
rbell:ipp_test bertie$ ls -la
total 0
drwxr-xr-x 2 bertie staff 68 Mar 8 05:17 .
drwxr-xr-x+ 71 bertie staff 2414 Mar 8 05:17 ..
rbell:ipp_test bertie$ cp /opt/intel/ipp/lib/libippcore-7.0.dylib .
rbell:ipp_test bertie$ ls -la
total 208
drwxr-xr-x 3 bertie staff 102 Mar 8 05:18 .
drwxr-xr-x+ 71 bertie staff 2414 Mar 8 05:17 ..
-rwxr-xr-x 1 bertie staff 105096 Mar 8 05:18 libippcore-7.0.dylib
rbell:ipp_test bertie$ otool -L libippcore-7.0.dylib
libippcore-7.0.dylib:
libippcore-7.0.dylib (compatibility version 7.0.0, current version 7.0.0)
libiomp5.dylib (compatibility version 5.0.0, current version 5.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.3)
rbell:ipp_test bertie$ install_name_tool -change libiomp5.dylib /Library/Frameworks/Intel_IPP.framework/Libraries/libiomp5.dylib libippcore-7.0.dylib
install_name_tool: for architecture i386 object: libippcore-7.0.dylib malformed object (section contents at offset 0 with a size of 172, overlaps Mach-O headers at offset 0 with a size of 1336)
rbell:ipp_test bertie$
Pavel_B_Intel1
Employee
165 Views

Hi Robert,

I'm going to investigate it for several days, please wait a little

Pavel
Pavel_B_Intel1
Employee
165 Views

Hi Robert,

thanks for waiting. I've found a problem in IPP. I'll try to fix it in IPP 7.0 update4.

Thanks for your report, Pavel
Pavel_B_Intel1
Employee
165 Views

Hi Robert,
I found the root of case it will be fixed in IPP 7.0.4 gold

Best regarg, Pavel
Reply