equal
deleted
inserted
replaced
1 /**************************************************************************** |
1 /**************************************************************************** |
2 ** |
2 ** |
3 ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). |
3 ** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). |
4 ** All rights reserved. |
4 ** All rights reserved. |
5 ** Contact: Nokia Corporation (qt-info@nokia.com) |
5 ** Contact: Nokia Corporation (qt-info@nokia.com) |
6 ** |
6 ** |
7 ** This file is part of the qmake application of the Qt Toolkit. |
7 ** This file is part of the qmake application of the Qt Toolkit. |
8 ** |
8 ** |
162 return true; |
162 return true; |
163 } |
163 } |
164 return false; |
164 return false; |
165 } |
165 } |
166 |
166 |
167 void createLdObjectScriptFile(const QString &fileName, const QStringList &objList) |
167 void MingwMakefileGenerator::createLdObjectScriptFile(const QString &fileName, const QStringList &objList) |
168 { |
168 { |
169 QString filePath = Option::output_dir + QDir::separator() + fileName; |
169 QString filePath = Option::output_dir + QDir::separator() + fileName; |
170 QFile file(filePath); |
170 QFile file(filePath); |
171 if (file.open(QIODevice::WriteOnly | QIODevice::Text)) { |
171 if (file.open(QIODevice::WriteOnly | QIODevice::Text)) { |
172 if (Option::mkfile::listgen) { |
172 if (Option::mkfile::listgen) { |
173 // TODO generatePrint(fileInfo(file.fileName()).absoluteFilePath()); |
173 generatePrint(QFileInfo(file.fileName()).absoluteFilePath()); |
174 } |
174 } |
175 QTextStream t(&file); |
175 QTextStream t(&file); |
176 t << "INPUT(" << endl; |
176 t << "INPUT(" << endl; |
177 for (QStringList::ConstIterator it = objList.constBegin(); it != objList.constEnd(); ++it) { |
177 for (QStringList::ConstIterator it = objList.constBegin(); it != objList.constEnd(); ++it) { |
178 if (QDir::isRelativePath(*it)) |
178 if (QDir::isRelativePath(*it)) |
184 t.flush(); |
184 t.flush(); |
185 file.close(); |
185 file.close(); |
186 } |
186 } |
187 } |
187 } |
188 |
188 |
189 void createArObjectScriptFile(const QString &fileName, const QString &target, const QStringList &objList) |
189 void MingwMakefileGenerator::createArObjectScriptFile(const QString &fileName, const QString &target, const QStringList &objList) |
190 { |
190 { |
191 QString filePath = Option::output_dir + QDir::separator() + fileName; |
191 QString filePath = Option::output_dir + QDir::separator() + fileName; |
192 QFile file(filePath); |
192 QFile file(filePath); |
193 if (file.open(QIODevice::WriteOnly | QIODevice::Text)) { |
193 if (file.open(QIODevice::WriteOnly | QIODevice::Text)) { |
194 if (Option::mkfile::listgen) { |
194 if (Option::mkfile::listgen) { |
195 // TODO generatePrint(file.fileName()).absoluteFilePath()); |
195 generatePrint(QFileInfo(file.fileName()).absoluteFilePath()); |
196 } |
196 } |
197 QTextStream t(&file); |
197 QTextStream t(&file); |
198 t << "CREATE " << target << endl; |
198 t << "CREATE " << target << endl; |
199 for (QStringList::ConstIterator it = objList.constBegin(); it != objList.constEnd(); ++it) { |
199 for (QStringList::ConstIterator it = objList.constBegin(); it != objList.constEnd(); ++it) { |
200 if (QDir::isRelativePath(*it)) |
200 if (QDir::isRelativePath(*it)) |