Skip to content

Commit

Permalink
Fix a linker error when compiling OpenEXR statically on Linux
Browse files Browse the repository at this point in the history
Linking OpenEXR and IlmBase statically on Linux failed due to
interdependencies between Iex and IlmThread. Simply reversing their
order in CMakeLists.txt fixes the issue (which only arises on Linux
since the GNU linker is particularly sensitive to the order of static
libraries)
  • Loading branch information
Wenzel Jakob committed Feb 2, 2015
1 parent 9101514 commit caa09c1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions OpenEXR/IlmImf/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ ADD_EXECUTABLE ( b44ExpLogTable

TARGET_LINK_LIBRARIES ( b44ExpLogTable
Half
Iex${ILMBASE_LIBSUFFIX}
IlmThread${ILMBASE_LIBSUFFIX}
Iex${ILMBASE_LIBSUFFIX}
${PTHREAD_LIB}
)

Expand All @@ -25,8 +25,8 @@ ADD_EXECUTABLE ( dwaLookups

TARGET_LINK_LIBRARIES ( dwaLookups
Half
Iex${ILMBASE_LIBSUFFIX}
IlmThread${ILMBASE_LIBSUFFIX}
Iex${ILMBASE_LIBSUFFIX}
${PTHREAD_LIB}
)

Expand Down

0 comments on commit caa09c1

Please sign in to comment.