The coreplugin/id.h header is kept for downstream for now.
Change-Id: I8c44590f7b988b3770ecdc177c40783e12353e66
(cherry picked from commit 430a33dcd9)
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Based on change 286266, we can find a correct NDK version for Qt for
Andriod version. This change allows Android plugin to get relevant NDK
information and registers appropriate toolchains and kits settings.
[ChangeLog][Android] Automatically use correct NDK version
corresponding to used Qt version.
Task-number: QTCREATORBUG-23583
Change-Id: Ic6b0d7a1ae8962c075b77498de88e018a008ac3e
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
When changing the Android device settings and pressing "Apply", the
information in the "Qt Versions" tab is no longer correct.
The Abi information is parsed from the mkspec, and that depends on the
NDK setting in the environment.
When the NDK in the device settings changes, it updates the toolchains,
and that triggers a re-validation of the Qt info in
QtOptionsPageWidget::validInformation, but since the Android Qt version
already has tried parsing the mkspec, and got (possibly empty) Abi
information, it never is parsed and updated again.
We need a way to force BaseQtVersion to update these things again.
Fixes: QTCREATORBUG-23095
Change-Id: I9cb55ad1a73db942804637344e4c856c7e95afd3
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
AndroidQtVersion reports as invalid also if NDK or SDK are not
configured, or there are other errors in Devices > Android, so point the
user there.
Fixes: QTCREATORBUG-23058
Change-Id: Ic81d0663552769f78b0121ee3e1ddfc1f6510c11
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
... by a mechanism that doesn't require re-implementation in each
derived class.
A QtVersion's type() is uniquely defined by the supported type of
the factory creating it, so that factory can be found and used
for cloning. Non-base data is copied by a fromMap(toMap()) dance
as done in the project configurations.
As a side-effect, the *QtVersion copy constructors are not used
and not needed anymore.
Change-Id: I3aa5a0fd90a27dd115769e0573647cb5669641a0
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Derived implementation either used that as-is, or used the
result as part of their own operation.
Change-Id: I2817c4e6c6701ae647a70e77382dd30c8ea2bd2f
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
One instance had (base) qt version already at hand, the other was
inside AndroidQtVersion itself.
Also remove the typo in the function name.
Change-Id: I8fb0a1cd11751e4dea1f29a99603ea6b0112c49e
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Use default plus polish afterwards instead.
Change-Id: Ibd137562128445a5bae5aaa4fc5fcce2df6c3e38
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Use two setters, one already pre-existing, to set autodetection
data instead of passing that through the create/contructor chain.
Change-Id: I8f9bdf2f82518aae765327a823bdea44210c2f96
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
The remaining dependency is hacked into QmakeProjectManager
by using a compile time-only dependency on androidconstants.h.
Change-Id: Id78125137bc75c145a072bc753276abbf0029647
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
Instead of using always just the minimum SDK version
we need to differentiate between SDK and NDK version.
Fixes: QTCREATORBUG-21536
Change-Id: I2f99c9d40ab05ccd2a4b8efeb2cd0300ecf0cf3a
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
Fix fallout of this in KitInformation/Kit/KitManager and the wizards.
Change-Id: I5cb88cc381dc04409401909b810940ab6dccf86a
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
Add and implement a method to get the supported target device
types to the BaseQtVersion interface. Implement this for all
Qt versions.
Validate that the Qt version's target device type matches up
with the device type set in the kit and warn on mismatch.
Change-Id: I95da42031022663776afe23a50eae3677bdb1dda
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
Use Core::Id for Feature and QSet<Core::Id> for FeatureSet.
Change-Id: I12341036bd9eaa82589d92bd3f7d21f2e6b737bd
Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
Introduce the class AndroidQmakeBuildConfiguration whose purpose is
to set the environment variable. Modify the Factory to create
buildconfigurations of that type and fix restore/clone to also
take the factories' priorities into account.
Change-Id: Icb377fa9211cd3564c36b60cf7c5f7dd84fcab50
Reviewed-by: BogDan Vatra <bogdan@kde.org>
Mostly done using the following ruby script:
Dir.glob('**/*.cpp').each { |file|
next if file =~ %r{src/shared/qbs|/qmljs/}
s = File.read(file)
s.scan(/^using namespace (.*);$/) {
ns = $1
t = s.gsub(/^(.*)\b#{ns}::((?!Const)[A-Z])/) { |m|
before = $1
char = $2
if before =~ /"|\/\/|\\|using|SIGNAL|SLOT|Q_/
m
else
before + char
end
}
if t != s
puts file
File.open(file, 'w').write(t)
end
}
}
Change-Id: I44745947f315b73f0b983d4362f884580dc2d94b
Reviewed-by: BogDan Vatra <bogdan@kde.org>
Centralize the handling inside a new class ProjectTree.
React to moving focus and remove most special handling.
This properly fixes the linked task.
Task-number: QTCREATORBUG-13357
Change-Id: I6b06aa32b1e4305ec8a6d432857b302585d8734b
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
* Supported variables are %{Qt:version}, %{Qt:type} and %{Qt:mkspec}
* Qt version display names need no longer be unique. This simplifies
the code a bit and makes the Qt versions behave like the Kits do now.
* The default Qt version name now contains %{Qt:version}. The method
to find the default version name no longer takes a Qt version string.
Change-Id: Ibca1e3daffe5a81f3c158e8bbc1779d033b03872
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
- Split up androiddeployqt into two steps: One building the apk,
and one deploying it to the device.
- The build apk step base class AndroidBuildApkStep is ihneritaged by
the qmake specific class QmakeAndroidBuildApkStep.
- The deployment step is still called androiddeployqt
- Move all qmake specific code to the qmakeprojectmanager plguin
- Flip the depencency between the android and qmake plugin, now
the qmake plugin depends on the android plugin, implementing
a interface the android plugin provides.
- Note: This removes the debug deployment for now.
Change-Id: I1c386640159ed14b637668abde8eb3b9009ab803
Reviewed-by: BogDan Vatra <bogdan@kde.org>
Make it possible to create multiple AndroidConfigs so that we can have
a different one in the settings dialog from the global one. Move pretty
much every method from AndroidConfigurations to AndroidConfig, so that
the settings dialog can work with its copy. Also add some additional
logic to the settings page around the java setting. To start the avd
manager we need both a sdk path and a java path. Also do some basic
additional checking of the java path.
Task-number: QTCREATORBUG-7724
Task-number: QTCREATORBUG-10936
Task-number: QTCREATORBUG-10937
Task-number: QTCREATORBUG-11059
Task-number: QTCREATORBUG-11218
Change-Id: I148c69b9c98a8a070d17d9b0e223d01db1750e69
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
ios now uses libQt5Core_iphonesimulator.a and libQt5Core.a for device
and simulator, this changes detects both architectures.
Change-Id: I0e2883c06355eb2b75aeeba4365c8aea14bb8ced
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
The available platforms in the ndk might not be the same as in the sdk.
This patch is renames everything using the ndk platform list to
ndkPlatforms, except the highestAvailablePlatform which wrongly uses
the ndk platform list.
Change-Id: I02d9b68bbc27b0c748281678fe654d5f4244578d
Reviewed-by: BogDan Vatra <bogdan@kde.org>
There are 3 different sdk settings:
- The minimum sdk setting from the AndroidManifest.xml
- The target sdk setting from the AndroidManifest.xml
- The target sdk setting from the project.properties file
The last one is now called buildTargetSDK, since it only affects the
build.
Change-Id: I373d925a45088ff0cf8a8e0b22cf9744e571eeb1
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
The slowness is due to AndroidToolChain::addToEnvironment() being called
a lot on project opening. Thus we need to avoid any file opening or
process on loading.
This patch does 2 things:
a) It removes the call to sdkTargets() which is unneeded. That actually
checks which avds are available.
b) It caches the target sdk inside a named target setting. That means,
we assume that the file does not change behind our backs.
Task-number: QTCREATORBUG-9164
Change-Id: I9287934a0624db0b3e8318b8cf76e605418850c2
Reviewed-by: Aurindam Jana <aurindam.jana@digia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Currently the Android plugin only checks for the linux-x86 prebuilds in the
64-bit Android NDK (and mingw-and-ndk), this means Qt Creator goes bonkers
because it can't find the toolchain and debugger for the kits it
auto-detects/creates.
A work around is to symlink linux-x86_64 to linux-x86 in every toolchain.
Change-Id: I04522b65ef48b6090a9f6925e8e3420ad1d333ee
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
We need to set ANDROID_NDK_PLATFORM in the environment, but doing so is
not really possible on a per project basis. Make the hack in
AndroidQtVersion that sets ANDROID_NDK_PLATFORM safer by checking if the
current project's active target is indeed using a android kit.
Change-Id: Ifcdb07a19708ac6bac5f5a02caa1ff197c0e4d80
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>