move preparation of configure test build dir to qmake-based system
Change-Id: I650fb92cfa858bf6d7ff5756aa0efe182f036a55 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
This commit is contained in:
parent
80e63223f8
commit
2dcc1a8e46
5
configure
vendored
5
configure
vendored
@ -452,11 +452,6 @@ fi
|
||||
# initalize variables
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
# Use CC/CXX to run config.tests
|
||||
mkdir -p "$outpath/config.tests"
|
||||
rm -f "$outpath/config.tests/.qmake.cache"
|
||||
: > "$outpath/config.tests/.qmake.cache"
|
||||
|
||||
# QTDIR may be set and point to an old or system-wide Qt installation
|
||||
unset QTDIR
|
||||
|
||||
|
@ -770,6 +770,7 @@ defineTest(qtConfTest_compile) {
|
||||
QMAKE_MAKE = "$$QMAKE_MAKE clean && $$QMAKE_MAKE"
|
||||
|
||||
mkpath($$test_out_dir)|error()
|
||||
write_file($$test_out_dir/.qmake.cache)|error()
|
||||
|
||||
# add possible command line args
|
||||
qmake_args += $$qtConfPrepareArgs($$eval($${1}.args)) $$eval($${1}.literal_args)
|
||||
|
@ -93,7 +93,6 @@ Configure::Configure(int& argc, char** argv)
|
||||
QDir(buildPath).mkpath("bin");
|
||||
|
||||
buildDir.mkpath("mkspecs");
|
||||
buildDir.mkpath("config.tests");
|
||||
}
|
||||
|
||||
dictionary[ "QT_INSTALL_PREFIX" ] = installPath;
|
||||
@ -479,25 +478,6 @@ void Configure::parseCmdLine()
|
||||
}
|
||||
}
|
||||
|
||||
void Configure::prepareConfigTests()
|
||||
{
|
||||
// Generate an empty .qmake.cache file for config.tests
|
||||
QDir buildDir(buildPath);
|
||||
bool success = true;
|
||||
if (!buildDir.exists("config.tests"))
|
||||
success = buildDir.mkdir("config.tests");
|
||||
|
||||
QString fileName(buildPath + "/config.tests/.qmake.cache");
|
||||
QFile cacheFile(fileName);
|
||||
success &= cacheFile.open(QIODevice::WriteOnly);
|
||||
cacheFile.close();
|
||||
|
||||
if (!success) {
|
||||
cout << "Failed to create file " << qPrintable(QDir::toNativeSeparators(fileName)) << endl;
|
||||
dictionary[ "DONE" ] = "error";
|
||||
}
|
||||
}
|
||||
|
||||
void Configure::generateQDevicePri()
|
||||
{
|
||||
FileWriter deviceStream(buildPath + "/mkspecs/qdevice.pri");
|
||||
|
@ -52,7 +52,6 @@ public:
|
||||
|
||||
void generateHeaders();
|
||||
void generateQDevicePri();
|
||||
void prepareConfigTests();
|
||||
|
||||
bool isDone();
|
||||
bool isOk();
|
||||
|
@ -63,11 +63,6 @@ int runConfigure( int argc, char** argv )
|
||||
if (!app.isOk())
|
||||
return 3;
|
||||
|
||||
// Prepare the config test build directory.
|
||||
app.prepareConfigTests();
|
||||
if (!app.isOk())
|
||||
return 3;
|
||||
|
||||
// run qmake based configure
|
||||
app.configure();
|
||||
if (!app.isOk())
|
||||
|
Loading…
Reference in New Issue
Block a user