zeus2615 / libgooglepinyin

Automatically exported from code.google.com/p/libgooglepinyin
0 stars 0 forks source link

Make it easy to install in 64bit systems #7

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
When I install it in my slackware64 box, it complained about could not find 
libgooglepinyin.so on start up. Installing the lib into /usr/lib64 will fix it.

Here is the patch:
================================
diff -r 94bdf5d6af9a CMakeLists.txt                                             

--- a/CMakeLists.txt    Sat Sep 03 09:27:43 2011 +0000
+++ b/CMakeLists.txt    Sat Sep 03 23:09:00 2011 +0800
@@ -19,6 +19,9 @@
 if(NOT DEFINED LIB_INSTALL_DIR)
     set(LIB_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib)
 endif()
+if(DEFINED LIB_SUFFIX)
+    set(LIB_INSTALL_DIR ${LIB_INSTALL_DIR}${LIB_SUFFIX})
+endif()

 set(prefix      ${CMAKE_INSTALL_PREFIX})
 set(exec_prefix ${CMAKE_INSTALL_PREFIX})
=======================================

On 64bit system, one can build it with the -DLIB_SUFFIX=64 option, which is 
standard as least in Slackware.

Besides, it seems there are two set(libdir ${LIB_INSTALL_DIR}) in 
CMakeList.txt. You may only need one.

Original issue reported on code.google.com by chaos.pr...@gmail.com on 3 Sep 2011 at 3:13

GoogleCodeExporter commented 9 years ago
you should use -DLIB_INSTALL_DIR=/usr/lib64

Original comment by wen...@gmail.com on 3 Sep 2011 at 5:28