Commit df1f5766 authored by Oswald Buddenhagen's avatar Oswald Buddenhagen

use DISTFILES instead of OTHER_FILES in docs, templates, and editors

the latter variable is entirely meaningless to qmake and should have
never been recognized by creator. unfortunately, qmake's dist target
wasn't very useful before qt 5.4, so it didn't occur to anybody to
actually use the variable associated with it, even though it is
semantically exactly the right thing.

Change-Id: I249857f54fdc38fb5ecac0f608e5f4140624c23c
Reviewed-by: default avatarDaniel Teske <daniel.teske@digia.com>
Reviewed-by: default avatarLeena Miettinen <riitta-leena.miettinen@digia.com>
parent 3e4f17c1
......@@ -86,7 +86,7 @@
\li Select the \gui {Use file defined in project files} option
to use the configuration file defined in the qmake
OTHER_FILES variable as the configuration file for the
DISTFILES variable as the configuration file for the
selected tool.
\li Select the \gui {Use $HOME} option to use the specified file
......
......@@ -2317,8 +2317,9 @@
\endlist
If locator does not find some files, you can add them to the \c OTHER_FILES
variable in the .pro file to make them known to \QC.
If locator does not find some files, you can add them to the \c DISTFILES
variable in the .pro file to include them into the distribution tarball
of your project and thus make them known to \QC as well.
\section1 Configuring Locator Filters
......
......@@ -199,10 +199,10 @@
\endlist
You can make additional files known to \QC, so that they become visible in
the \gui Projects view and known to the locator and search, but do not
affect the build system. Add the paths to the files to the \c OTHER_FILES
variable in the .pro file.
Files that are not sources or data can be still included into a project's
distribution tarball by adding their paths to the \c DISTFILES variable in
the .pro file. This way they also become known to \QC, so that they are
visible in the \gui Projects view and are known to the locator and search.
\section2 Viewing the File System
......
......@@ -340,7 +340,7 @@
\QC determines whether to display files from the project folder
in the \gui Projects pane depending on the file type (.pro, .pri, .cpp,
.h, .qrc, and so on). To display other types of files, edit the
project file. Add filenames as values of the \c {OTHER_FILES} variable.
project file. Add filenames as values of the \c {DISTFILES} variable.
You can also use wildcards.
For example, the following code specifies that text files are displayed
......@@ -348,7 +348,7 @@
\code
OTHER_FILES += *.txt
DISTFILES += *.txt
\endcode
......
......@@ -10,7 +10,7 @@ SOURCES += \
HEADERS += \
src/applicationui.%CppHeaderSuffix% \
OTHER_FILES += \
DISTFILES += \
bar-descriptor.xml \
assets/main.qml \
......
......@@ -15,7 +15,7 @@ HEADERS += \
%ProjectName:l%_plugin.%CppHeaderSuffix% \
%ObjectName:l%.%CppHeaderSuffix%
OTHER_FILES = qmldir
DISTFILES = qmldir
!equals(_PRO_FILE_PWD_, $$OUT_PWD) {
copy_qmldir.target = $$OUT_PWD/qmldir
......
......@@ -15,7 +15,7 @@ HEADERS += \
%ProjectName:l%_plugin.%CppHeaderSuffix% \
%ObjectName:l%.%CppHeaderSuffix%
OTHER_FILES = qmldir
DISTFILES = qmldir
!equals(_PRO_FILE_PWD_, $$OUT_PWD) {
copy_qmldir.target = $$OUT_PWD/qmldir
......
......@@ -1329,12 +1329,12 @@ QString QmakePriFileNode::varNameForAdding(const QString &mimeType)
return QLatin1String("FORMS");
if (mimeType == QLatin1String(ProjectExplorer::Constants::QML_MIMETYPE))
return QLatin1String("OTHER_FILES");
return QLatin1String("DISTFILES");
if (mimeType == QLatin1String(Constants::PROFILE_MIMETYPE))
return QLatin1String("SUBDIRS");
return QLatin1String("OTHER_FILES");
return QLatin1String("DISTFILES");
}
//!
......@@ -1354,7 +1354,7 @@ QStringList QmakePriFileNode::varNamesForRemoving()
vars << QLatin1String("FORMS");
vars << QLatin1String("OTHER_FILES");
vars << QLatin1String("SUBDIRS");
vars << QLatin1String("OTHER_FILES");
vars << QLatin1String("DISTFILES");
vars << QLatin1String("ICON");
vars << QLatin1String("QMAKE_INFO_PLIST");
return vars;
......
......@@ -142,7 +142,7 @@ Core::GeneratedFiles LibraryWizard::generateFiles(const QWizard *w,
if (!globalHeaderFileName.isEmpty())
proStr << "\\\n " << globalHeaderFileName << '\n';
if (!pluginJsonFileName.isEmpty())
proStr << "\nOTHER_FILES += " << pluginJsonFileName << '\n';
proStr << "\nDISTFILES += " << pluginJsonFileName << '\n';
writeLinuxProFile(proStr);
}
profile.setContents(profileContents);
......
......@@ -165,7 +165,7 @@ bool ProjectFileConverter::convertFile(Core::GeneratedFile &file, QString &error
fileContent.replace(QLatin1String("%HEADERS%"), headers.join(QLatin1String(" \\\n ")));
fileContent.replace(QLatin1String("%SOURCES%"), sources.join(QLatin1String(" \\\n ")));
fileContent.replace(QLatin1String("%RESOURCES%"), resources.join(QLatin1String(" \\\n ")));
fileContent.replace(QLatin1String("%OTHER_FILES%"), otherFiles.join(QLatin1String(" \\\n ")));
fileContent.replace(QLatin1String("%DISTFILES%"), otherFiles.join(QLatin1String(" \\\n ")));
fileContent.replace(QLatin1String("%PROJECT_NAME%"), convertedProjectContext().projectName());
fileContent.replace(QLatin1String("%TARGET%"), origProjectVariables.value(QLatin1String("TARGET"),
convertedProjectContext().projectName()));
......
......@@ -41,6 +41,6 @@ SOURCES += \
RESOURCES += \
%RESOURCES%
OTHER_FILES += \
DISTFILES += \
bar-descriptor.xml \
%OTHER_FILES%
%DISTFILES%
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment