From c7066c9dc25bc4cafdd7bd8057ce34457a86ee65 Mon Sep 17 00:00:00 2001 From: Arttu Tarkiainen Date: Wed, 7 Aug 2019 14:51:12 +0300 Subject: Update usage of Apple-related terminology Replace deprecated Q_OS_OSX macro used in several places with the newer Q_OS_MACOS. Old style reference of Apple's desktop operating system name as "OS X" in documentation and files are also replaced with "macOS" where applicable. Task-number: QTIFW-1406 Change-Id: I0561d5e0d964917ac4fca0702d58a06b85d30e57 Reviewed-by: Katja Marttila --- INSTALL | 4 ++-- README | 2 +- doc/includes/installerfw-examples-generating.qdocinc | 2 +- doc/installerfw-getting-started.qdoc | 4 ++-- doc/installerfw-overview.qdoc | 2 +- doc/installerfw-using.qdoc | 8 ++++---- doc/installerfw.qdoc | 14 +++++++------- doc/scripting-api/buttons.qdoc | 6 +++--- doc/scripting-api/qfiledialog.qdoc | 2 +- doc/scripting.qdoc | 2 +- doc/systeminfo.qdoc | 4 ++-- doc/tutorial.qdoc | 2 +- examples/doc/dynamicpage.qdoc | 2 +- examples/doc/online.qdoc | 6 +++--- examples/doc/openreadme.qdoc | 2 +- examples/doc/systeminfo.qdoc | 6 +++--- .../systeminfo/packages/root/meta/installscript.qs | 2 +- examples/translations/README | 2 +- src/libs/installer/fileutils.cpp | 4 ++-- src/libs/installer/messageboxhandler.cpp | 2 +- src/libs/installer/packagemanagercore.cpp | 2 +- src/libs/installer/packagemanagercore_p.cpp | 20 ++++++++++---------- src/libs/installer/packagemanagercoredata.cpp | 4 ++-- src/libs/installer/packagemanagergui.cpp | 10 +++++----- src/libs/installer/remoteserver.cpp | 2 +- src/libs/installer/settings.cpp | 2 +- src/libs/installer/systeminfo.cpp | 4 ++-- src/libs/kdtools/updateoperation.cpp | 2 +- src/sdk/commandlineparser.cpp | 2 +- src/sdk/main.cpp | 8 ++++---- src/sdk/sdkapp.h | 10 +++++----- tests/auto/installer/settings/tst_settings.cpp | 2 +- tools/binarycreator/binarycreator.cpp | 18 +++++++++--------- tools/binarycreator/resources/copylibsintobundle.sh | 2 +- tools/devtool/binaryreplace.cpp | 2 +- tools/devtool/main.cpp | 2 +- 36 files changed, 85 insertions(+), 85 deletions(-) diff --git a/INSTALL b/INSTALL index f29d85699..195f59766 100644 --- a/INSTALL +++ b/INSTALL @@ -40,9 +40,9 @@ Recommended configuration options for Linux: configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -qt-xcb -qt-pcre -no-glib -no-cups -no-sql-sqlite -no-qml-debug -no-opengl -no-egl -no-xinput2 -no-sm -no-icu -nomake examples -nomake tests -no-libudev Build Qt: make module-qtbase module-qtdeclarative module-qttools module-qttranslations -### OS X +### macOS -Recommended configuration options for OS X: +Recommended configuration options for macOS: configure -prefix $PWD/qtbase -release -static -no-securetransport -accessibility -qt-zlib -qt-libpng -qt-libjpeg -no-cups -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -no-freetype Build Qt: diff --git a/README b/README index 126d2d6d1..0130bfd8c 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ The Qt Installer Framework provides a set of tools and utilities to create installers for the supported desktop Qt platforms: Linux, Microsoft Windows, and -OS X. +macOS. Documentation diff --git a/doc/includes/installerfw-examples-generating.qdocinc b/doc/includes/installerfw-examples-generating.qdocinc index 45ea2fc22..65ef313b5 100644 --- a/doc/includes/installerfw-examples-generating.qdocinc +++ b/doc/includes/installerfw-examples-generating.qdocinc @@ -8,7 +8,7 @@ \code ..\..\bin\binarycreator.exe -c config\config.xml -p packages installer.exe \endcode - \li On Linux or OS X: + \li On Linux or macOS: \code ../../bin/binarycreator -c config/config.xml -p packages installer \endcode diff --git a/doc/installerfw-getting-started.qdoc b/doc/installerfw-getting-started.qdoc index f3832ddae..7d3300138 100644 --- a/doc/installerfw-getting-started.qdoc +++ b/doc/installerfw-getting-started.qdoc @@ -99,9 +99,9 @@ make module-qtbase module-qtdeclarative module-qttools module-qttranslations \endcode - \section3 Configuring Qt for OS X + \section3 Configuring Qt for macOS - We recommend that you use the following configuration options for OS X: + We recommend that you use the following configuration options for macOS: \code configure -prefix $PWD/qtbase -release -static -no-securetransport -accessibility -qt-zlib -qt-libpng -qt-libjpeg -no-cups -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -no-freetype diff --git a/doc/installerfw-overview.qdoc b/doc/installerfw-overview.qdoc index ee93fcf5a..9a5da1943 100644 --- a/doc/installerfw-overview.qdoc +++ b/doc/installerfw-overview.qdoc @@ -37,7 +37,7 @@ create installers once, and deploy them across all the supported desktop Qt platforms without rewriting the source code. The installers will have the native look and feel on the platform where they are run: Linux, Microsoft - Windows, and OS X. + Windows, and macOS. The Qt Installer Framework tools generate installers with a set of pages that guide the users during the installation, update, or uninstallation diff --git a/doc/installerfw-using.qdoc b/doc/installerfw-using.qdoc index 178957dbd..30065fa56 100644 --- a/doc/installerfw-using.qdoc +++ b/doc/installerfw-using.qdoc @@ -71,7 +71,7 @@ \image ifw-user-flow-installing.png "Installation workflow" - This section uses the \e {Your Application Installer} example run on OS X + This section uses the \e {Your Application Installer} example run on macOS to illustrate the default workflow for end users. The installers have the native look and feel on each supported desktop platform, and therefore they look and feel different when run on Linux and Windows. @@ -188,7 +188,7 @@ \image ifw-user-flow-adding.png "Add components workflow" This section uses the \e {Maintenance Tool} installed by the Qt 5 installer - run on OS X as an example implementation of how end users can add components + run on macOS as an example implementation of how end users can add components after the initial installation. The Maintenance Tool contains the package manager, updater, and uninstaller. @@ -244,7 +244,7 @@ \image ifw-user-flow-removing.png "Remove components workflow" - This section uses the Qt 5 Maintenance Tool run on OS X as an example + This section uses the Qt 5 Maintenance Tool run on macOS as an example implementation of how end users can remove all or selected components. \section1 Removing All Components @@ -297,7 +297,7 @@ \image ifw-user-flow-updating.png "Updating workflow" - This section uses the Qt 5 Maintenance Tool run on OS X as an example + This section uses the Qt 5 Maintenance Tool run on macOS as an example implementation of how end users can update installed components. \section1 Starting Updater diff --git a/doc/installerfw.qdoc b/doc/installerfw.qdoc index ec3c3781b..07859b0d9 100644 --- a/doc/installerfw.qdoc +++ b/doc/installerfw.qdoc @@ -42,7 +42,7 @@ The Qt Installer Framework provides a set of tools and utilities to create installers for the supported desktop Qt platforms: Linux, Microsoft - Windows, and OS X. + Windows, and macOS. \note Report bugs and suggestions for the Qt Installer Framework project in the \l{https://bugreports.qt.io/browse/QTIFW}{Qt Bugtracker}. @@ -191,13 +191,13 @@ \row \li Icon \li Filename for a custom installer icon. The actual file is looked up by attaching - a '.icns' (OS X), '.ico' (Windows) or '.png' (Unix) suffix. Deprecated, + a '.icns' (macOS), '.ico' (Windows) or '.png' (Unix) suffix. Deprecated, use \c or \c instead. \row \li InstallerApplicationIcon \li Filename for a custom installer icon. The actual file is looked up by attaching - a '.icns' (OS X), '.ico' (Windows). No functionality on Unix. + a '.icns' (macOS), '.ico' (Windows). No functionality on Unix. \row \li InstallerWindowIcon \li Filename for a custom window icon in PNG format for the Installer application. @@ -794,7 +794,7 @@ \binarycreator.exe -t \installerbase.exe -p -c \ \endcode - \li On Linux and OS X + \li On Linux and macOS \code /binarycreator -t /installerbase -p -c / @@ -812,7 +812,7 @@ \binarycreator.exe -t \installerbase.exe -p -c \ -e \endcode - \li On Linux and OS X + \li On Linux and macOS \code /binarycreator -t /installerbase -p -c / -e @@ -883,7 +883,7 @@ \row \li -s or --sign identity - \li Only available on OS X. Allows specifying a code signing identity to be + \li Only available on macOS. Allows specifying a code signing identity to be used for signing the generated app bundle. \endtable @@ -907,7 +907,7 @@ \section2 Using Icons - On OS X, if the target binary is suffixed with .app, a OS X + On macOS, if the target binary is suffixed with .app, a macOS application bundle is created. The icon that you specify in config.xml is extended with .icns and used as the icon for the created bundle. diff --git a/doc/scripting-api/buttons.qdoc b/doc/scripting-api/buttons.qdoc index a96d68434..811bde587 100644 --- a/doc/scripting-api/buttons.qdoc +++ b/doc/scripting-api/buttons.qdoc @@ -42,13 +42,13 @@ Specifies the buttons on an installer page. \value buttons.BackButton - The \uicontrol Back button (\uicontrol {Go Back} on OS X.) + The \uicontrol Back button (\uicontrol {Go Back} on macOS.) \value buttons.NextButton - The \uicontrol Next button (\uicontrol Continue on OS X.) + The \uicontrol Next button (\uicontrol Continue on macOS.) \value buttons.CommitButton The \uicontrol Commit button. \value buttons.FinishButton - The \uicontrol Finish button (\uicontrol Done on OS X.) + The \uicontrol Finish button (\uicontrol Done on macOS.) \value buttons.CancelButton The \uicontrol Cancel button. \value buttons.HelpButton diff --git a/doc/scripting-api/qfiledialog.qdoc b/doc/scripting-api/qfiledialog.qdoc index ecce6f59d..5433697ce 100644 --- a/doc/scripting-api/qfiledialog.qdoc +++ b/doc/scripting-api/qfiledialog.qdoc @@ -66,6 +66,6 @@ "Images (*.png *.xpm *.jpg);;Text files (*.txt);;XML files (*.xml)" \endcode - On Windows, and OS X, this static function will use the native file dialog + On Windows, and macOS, this static function will use the native file dialog and not a QFileDialog. */ diff --git a/doc/scripting.qdoc b/doc/scripting.qdoc index 708345c7d..20004e9b7 100644 --- a/doc/scripting.qdoc +++ b/doc/scripting.qdoc @@ -265,7 +265,7 @@ \li Applications directory. For example, \c {C:\Program Files} on Windows, - \c {/opt} on Linux and \c {/Applications} on OS X. + \c {/opt} on Linux and \c {/Applications} on macOS. See also the table that lists examples of \l {Applications-directory-on-Windows} {applications directories on Windows}. diff --git a/doc/systeminfo.qdoc b/doc/systeminfo.qdoc index fde826066..5e64db484 100644 --- a/doc/systeminfo.qdoc +++ b/doc/systeminfo.qdoc @@ -58,7 +58,7 @@ kernel the installer is running on, unless the host operating system is running a form of compatibility or virtualization layer. - For Windows, Linux, and OS X this will return + For Windows, Linux, and macOS this will return \list \li "winnt" \li "linux" @@ -82,7 +82,7 @@ \endlist The release version of the operating system kernel. On Windows, it returns the version of the - NT or CE kernel. On Unix systems, including OS X, it returns the same as the \c {uname -r} + NT or CE kernel. On Unix systems, including macOS, it returns the same as the \c {uname -r} command would return. \sa QSysInfo::kernelVersion() diff --git a/doc/tutorial.qdoc b/doc/tutorial.qdoc index df53d22a6..0633c94a5 100644 --- a/doc/tutorial.qdoc +++ b/doc/tutorial.qdoc @@ -195,7 +195,7 @@ ..\..\bin\binarycreator.exe -c config\config.xml -p packages YourInstaller.exe \endcode - \li On Linux or OS X: + \li On Linux or macOS: \code ../../bin/binarycreator -c config/config.xml -p packages YourInstaller \endcode diff --git a/examples/doc/dynamicpage.qdoc b/examples/doc/dynamicpage.qdoc index 3dbc0d287..acbf9639c 100644 --- a/examples/doc/dynamicpage.qdoc +++ b/examples/doc/dynamicpage.qdoc @@ -105,7 +105,7 @@ \code ..\..\bin\binarycreator.exe -c config\config.xml -r resources/additional.qrc -p packages installer.exe \endcode - \li On Linux or OS X: + \li On Linux or macOS: \code ../../bin/binarycreator -c config/config.xml -r resources/additional.qrc -p packages installer \endcode diff --git a/examples/doc/online.qdoc b/examples/doc/online.qdoc index b64a2d6ee..90be15551 100644 --- a/examples/doc/online.qdoc +++ b/examples/doc/online.qdoc @@ -74,7 +74,7 @@ \code ..\..\bin\repogen.exe -p packages repository \endcode - \li On Linux or OS X: + \li On Linux or macOS: \code ../../bin/repogen -p packages repository \endcode @@ -114,7 +114,7 @@ \code ..\..\bin\binarycreator.exe --online-only -c config\config.xml -p packages installer.exe \endcode - \li On Linux or OS X: + \li On Linux or macOS: \code ../../bin/binarycreator --online-only -c config/config.xml -p packages installer \endcode @@ -139,7 +139,7 @@ \code ..\..\bin\repogen.exe --update-new-components -p packages_update repository \endcode - \li On Linux or OS X: + \li On Linux or macOS: \code ../../bin/repogen --update-new-components -p packages_update repository \endcode diff --git a/examples/doc/openreadme.qdoc b/examples/doc/openreadme.qdoc index 97e9a0422..86a6e3182 100644 --- a/examples/doc/openreadme.qdoc +++ b/examples/doc/openreadme.qdoc @@ -61,7 +61,7 @@ In installscript.qs, we use the \c Component() function to connect to the \c installationFinishedPageIsShown signal when the installation is complete and to the \c installationFinished signal when the end users click - \uicontrol Finish (\uicontrol Done on OS X): + \uicontrol Finish (\uicontrol Done on macOS): \quotefromfile openreadme/packages/or.qtproject.ifw.example.openreadme/meta/installscript.qs \skipto Component() diff --git a/examples/doc/systeminfo.qdoc b/examples/doc/systeminfo.qdoc index 027587af1..11a2573c5 100644 --- a/examples/doc/systeminfo.qdoc +++ b/examples/doc/systeminfo.qdoc @@ -84,9 +84,9 @@ \printto /\!validOs/ The script uses \l{systemInfo::productType}{systemInfo.productType} to differentiate - between Windows, OS X, and individual Linux distributions. + between Windows, macOS, and individual Linux distributions. - For OS X and Windows, the script checks the operating system kernel version. + For macOS and Windows, the script checks the operating system kernel version. For a mapping of kernel to operating system versions, see \l{http://en.wikipedia.org/wiki/Darwin_%28operating_system%29}{Darwin} and \l{http://en.wikipedia.org/wiki/Windows_NT}{Windows NT}. @@ -95,7 +95,7 @@ the specific distribution and version the binaries are presumably built for, the installer shows a warning in a modal dialog, but allows installation. - If the Windows or OS X version is too old, though, the script calls the \c cancelInstaller() + If the Windows or macOS version is too old, though, the script calls the \c cancelInstaller() helper function to prevent an actual installation: \printuntil /\}/ diff --git a/examples/systeminfo/packages/root/meta/installscript.qs b/examples/systeminfo/packages/root/meta/installscript.qs index 0b77b2f12..f5435b652 100644 --- a/examples/systeminfo/packages/root/meta/installscript.qs +++ b/examples/systeminfo/packages/root/meta/installscript.qs @@ -55,7 +55,7 @@ function Component() // // Check whether OS is supported. // - // For Windows and OS X we check the kernel version: + // For Windows and macOS we check the kernel version: // - Require at least Windows Vista (winnt kernel version 6.0.x) // - Require at least OS X 10.7 (Lion) (darwin kernel version 11.x) // diff --git a/examples/translations/README b/examples/translations/README index b3c20e3d7..a077fe2cb 100644 --- a/examples/translations/README +++ b/examples/translations/README @@ -12,4 +12,4 @@ Linux: LANGUAGE=de ./installer -On OS X and Windows you need to adapt the system settings to set German as preferred language, and then start the installer. +On macOS and Windows you need to adapt the system settings to set German as preferred language, and then start the installer. diff --git a/src/libs/installer/fileutils.cpp b/src/libs/installer/fileutils.cpp index 4347c67da..18c5f90fd 100644 --- a/src/libs/installer/fileutils.cpp +++ b/src/libs/installer/fileutils.cpp @@ -286,7 +286,7 @@ void QInstaller::removeSystemGeneratedFiles(const QString &path) { if (path.isEmpty()) return; -#if defined Q_OS_OSX +#if defined Q_OS_MACOS QFile::remove(path + QLatin1String("/.DS_Store")); #elif defined Q_OS_WIN QFile::remove(path + QLatin1String("/Thumbs.db")); @@ -572,7 +572,7 @@ quint64 QInstaller::fileSize(const QFileInfo &info) bool QInstaller::isInBundle(const QString &path, QString *bundlePath) { -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS QFileInfo fi = QFileInfo(path).absoluteFilePath(); while (!fi.isRoot()) { if (fi.isBundle()) { diff --git a/src/libs/installer/messageboxhandler.cpp b/src/libs/installer/messageboxhandler.cpp index 286009e21..28e09df44 100644 --- a/src/libs/installer/messageboxhandler.cpp +++ b/src/libs/installer/messageboxhandler.cpp @@ -381,7 +381,7 @@ static QMessageBox::StandardButton showNewMessageBox(QWidget *parent, QMessageBo msgBox.setDefaultButton(button); } } -#if defined(Q_OS_OSX) +#if defined(Q_OS_MACOS) msgBox.setWindowModality(Qt::WindowModal); #endif if (msgBox.exec() == -1) diff --git a/src/libs/installer/packagemanagercore.cpp b/src/libs/installer/packagemanagercore.cpp index 028a5b4b2..c154edf76 100644 --- a/src/libs/installer/packagemanagercore.cpp +++ b/src/libs/installer/packagemanagercore.cpp @@ -2201,7 +2201,7 @@ QString PackageManagerCore::findLibrary(const QString &name, const QStringList & #if defined(Q_OS_WIN) return findPath(QString::fromLatin1("%1.lib").arg(name), findPaths); #else -#if defined(Q_OS_OSX) +#if defined(Q_OS_MACOS) if (findPaths.isEmpty()) { findPaths.push_back(QLatin1String("/lib")); findPaths.push_back(QLatin1String("/usr/lib")); diff --git a/src/libs/installer/packagemanagercore_p.cpp b/src/libs/installer/packagemanagercore_p.cpp index 1526d8bd0..653869898 100644 --- a/src/libs/installer/packagemanagercore_p.cpp +++ b/src/libs/installer/packagemanagercore_p.cpp @@ -590,7 +590,7 @@ void PackageManagerCorePrivate::initialize(const QHash ¶ms #endif if (!m_core->isInstaller()) { -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS readMaintenanceConfigFiles(QCoreApplication::applicationDirPath() + QLatin1String("/../../..")); #else readMaintenanceConfigFiles(QCoreApplication::applicationDirPath()); @@ -718,7 +718,7 @@ Operation *PackageManagerCorePrivate::takeOwnedOperation(Operation *operation) QString PackageManagerCorePrivate::maintenanceToolName() const { QString filename = m_data.settings().maintenanceToolName(); -#if defined(Q_OS_OSX) +#if defined(Q_OS_MACOS) if (QInstaller::isInBundle(QCoreApplication::applicationDirPath())) filename += QLatin1String(".app/Contents/MacOS/") + filename; #elif defined(Q_OS_WIN) @@ -1044,7 +1044,7 @@ void PackageManagerCorePrivate::writeMaintenanceToolBinary(QFile *const input, q if (writeBinaryLayout) { QDir resourcePath(QFileInfo(maintenanceToolRenamedName).dir()); -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS if (!resourcePath.path().endsWith(QLatin1String("Contents/MacOS"))) throw Error(tr("Maintenance tool is not a bundle")); resourcePath.cdUp(); @@ -1172,7 +1172,7 @@ void PackageManagerCorePrivate::writeMaintenanceTool(OperationList performedOper const QString targetAppDirPath = QFileInfo(maintenanceToolName()).path(); if (!QDir().exists(targetAppDirPath)) { - // create the directory containing the maintenance tool (like a bundle structure on OS X...) + // create the directory containing the maintenance tool (like a bundle structure on macOS...) Operation *op = createOwnedOperation(QLatin1String("Mkdir")); op->setArguments(QStringList() << targetAppDirPath); performOperationThreaded(op, Backup); @@ -1180,7 +1180,7 @@ void PackageManagerCorePrivate::writeMaintenanceTool(OperationList performedOper performedOperations.append(takeOwnedOperation(op)); } -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS // if it is a bundle, we need some stuff in it... const QString sourceAppDirPath = QCoreApplication::applicationDirPath(); if (isInstaller() && QInstaller::isInBundle(sourceAppDirPath)) { @@ -1340,7 +1340,7 @@ void PackageManagerCorePrivate::writeMaintenanceTool(OperationList performedOper // On Mac data is always in a separate file so that the binary can be signed. // On other platforms data is in separate file only after install so that the // maintenancetool sign does not break. -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS QDir dataPath(QFileInfo(binaryName).dir()); dataPath.cdUp(); dataPath.cd(QLatin1String("Resources")); @@ -1355,7 +1355,7 @@ void PackageManagerCorePrivate::writeMaintenanceTool(OperationList performedOper newBinaryWritten = true; QFile tmp(binaryName); QInstaller::openForRead(&tmp); -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS writeMaintenanceToolBinary(&tmp, tmp.size(), true); #else writeMaintenanceToolBinary(&tmp, layout.endOfBinaryContent - layout.binaryContentSize, true); @@ -1554,8 +1554,8 @@ bool PackageManagerCorePrivate::runInstaller() Operation *createRepo = createOwnedOperation(QLatin1String("CreateLocalRepository")); if (createRepo) { QString binaryFile = QCoreApplication::applicationFilePath(); -#ifdef Q_OS_OSX - // The installer binary on OSX does not contain the binary content, it's put into +#ifdef Q_OS_MACOS + // The installer binary on macOS does not contain the binary content, it's put into // the resources folder as separate file. Adjust the actual binary path. No error // checking here since we will fail later while reading the binary content. QDir resourcePath(QFileInfo(binaryFile).dir()); @@ -2028,7 +2028,7 @@ void PackageManagerCorePrivate::deleteMaintenanceTool() // every other platform has no problem if we just delete ourselves now QFile maintenanceTool(QFileInfo(installerBinaryPath()).absoluteFilePath()); maintenanceTool.remove(); -# ifdef Q_OS_OSX +# ifdef Q_OS_MACOS if (QInstaller::isInBundle(installerBinaryPath())) { const QLatin1String cdUp("/../../.."); removeDirectoryThreaded(QFileInfo(installerBinaryPath() + cdUp).absoluteFilePath()); diff --git a/src/libs/installer/packagemanagercoredata.cpp b/src/libs/installer/packagemanagercoredata.cpp index ebacbf938..e9af30d17 100644 --- a/src/libs/installer/packagemanagercoredata.cpp +++ b/src/libs/installer/packagemanagercoredata.cpp @@ -57,7 +57,7 @@ PackageManagerCoreData::PackageManagerCoreData(const QHash &va #ifdef Q_OS_WIN m_variables.insert(QLatin1String("os"), QLatin1String("win")); -#elif defined(Q_OS_OSX) +#elif defined(Q_OS_MACOS) m_variables.insert(QLatin1String("os"), QLatin1String("mac")); #elif defined(Q_OS_LINUX) m_variables.insert(QLatin1String("os"), QLatin1String("x11")); @@ -110,7 +110,7 @@ void PackageManagerCoreData::setDynamicPredefinedVariables() TCHAR buffer[MAX_PATH + 1] = { 0 }; SHGetFolderPath(nullptr, CSIDL_PROGRAM_FILES, nullptr, 0, buffer); dir = QString::fromWCharArray(buffer); -#elif defined (Q_OS_OSX) +#elif defined (Q_OS_MACOS) dir = QStandardPaths::standardLocations(QStandardPaths::ApplicationsLocation).value(0); #endif m_variables.insert(QLatin1String("ApplicationsDir"), dir); diff --git a/src/libs/installer/packagemanagergui.cpp b/src/libs/installer/packagemanagergui.cpp index c3591d446..934570ae1 100644 --- a/src/libs/installer/packagemanagergui.cpp +++ b/src/libs/installer/packagemanagergui.cpp @@ -305,7 +305,7 @@ PackageManagerGui::PackageManagerGui(PackageManagerCore *core, QWidget *parent) setWindowTitle(tr("Maintain %1").arg(m_core->value(scTitle))); setWindowFlags(windowFlags() &~ Qt::WindowContextHelpButtonHint); -#ifndef Q_OS_OSX +#ifndef Q_OS_MACOS setWindowIcon(QIcon(m_core->settings().installerWindowIcon())); #else setPixmap(QWizard::BackgroundPixmap, m_core->settings().background()); @@ -408,7 +408,7 @@ PackageManagerGui::~PackageManagerGui() \list \li \c Classic - Classic UI style for Windows 7 and earlier. \li \c Modern - Modern UI style for Windows 8. - \li \c Mac - UI style for OS X. + \li \c Mac - UI style for macOS. \li \c Aero - Aero Peek for Windows 7. \endlist */ @@ -2178,7 +2178,7 @@ bool TargetDirectoryPage::validatePage() const QFileInfo fi(targetDir); if (fi.isDir()) { QString fileName = packageManagerCore()->settings().maintenanceToolName(); -#if defined(Q_OS_OSX) +#if defined(Q_OS_MACOS) if (QInstaller::isInBundle(QCoreApplication::applicationDirPath())) fileName += QLatin1String(".app/Contents/MacOS/") + fileName; #elif defined(Q_OS_WIN) @@ -2849,7 +2849,7 @@ void FinishedPage::entering() } if (packageManagerCore()->isMaintainer()) { -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS gui()->setOption(QWizard::NoCancelButton, false); #endif if (QAbstractButton *cancel = gui()->button(QWizard::CancelButton)) { @@ -2913,7 +2913,7 @@ void FinishedPage::entering() */ void FinishedPage::leaving() { -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS gui()->setOption(QWizard::NoCancelButton, true); #endif diff --git a/src/libs/installer/remoteserver.cpp b/src/libs/installer/remoteserver.cpp index 9d178ca06..ddf4d6ecf 100644 --- a/src/libs/installer/remoteserver.cpp +++ b/src/libs/installer/remoteserver.cpp @@ -65,7 +65,7 @@ void RemoteServer::start() if (d->m_localServer) return; -#if defined(Q_OS_UNIX) && !defined(Q_OS_OSX) +#if defined(Q_OS_UNIX) && !defined(Q_OS_MACOS) // avoid writing to stderr: // the parent process has redirected stderr to a pipe to work with sudo, // but is not reading anymore -> writing to stderr will block after a while. diff --git a/src/libs/installer/settings.cpp b/src/libs/installer/settings.cpp index 0963f2208..3aa0baf18 100644 --- a/src/libs/installer/settings.cpp +++ b/src/libs/installer/settings.cpp @@ -472,7 +472,7 @@ QString Settings::installerWindowIcon() const QString Settings::systemIconSuffix() const { -#if defined(Q_OS_OSX) +#if defined(Q_OS_MACOS) return QLatin1String(".icns"); #elif defined(Q_OS_WIN) return QLatin1String(".ico"); diff --git a/src/libs/installer/systeminfo.cpp b/src/libs/installer/systeminfo.cpp index eb4e9cde9..6a1976c4a 100644 --- a/src/libs/installer/systeminfo.cpp +++ b/src/libs/installer/systeminfo.cpp @@ -76,7 +76,7 @@ QString SystemInfo::currentCpuArchitecture() const kernel the installer is running on, unless the host operating system is running a form of compatibility or virtualization layer. - For Windows, Linux, and OS X this will return: + For Windows, Linux, and macOS this will return: \list \li "winnt" \li "linux" @@ -96,7 +96,7 @@ QString SystemInfo::kernelType() const \property SystemInfo::kernelVersion The release version of the operating system kernel. On Windows, it returns the version of the - NT or CE kernel. On Unix systems, including OS X, it returns the same as the \c {uname -r} + NT or CE kernel. On Unix systems, including macOS, it returns the same as the \c {uname -r} command would return. Example values are: diff --git a/src/libs/kdtools/updateoperation.cpp b/src/libs/kdtools/updateoperation.cpp index dc40b0e1b..1dcb0014b 100644 --- a/src/libs/kdtools/updateoperation.cpp +++ b/src/libs/kdtools/updateoperation.cpp @@ -455,7 +455,7 @@ QDomDocument UpdateOperation::toXml() const bool UpdateOperation::fromXml(const QDomDocument &doc) { QString target = QCoreApplication::applicationDirPath(); - // Does not change target on non OSX platforms. + // Does not change target on non macOS platforms. if (QInstaller::isInBundle(target, &target)) target = QDir::cleanPath(target + QLatin1String("/..")); diff --git a/src/sdk/commandlineparser.cpp b/src/sdk/commandlineparser.cpp index 80aa0afa8..3d0d2412a 100644 --- a/src/sdk/commandlineparser.cpp +++ b/src/sdk/commandlineparser.cpp @@ -51,7 +51,7 @@ CommandLineParser::CommandLineParser() QLatin1String("Verbose mode. Prints out more information."))); m_parser.addOption(QCommandLineOption(QLatin1String(CommandLineOptions::Proxy), - QLatin1String("Use system proxy on Windows and Linux. This option has no effect on OS X."))); + QLatin1String("Use system proxy on Windows and Linux. This option has no effect on macOS."))); m_parser.addOption(QCommandLineOption(QLatin1String(CommandLineOptions::NoProxy), QLatin1String("Do not use system proxy."))); diff --git a/src/sdk/main.cpp b/src/sdk/main.cpp index 819d512c2..336ff51b0 100644 --- a/src/sdk/main.cpp +++ b/src/sdk/main.cpp @@ -44,7 +44,7 @@ #include -#if defined(Q_OS_OSX) or defined(Q_OS_UNIX) +#if defined(Q_OS_MACOS) or defined(Q_OS_UNIX) # include # include #endif @@ -66,7 +66,7 @@ int main(int argc, char *argv[]) } #endif // increase maximum numbers of file descriptors -#if defined (Q_OS_OSX) +#if defined (Q_OS_MACOS) QCoreApplication::setSetuidAllowed(true); struct rlimit rl; getrlimit(RLIMIT_NOFILE, &rl); @@ -141,7 +141,7 @@ int main(int argc, char *argv[]) Qt::CaseInsensitive) == 0); if (production) { argumentsValid = (!key.isEmpty()) && (!socketName.isEmpty()); -#if defined(Q_OS_UNIX) && !defined(Q_OS_OSX) +#if defined(Q_OS_UNIX) && !defined(Q_OS_MACOS) /* In production mode detach child so that sudo waiting on us will terminate. */ pid_t child = fork(); if (child <= -1) { @@ -166,7 +166,7 @@ int main(int argc, char *argv[]) return EXIT_FAILURE; } -#if defined(Q_OS_OSX) +#if defined(Q_OS_MACOS) // make sure effective == real user id. uid_t realUserId = getuid(); uid_t effectiveUserId = geteuid(); diff --git a/src/sdk/sdkapp.h b/src/sdk/sdkapp.h index 17d0ac5e3..68d7a2434 100644 --- a/src/sdk/sdkapp.h +++ b/src/sdk/sdkapp.h @@ -73,21 +73,21 @@ public: as the binary layout cannot be appended to the actual maintenance tool binary itself because of signing. - On OS X: This function will return always the .dat file + On macOS: This function will return always the .dat file .dat file is located inside the resource folder in the application - bundle in OS X. + bundle in macOS. */ QString binaryFile() const { QString binaryFile = QCoreApplication::applicationFilePath(); - // The installer binary on OSX and Windows does not contain the binary + // The installer binary on macOS and Windows does not contain the binary // content, it's put into the resources folder as separate file. // Adjust the actual binary path. No error checking here since we // will fail later while reading the binary content. QDir resourcePath(QFileInfo(binaryFile).dir()); -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS resourcePath.cdUp(); resourcePath.cd(QLatin1String("Resources")); #endif @@ -116,7 +116,7 @@ public: QString bundlePath; if (QInstaller::isInBundle(fi.absoluteFilePath(), &bundlePath)) fi.setFile(bundlePath); -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS return fi.absoluteDir().filePath(fi.baseName() + QLatin1String(".dat")); #else return fi.absoluteDir().filePath(qApp->applicationName() + QLatin1String(".dat")); diff --git a/tests/auto/installer/settings/tst_settings.cpp b/tests/auto/installer/settings/tst_settings.cpp index 0edf3fd7b..ab8611e12 100644 --- a/tests/auto/installer/settings/tst_settings.cpp +++ b/tests/auto/installer/settings/tst_settings.cpp @@ -49,7 +49,7 @@ void tst_Settings::loadTutorialConfig() QCOMPARE(settings.installerApplicationIcon(), QLatin1String(":/installer.ico")); QCOMPARE(settings.installerWindowIcon(), QLatin1String(":/installer.ico")); QCOMPARE(settings.systemIconSuffix(), QLatin1String(".ico")); -#elif defined(Q_OS_OSX) +#elif defined(Q_OS_MACOS) QCOMPARE(settings.installerApplicationIcon(), QLatin1String(":/installer.icns")); QCOMPARE(settings.installerWindowIcon(), QLatin1String(":/installer.icns")); QCOMPARE(settings.systemIconSuffix(), QLatin1String(".icns")); diff --git a/tools/binarycreator/binarycreator.cpp b/tools/binarycreator/binarycreator.cpp index 257fc22fe..f9a8f31d4 100644 --- a/tools/binarycreator/binarycreator.cpp +++ b/tools/binarycreator/binarycreator.cpp @@ -263,7 +263,7 @@ static QVersionNumber readMachOMinimumSystemVersion(QIODevice *device) static int assemble(Input input, const QInstaller::Settings &settings, const QString &signingIdentity) { -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS if (QInstaller::isInBundle(input.installerExePath)) { const QString bundle = input.installerExePath; // if the input file was a bundle @@ -394,7 +394,7 @@ static int assemble(Input input, const QInstaller::Settings &settings, const QSt // no error handling as this is not fatal setApplicationIcon(tempFile, settings.installerApplicationIcon()); } -#elif defined(Q_OS_OSX) +#elif defined(Q_OS_MACOS) if (isBundle) { // no error handling as this is not fatal const QString copyscript = QDir::temp().absoluteFilePath(QLatin1String("copylibsintobundle.sh")); @@ -411,7 +411,7 @@ static int assemble(Input input, const QInstaller::Settings &settings, const QSt QTemporaryFile out; QString targetName = input.outputPath; -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS QDir resourcePath(QFileInfo(input.outputPath).dir()); resourcePath.cdUp(); resourcePath.cd(QLatin1String("Resources")); @@ -432,7 +432,7 @@ static int assemble(Input input, const QInstaller::Settings &settings, const QSt QInstaller::openForWrite(&out); QFile exe(input.installerExePath); -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS if (!exe.copy(input.outputPath)) { throw Error(QString::fromLatin1("Cannot copy %1 to %2: %3").arg(exe.fileName(), input.outputPath, exe.errorString())); @@ -477,7 +477,7 @@ static int assemble(Input input, const QInstaller::Settings &settings, const QSt #endif QFile::remove(tempFile); -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS if (isBundle && !signingIdentity.isEmpty()) { qDebug() << "Signing .app bundle..."; @@ -660,7 +660,7 @@ static void printUsage() std::cout << " -rcc|--compile-resource Compiles the default resource and outputs the result into" << std::endl; std::cout << " 'update.rcc' in the current path." << std::endl; -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS std::cout << " -s|--sign identity Sign generated app bundle using the given code " << std::endl; std::cout << " signing identity" << std::endl; #endif @@ -718,7 +718,7 @@ void copyConfigData(const QString &configFile, const QString &targetDir) QString targetFile; QFileInfo elementFileInfo; if (tagName == QLatin1String("Icon") || tagName == QLatin1String("InstallerApplicationIcon")) { -#if defined(Q_OS_OSX) +#if defined(Q_OS_MACOS) const QString suffix = QLatin1String(".icns"); #elif defined(Q_OS_WIN) const QString suffix = QLatin1String(".ico"); @@ -885,7 +885,7 @@ int main(int argc, char **argv) continue; } else if (*it == QLatin1String("-rcc") || *it == QLatin1String("--compile-resource")) { compileResource = true; -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS } else if (*it == QLatin1String("-s") || *it == QLatin1String("--sign")) { ++it; if (it == args.end() || it->startsWith(QLatin1String("-"))) @@ -986,7 +986,7 @@ int main(int argc, char **argv) confInternal.setValue(QLatin1String("offlineOnly"), offlineOnly); } -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS // on mac, we enforce building a bundle if (!target.endsWith(QLatin1String(".app")) && !target.endsWith(QLatin1String(".dmg"))) target += QLatin1String(".app"); diff --git a/tools/binarycreator/resources/copylibsintobundle.sh b/tools/binarycreator/resources/copylibsintobundle.sh index c6765364e..1ad5da4db 100644 --- a/tools/binarycreator/resources/copylibsintobundle.sh +++ b/tools/binarycreator/resources/copylibsintobundle.sh @@ -71,7 +71,7 @@ function handleFile() if [ `basename $FILE` != $NAME ]; then - # this part handles libraries which are Mac OS X frameworks + # this part handles libraries which are macOS frameworks if echo $lib | grep '\.framework' >/dev/null; then local FRAMEWORKPATH=`echo $lib | sed -ne 's,\(.*\.framework\).*,\1,p'` local FRAMEWORKNAME=`basename $FRAMEWORKPATH` diff --git a/tools/devtool/binaryreplace.cpp b/tools/devtool/binaryreplace.cpp index 7497f2199..97dac37d2 100644 --- a/tools/devtool/binaryreplace.cpp +++ b/tools/devtool/binaryreplace.cpp @@ -99,7 +99,7 @@ int BinaryReplace::replace(const QString &source, const QString &target) result = EXIT_FAILURE; try { QFile installerBaseNew(newInstallerBasePath); -#ifndef Q_OS_OSX +#ifndef Q_OS_MACOS QFile installerBaseOld(target); QInstaller::openForAppend(&installerBaseNew); diff --git a/tools/devtool/main.cpp b/tools/devtool/main.cpp index d75ab4e81..dbe8f2b09 100644 --- a/tools/devtool/main.cpp +++ b/tools/devtool/main.cpp @@ -168,7 +168,7 @@ int main(int argc, char *argv[]) if (QInstaller::isInBundle(path, &bundlePath)) { path = QDir(bundlePath).filePath(QLatin1String("Contents/Resources/installer.dat")); } -#ifndef Q_OS_OSX +#ifndef Q_OS_MACOS QFileInfo fi = QFileInfo(path); bundlePath = path; QString tmp = QDir(fi.path()).filePath(QLatin1String("installer.dat")); -- cgit v1.2.3