diff options
author | Jim Huang <jserv@0xlab.org> | 2011-11-05 02:24:39 +0800 |
---|---|---|
committer | Peng Wu <alexepico@gmail.com> | 2011-11-08 11:17:20 +0800 |
commit | 0aee1fa97acab18ce41fd2e03851624f79f6657b (patch) | |
tree | 6ccbbcaca081cfc6117c1632168a3e75979122e2 | |
parent | f867fe3f4b877adf376516013bddbc3803c8de2a (diff) | |
download | libpinyin-0aee1fa97acab18ce41fd2e03851624f79f6657b.tar.gz libpinyin-0aee1fa97acab18ce41fd2e03851624f79f6657b.tar.xz libpinyin-0aee1fa97acab18ce41fd2e03851624f79f6657b.zip |
CMake: add -fPIC flag to combine static libraries to dynamic one0.2.99.4
Machines running Linux on architectures such as amd64 require flag
"-fPIC" to be specified to compile shared libraries, and it would
be helpful to have this a default for CMake when building libpinyin.
-rw-r--r-- | src/lookup/CMakeLists.txt | 4 | ||||
-rw-r--r-- | src/storage/CMakeLists.txt | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/src/lookup/CMakeLists.txt b/src/lookup/CMakeLists.txt index bb5b8ba..bd29b4a 100644 --- a/src/lookup/CMakeLists.txt +++ b/src/lookup/CMakeLists.txt @@ -1,4 +1,8 @@ set( + CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC" +) + +set( LIBLOOKUP_HEADERS lookup.h pinyin_lookup.h diff --git a/src/storage/CMakeLists.txt b/src/storage/CMakeLists.txt index b775350..59f6bfd 100644 --- a/src/storage/CMakeLists.txt +++ b/src/storage/CMakeLists.txt @@ -1,4 +1,8 @@ set( + CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC" +) + +set( LIBSTORAGE_HEADERS pinyin_large_table.h pinyin_base.h |