diff options
author | Aleric Inglewood <Aleric.Inglewood@gmail.com> | 2010-12-15 21:23:03 +0100 |
---|---|---|
committer | Aleric Inglewood <Aleric.Inglewood@gmail.com> | 2010-12-15 21:23:03 +0100 |
commit | 5936ced3119b44fab35a6af29339e54feb08e8ff (patch) | |
tree | 2c6a2f1ce63d650b4458547f03585d4e2ebb98bd /indra | |
parent | d0a25a41848142e469f5d64f4e4cef3852d3b2ab (diff) |
SNOW-240: Fix libjson naming madness, again, for standalone.
SNOW-240 was actually about adding the whole search.
While this has been done, there is one issue left:
On linux (and remember, all of this is about standalone)
the libjson packages of distributions don't have this
complex compiler version baked into their name.
See also the last comment on SNOW-240:
https://jira.secondlife.com/browse/SNOW-240?focusedCommentId=205305&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-205305
This patch fixes this issue by first searching for
libjson_linux-gcc-${_gcc_COMPILER_VERSION}_libmt.so
and when that fails search for the system package
library file libjson.so.
Diffstat (limited to 'indra')
-rw-r--r-- | indra/cmake/FindJsonCpp.cmake | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/indra/cmake/FindJsonCpp.cmake b/indra/cmake/FindJsonCpp.cmake index 9d16f2aaab..cf84b309c1 100644 --- a/indra/cmake/FindJsonCpp.cmake +++ b/indra/cmake/FindJsonCpp.cmake @@ -21,7 +21,12 @@ EXEC_PROGRAM(${CMAKE_CXX_COMPILER} OUTPUT_STRIP_TRAILING_WHITESPACE ) +# Try to find a library that was compiled with the same compiler version as we currently use. SET(JSONCPP_NAMES ${JSONCPP_NAMES} libjson_linux-gcc-${_gcc_COMPILER_VERSION}_libmt.so) +IF (STANDALONE) + # On standalone, assume that the system installed library was compiled with the used compiler. + SET(JSONCPP_NAMES ${JSONCPP_NAMES} libjson.so) +ENDIF (STANDALONE) FIND_LIBRARY(JSONCPP_LIBRARY NAMES ${JSONCPP_NAMES} PATHS /usr/lib /usr/local/lib |