2010-09-02 Lucas De Marchi <lucas.demarchi@profusion.mobi>
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 3 Sep 2010 05:41:27 +0000 (05:41 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 3 Sep 2010 05:41:27 +0000 (05:41 +0000)
        Reviewed by Antonio Gomes.

        [EFL] Fix double addition of -fPIC
        https://bugs.webkit.org/show_bug.cgi?id=45122

         When SHARED_CORE=ON, -fPIC is automatically added because all
         libraries are dynamic. Only when static libraries are built that
         -fPIC needs to be manually inserted (because the final library,
         libewebkit.so, is dynamic).

        * cmake/OptionsCommon.cmake: Remove -fPIC flag.
        * cmake/WebKitHelpers.cmake: Add -fPIC flags iff SHARED_CORE=ON.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@66714 268f45cc-cd09-0410-ab3c-d52691b4dbfc

ChangeLog
cmake/OptionsCommon.cmake
cmake/WebKitHelpers.cmake

index c75cc87e770d4a605b962cde90105a599e6030f8..3af1bfc493058735ab38e1993dae653ed9dbbb03 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,18 @@
+2010-09-02  Lucas De Marchi  <lucas.demarchi@profusion.mobi>
+
+        Reviewed by Antonio Gomes.
+
+        [EFL] Fix double addition of -fPIC
+        https://bugs.webkit.org/show_bug.cgi?id=45122
+
+         When SHARED_CORE=ON, -fPIC is automatically added because all
+         libraries are dynamic. Only when static libraries are built that
+         -fPIC needs to be manually inserted (because the final library,
+         libewebkit.so, is dynamic).
+
+        * cmake/OptionsCommon.cmake: Remove -fPIC flag.
+        * cmake/WebKitHelpers.cmake: Add -fPIC flags iff SHARED_CORE=ON.
+
 2010-09-01  Ryuan Choi  <ryuan.choi@samsung.com>
 
         Reviewed by Antonio Gomes.
index 8b0b9c36a0a54bd3b09ade8f683a9009a784a653..32358165e80a0fec74f1e6fefbd4847e3a34c76d 100644 (file)
@@ -1,11 +1,6 @@
 ADD_DEFINITIONS(-DBUILDING_WITH_CMAKE=1)
 ADD_DEFINITIONS(-DHAVE_CONFIG_H=1)
 
-IF (CMAKE_COMPILER_IS_GNUCC)
-    SET(CMAKE_CXX_FLAGS "-fPIC ${CMAKE_CXX_FLAGS}")
-    SET(CMAKE_C_FLAGS "-fPIC ${CMAKE_C_FLAGS}")
-ENDIF ()
-
 SET(WTF_INCLUDE_DIRECTORIES
     "${JAVASCRIPTCORE_DIR}"
     "${JAVASCRIPTCORE_DIR}/wtf"
index 55549d6a30cda0a1c6ed8a703fd6f5cb0f9e9fa3..1e69d49082dbf26809f949b4e7ae98e799ee3cee 100644 (file)
@@ -19,7 +19,7 @@ MACRO(WEBKIT_SET_EXTRA_COMPILER_FLAGS _target)
             COMPILE_FLAGS "-fno-exceptions -fstrict-aliasing ${OLD_COMPILE_FLAGS}")
     ELSE ()
         SET_TARGET_PROPERTIES (${_target} PROPERTIES
-            COMPILE_FLAGS "-fno-exceptions -fstrict-aliasing -fvisibility=hidden ${OLD_COMPILE_FLAGS}")
+            COMPILE_FLAGS "-fPIC -fno-exceptions -fstrict-aliasing -fvisibility=hidden ${OLD_COMPILE_FLAGS}")
     ENDIF ()
     UNSET(OLD_COMPILE_FLAGS)
   ENDIF ()