Installing Libraries on 64 bit systems
John Hoare <[email protected]>
| Newsgroups | gmane.science.robotics.playerstage |
|---|---|
| Message-ID | <[email protected]> |
Hi, It's been discussed a bit before about where libraries exist on different systems. Some unixes have them in a lib64 directory and some have them in the lib directory (and 32 bit libs in lib32). Right now, as far as I can tell, it does not give you a choice when you're building player, the libraries have to go into lib64. The issue for me is, that lib64 is not in the system's library search path, so when I compile player, and link against player, when I try to run any libraries linked against player's I get a library not found error. My solution to this was to just expose the PLAYER_LIBRARY_INSTALL_DIR CMake variable so that you can change lib64 to lib if you so desire. Is there a better way to do this, or is this the way it should be done. I've attached what I've done as a patch (it's quite simple) if anyone is interested. I apologize if this specific topic has been discussed before, I searched for a bit and couldn't find anything, only the discussion about multilib linux (Player SVN trunk: Problem with playerc++ on multilib Linux/x86_64) Thanks, John Hoare ------------------------------------------------------------------------------ This SF.net email is sponsored by Sprint What will you do first with EVO, the first 4G phone? Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first _______________________________________________ Playerstage-developers mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/playerstage-developers
player-cmake-libinstall.diff
(text/x-patch, 825 B)
Index: cmake/internal/SetupDirectories.cmake
===================================================================
--- cmake/internal/SetupDirectories.cmake (revision 8808)
+++ cmake/internal/SetupDirectories.cmake (working copy)
@@ -12,10 +12,10 @@
SET (PLAYER_INCLUDE_INSTALL_DIR "include/${projectNameLower}-${PLAYER_MAJOR_VERSION}.${PLAYER_MINOR_VERSION}")
IF (PLAYER_PROC_64BIT)
- SET (PLAYER_LIBRARY_INSTALL_DIR "lib64")
+ SET (PLAYER_LIBRARY_INSTALL_DIR "lib64" CACHE STRING "Player library install folder")
MESSAGE (STATUS "Player libraries will be in lib64")
ELSE (PLAYER_PROC_64BIT)
- SET (PLAYER_LIBRARY_INSTALL_DIR "lib")
+ SET (PLAYER_LIBRARY_INSTALL_DIR "lib" CACHE STRING "Player library install folder")
MESSAGE (STATUS "Player libraries will be in lib")
ENDIF (PLAYER_PROC_64BIT)