Switch USE(ICONDATABASE) to ENABLE(ICONDATABASE)
authorstaikos <staikos@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 6 Jul 2007 05:12:47 +0000 (05:12 +0000)
committerstaikos <staikos@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 6 Jul 2007 05:12:47 +0000 (05:12 +0000)
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@24042 268f45cc-cd09-0410-ab3c-d52691b4dbfc

JavaScriptCore/ChangeLog
JavaScriptCore/wtf/Platform.h
WebCore/ChangeLog
WebCore/WebCore.pro
WebCore/loader/icon/IconDatabase.h

index 433d89d851ceea8bd625250294a3350310620e07..4272f0c4b860313045d0de9131e76c3907b5b150 100644 (file)
@@ -1,3 +1,11 @@
+2007-07-06  George Staikos  <staikos@kde.org>
+
+        Reviewed by Maciej.
+
+        Switch USE(ICONDATABASE) to ENABLE(ICONDATABASE)
+
+        * wtf/Platform.h:
+
 2007-07-03  Sam Weinig  <sam@webkit.org>
 
         Reviewed by Darin.
index 29569157db457eca9fb55f038c82760810b858f8..775f0b1326b53c49bde04bf161ce7c5665844079 100644 (file)
 #define USE_SYSTEM_MALLOC 1
 #endif
 
-#define WTF_USE_ICONDATABASE 1
+#if !defined(ENABLE_ICONDATABASE)
+#define ENABLE_ICONDATABASE 1
+#endif
 
 #endif /* WTF_Platform_h */
index 9fe00b7cc755ddeff3f5421eea4011f8ed866457..c17dce27caf8ee87e7f5561a3192c47801e0a865 100644 (file)
@@ -1,3 +1,13 @@
+2007-07-06  George Staikos  <staikos@kde.org>
+
+        Reviewed by Maciej.
+
+        Switch USE(ICONDATABASE) to ENABLE(ICONDATABASE) and activate the
+        flag via the .pro file
+
+        * WebCore.pro:
+        * loader/icon/IconDatabase.h:
+
 2007-07-05  John Sullivan  <sullivan@apple.com>
 
         Reviewed by Adam
index 7a8149434d174037ce24e6e8d769f19813d32a1b..fe59489521fef0473413b313495e6bd0b2595c18 100644 (file)
@@ -36,6 +36,7 @@ freebsd-*: DEFINES += HAVE_PTHREAD_NP_H
 DEFINES += BUILD_WEBKIT
 
 # Optional components (look for defs in config.h and included files!)
+DEFINES += ENABLE_ICONDATABASE=1
 DEFINES += ENABLE_XPATH=1
 DEFINES += ENABLE_XSLT=1
 #DEFINES += ENABLE_XBL=1
@@ -59,7 +60,6 @@ LIBS += -L$$OUTPUT_DIR/WebKitQt/Plugins
 LIBS += -lqtwebico
 
 INCLUDEPATH += \
-                $$[QT_INSTALL_PREFIX]/src/3rdparty/sqlite/ \
                 $$PWD/platform/qt \
                 $$PWD/platform/network/qt \
                 $$PWD/platform/graphics/qt \
@@ -117,8 +117,6 @@ INCLUDEPATH +=  $$PWD \
                 $$PWD/platform/image-decoders \
                 $$PWD/../WebKitQt/WebCoreSupport
 QT += network
-LIBS += -lsqlite3
-
 
 FEATURE_DEFINES_JAVASCRIPT = LANGUAGE_JAVASCRIPT
 
@@ -554,12 +552,7 @@ SOURCES += \
     loader/DocumentLoader.cpp \
     loader/FormState.cpp \
     loader/FrameLoader.cpp \
-    loader/icon/IconDatabase.cpp \
-    loader/icon/IconDataCache.cpp \
     loader/icon/IconLoader.cpp \
-    loader/icon/SQLDatabase.cpp \
-    loader/icon/SQLStatement.cpp \
-    loader/icon/SQLTransaction.cpp \
     loader/ImageDocument.cpp \
     loader/loader.cpp \
     loader/MainResourceLoader.cpp \
@@ -869,6 +862,19 @@ gdk-port:SOURCES += \
         platform/image-decoders/ico/ICOImageDecoder.cpp \
         platform/image-decoders/xbm/XBMImageDecoder.cpp
  
+contains(DEFINES, ENABLE_ICONDATABASE=1) {
+    qt-port: INCLUDEPATH += $$[QT_INSTALL_PREFIX]/src/3rdparty/sqlite/
+    LIBS += -lsqlite3
+    SOURCES += \
+        loader/icon/IconDatabase.cpp \
+        loader/icon/IconDataCache.cpp \
+        loader/icon/SQLDatabase.cpp \
+        loader/icon/SQLStatement.cpp \
+        loader/icon/SQLTransaction.cpp
+} else {
+    SOURCES += \
+        loader/icon/IconDatabaseNone.cpp
+}
 
 contains(DEFINES, ENABLE_XPATH=1) {
     FEATURE_DEFINES_JAVASCRIPT += ENABLE_XPATH
index 3e0d46bdc0c7cc3a1ff256584cff8151091d027e..49fcff079d37fc3c1d708382f848a256aced7fec 100644 (file)
@@ -26,7 +26,7 @@
 #ifndef IconDatabase_h
 #define IconDatabase_h
 
-#if USE(ICONDATABASE)
+#if ENABLE(ICONDATABASE)
 #include "SQLDatabase.h"
 #endif
 
@@ -43,7 +43,7 @@ class IntSize;
 class IconDataCache;
 class SharedBuffer;
 
-#if USE(ICONDATABASE)
+#if ENABLE(ICONDATABASE)
 class SQLTransaction;
 #endif
 
@@ -91,7 +91,7 @@ private:
     ~IconDatabase();
     friend IconDatabase* iconDatabase();
 
-#if USE(ICONDATABASE)
+#if ENABLE(ICONDATABASE)
     // This tries to get the iconID for the IconURL and, if it doesn't exist and createIfNecessary is true,
     // it will create the entry and return the new iconID
     int64_t establishIconIDForIconURL(SQLDatabase&, const String&, bool createIfNecessary = true);