Hello, on unix* hugin stores functions used by multiple executables in private shared libs. This is done to minimize the size of executables.
However afaict these libraries are not supposed to be used by programs outside hugin. Nobody seems to be responsible for defining and monitoring a public interface. The libraries are not versioned. Stuff should just work for hugin. This is not to be read as criticism, I am just trying to provide a rationale why I think the libraries are private. Anyway, how about making this fact [1] a little bit more official by moving the libs to a private subdirectory ($libdir/hugin) and using rpath? Suggested patch attached. cu andreas [1] "If you use these shared libraries in your external program you may keep both pieces when it breakes. Recompilation after every new hugin release will probably be necessary. The API and ABI may change without notice in an incompatible way (symbols removed, size of struct changed, etc.) from one release to the next." -- `What a good friend you are to him, Dr. Maturin. His other friends are so grateful to you.' `I sew his ears on from time to time, sure' -- You received this message because you are subscribed to the Google Groups "Hugin and other free panoramic software" group. A list of frequently asked questions is available at: http://wiki.panotools.org/Hugin_FAQ To post to this group, send email to hugin-ptx@googlegroups.com To unsubscribe from this group, send email to hugin-ptx+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/hugin-ptx
Install hugin shared libraries in a private subdirectory of $libdir and use rpath to let the dynamic linker locate them. --- hugin-2010.2.0+dfsg~rc2.orig/CMakeLists.txt +++ hugin-2010.2.0+dfsg~rc2/CMakeLists.txt @@ -350,6 +350,7 @@ IF (UNIX) SET(HUGIN_SHARED_LIBS 1) ENDIF (${HUGIN_SHARED}) MESSAGE("-- Using shared internal libraries") + SET(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/${LIBDIR}/hugin") ELSE (UNIX) IF (${HUGIN_SHARED}) --- hugin-2010.2.0+dfsg~rc2.orig/src/foreign/ANN/CMakeLists.txt +++ hugin-2010.2.0+dfsg~rc2/src/foreign/ANN/CMakeLists.txt @@ -15,7 +15,7 @@ IF (${HUGIN_SHARED_LIBS}) IF(WIN32) install(TARGETS huginANN RUNTIME DESTINATION ${BINDIR}) ELSE(WIN32) - install(TARGETS huginANN DESTINATION ${LIBDIR}) + install(TARGETS huginANN DESTINATION ${LIBDIR}/hugin) ENDIF(WIN32) ELSE (${HUGIN_SHARED_LIBS}) add_library(huginANN STATIC ${ANN_SRC} ${ANN_HEADERS}) --- hugin-2010.2.0+dfsg~rc2.orig/src/foreign/vigra/vigra_impex/CMakeLists.txt +++ hugin-2010.2.0+dfsg~rc2/src/foreign/vigra/vigra_impex/CMakeLists.txt @@ -11,7 +11,7 @@ IF (${HUGIN_SHARED_LIBS}) IF(WIN32) install(TARGETS huginvigraimpex RUNTIME DESTINATION ${BINDIR}) ELSE(WIN32) - install(TARGETS huginvigraimpex DESTINATION ${LIBDIR}) + install(TARGETS huginvigraimpex DESTINATION ${LIBDIR}/hugin) ENDIF(WIN32) ELSE (${HUGIN_SHARED_LIBS}) add_library(huginvigraimpex STATIC ${VIGRA_IMPEX_SRC} ${VIGRA_IMPEX_HEADER}) --- hugin-2010.2.0+dfsg~rc2.orig/src/celeste/CMakeLists.txt +++ hugin-2010.2.0+dfsg~rc2/src/celeste/CMakeLists.txt @@ -59,7 +59,7 @@ IF (${HUGIN_SHARED_LIBS}) IF(WIN32) install(TARGETS celeste RUNTIME DESTINATION ${BINDIR}) ELSE(WIN32) - install(TARGETS celeste DESTINATION ${LIBDIR}) + install(TARGETS celeste DESTINATION ${LIBDIR}/hugin) ENDIF(WIN32) ELSE (${HUGIN_SHARED_LIBS}) # messages are quite obtrusive in windows cmakesetup.exe --- hugin-2010.2.0+dfsg~rc2.orig/src/hugin1/base_wx/CMakeLists.txt +++ hugin-2010.2.0+dfsg~rc2/src/hugin1/base_wx/CMakeLists.txt @@ -14,7 +14,7 @@ IF (${HUGIN_SHARED_LIBS}) IF(WIN32) install(TARGETS huginbasewx RUNTIME DESTINATION ${BINDIR}) ELSE(WIN32) - install(TARGETS huginbasewx DESTINATION ${LIBDIR}) + install(TARGETS huginbasewx DESTINATION ${LIBDIR}/hugin) ENDIF(WIN32) ELSE (${HUGIN_SHARED_LIBS}) add_library(huginbasewx STATIC ${HUGIN_WX_BASE_SRC} ${HUGIN_WX_BASE_HEADER}) --- hugin-2010.2.0+dfsg~rc2.orig/src/hugin_base/CMakeLists.txt +++ hugin-2010.2.0+dfsg~rc2/src/hugin_base/CMakeLists.txt @@ -134,7 +134,7 @@ IF (${HUGIN_SHARED_LIBS}) IF(WIN32) install(TARGETS huginbase RUNTIME DESTINATION ${BINDIR}) ELSE(WIN32) - install(TARGETS huginbase DESTINATION ${LIBDIR}) + install(TARGETS huginbase DESTINATION ${LIBDIR}/hugin) ENDIF(WIN32) ELSE (${HUGIN_SHARED_LIBS}) add_library(huginbase STATIC ${HUGIN_BASE_SRC} ${HUGIN_BASE_HEADER})