[Groonga-commit] groonga/groonga-normalizer-mysql at dd332c4 [master] cmake: add workaround for old CMake

Back to archive index

Kouhei Sutou null+****@clear*****
Wed May 6 19:35:56 JST 2015


Kouhei Sutou	2015-05-06 19:35:56 +0900 (Wed, 06 May 2015)

  New Revision: dd332c48ea2ee3b34ae402fe6bcc04ca306cecfd
  https://github.com/groonga/groonga-normalizer-mysql/commit/dd332c48ea2ee3b34ae402fe6bcc04ca306cecfd

  Message:
    cmake: add workaround for old CMake

  Modified files:
    normalizers/CMakeLists.txt

  Modified: normalizers/CMakeLists.txt (+8 -0)
===================================================================
--- normalizers/CMakeLists.txt    2015-04-28 18:53:51 +0900 (8d79558)
+++ normalizers/CMakeLists.txt    2015-05-06 19:35:56 +0900 (bddda0a)
@@ -25,6 +25,14 @@ if(GROONGA_NORMALIZER_MYSQL_EMBED)
     mysql_normalizer
     PROPERTIES
     POSITION_INDEPENDENT_CODE ON)
+  if(NOT DEFINED CMAKE_C_COMPILE_OPTIONS_PIC)
+    # For old CMake
+    if(CMAKE_COMPILER_IS_GNUCXX)
+      set_source_files_properties(${MYSQL_SOURCES}
+	PROPERTIES
+	COMPILE_FLAGS "-fPIC")
+    endif()
+  endif()
 else()
   add_library(mysql_normalizer MODULE ${MYSQL_SOURCES})
   set_target_properties(mysql_normalizer PROPERTIES
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index