#include <boost/regex.hpp>
#endif
+#ifdef HAVE_JSC
#include <QtScript>
#include "pcre/pcre.h"
-
+#endif
#define ZLIB_VERSION "1.2.3.4"
class tst_qregexp : public QObject
void rangeReplace2();
void matchReplace2();
+#ifdef HAVE_JSC
void simpleFindJSC();
void rangeReplaceJSC();
void matchReplaceJSC();
+#endif
#ifdef HAVE_BOOST
void simpleFindBoost();
void horribleReplace1();
void horribleReplace2();
void horribleWrongReplace2();
+#ifdef HAVE_JSC
void horribleWrongReplaceJSC();
void horribleReplaceJSC();
+#endif
#ifdef HAVE_BOOST
void horribleWrongReplaceBoost();
void horribleReplaceBoost();
}
QCOMPARE(r, QString("1.2.3"));
}
-
-
+#ifdef HAVE_JSC
void tst_qregexp::simpleFindJSC()
{
int numr;
}
QCOMPARE(r.toString(), QString("1.2.3"));
}
-
+#endif
#ifdef HAVE_BOOST
void tst_qregexp::simpleFindBoost(){
INCLUDEPATH += .
RESOURCES+=qregexp.qrc
QT -= gui
-QT += script
CONFIG += release
# Input
SOURCES += main.cpp
-include( $${QT_SOURCE_TREE}/src/3rdparty/webkit/JavaScriptCore/JavaScriptCore.pri )
+!isEmpty(QT.webkit.sources):exists($${QT.webkit.sources}/../JavaScriptCore/JavaScriptCore.pri) {
+ include( $${QT.webkit.sources}/../JavaScriptCore/JavaScriptCore.pri )
+ DEFINES += HAVE_JSC
+ QT += script
+}
exists( /usr/include/boost/regex.hpp ){
DEFINES+=HAVE_BOOST