From 56b2a229a392befd23c6ff48d0c1af8605075d31 Mon Sep 17 00:00:00 2001 From: Olivier Goffart Date: Thu, 12 Jan 2012 22:34:44 +0100 Subject: Remove the Q_NO_DATA_RELOCATION hack This hack was there because symbian used to have a problem with relocations in the data section, between libraries. Hence, this was needed so the metaobject could have a pointer to the base metaobject, despite being in another library. Anyway, I was told that symbian was fixed eventually. but the hack had to stay there because of compatibility. But now that we don't even support symbian, we can get rid of this hack totally. Change-Id: I7249971ece35d952efa92bf8b04bf3aa3667624c Reviewed-by: Bradley T. Hughes --- src/tools/moc/generator.cpp | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'src/tools') diff --git a/src/tools/moc/generator.cpp b/src/tools/moc/generator.cpp index 8274f10a53..8793496b37 100644 --- a/src/tools/moc/generator.cpp +++ b/src/tools/moc/generator.cpp @@ -329,17 +329,10 @@ void Generator::generateCode() } if (!extraList.isEmpty()) { - fprintf(out, "#ifdef Q_NO_DATA_RELOCATION\n"); - fprintf(out, "static const QMetaObjectAccessor qt_meta_extradata_%s[] = {\n ", qualifiedClassNameIdentifier.constData()); - for (int i = 0; i < extraList.count(); ++i) { - fprintf(out, " %s::getStaticMetaObject,\n", extraList.at(i).constData()); - } - fprintf(out, "#else\n"); fprintf(out, "static const QMetaObject *qt_meta_extradata_%s[] = {\n ", qualifiedClassNameIdentifier.constData()); for (int i = 0; i < extraList.count(); ++i) { fprintf(out, " &%s::staticMetaObject,\n", extraList.at(i).constData()); } - fprintf(out, "#endif //Q_NO_DATA_RELOCATION\n"); fprintf(out, " 0\n};\n\n"); } @@ -384,12 +377,6 @@ void Generator::generateCode() if(isQt) return; -// -// Generate static meta object accessor (needed for symbian, because DLLs do not support data imports. -// - fprintf(out, "\n#ifdef Q_NO_DATA_RELOCATION\n"); - fprintf(out, "const QMetaObject &%s::getStaticMetaObject() { return staticMetaObject; }\n", cdef->qualified.constData()); - fprintf(out, "#endif //Q_NO_DATA_RELOCATION\n"); if (!cdef->hasQObject) return; -- cgit v1.2.3