mirror of
git://code.qt.io/qt/qt5.git
synced 2026-04-24 21:57:45 +08:00
Android:Coin: do gradle build in provisioning to cache downloadables
If Gradle is not present in the system, it's downloaded from the URL from the Gradle wrapper. Also, the same for AGP when an Android project build is done. Currently, that's done on every integration, and that can be unreliable due to networking flakiness. With this patch, a Gradle build is done once during provisioning where the downloads of Gradle and AGP dependencies are downloaded. Fixes: QTQAINFRA-6166 Fixes: QTQAINFRA-4726 Fixes: QTBUG-117203 Fixes: QTBUG-114699 Change-Id: Ic9fd8aeea3379ca1d45ffeb4523a52e2846fcabb Reviewed-by: Dimitrios Apostolou <jimis@qt.io> Reviewed-by: Toni Saario <toni.saario@qt.io>
This commit is contained in:
1
coin/provisioning/common/linux/android/gradle_project/app/.gitignore
vendored
Normal file
1
coin/provisioning/common/linux/android/gradle_project/app/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
/build
|
||||
@@ -0,0 +1,26 @@
|
||||
plugins {
|
||||
alias(libs.plugins.androidApplication)
|
||||
}
|
||||
|
||||
android {
|
||||
namespace 'com.example.gradle_project'
|
||||
compileSdk 34
|
||||
|
||||
defaultConfig {
|
||||
applicationId "com.example.gradle_project"
|
||||
minSdk 23
|
||||
targetSdk 34
|
||||
versionCode 1
|
||||
versionName "1.0"
|
||||
}
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation libs.appcompat
|
||||
implementation libs.material
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools">
|
||||
|
||||
<application
|
||||
android:allowBackup="true"
|
||||
android:label="gradle_project"
|
||||
android:supportsRtl="true"
|
||||
tools:targetApi="34">
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="true">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
</application>
|
||||
|
||||
</manifest>
|
||||
@@ -0,0 +1,16 @@
|
||||
// Copyright (C) 2023 The Qt Company Ltd.
|
||||
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
|
||||
|
||||
package com.example.gradle_project;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
public class MainActivity extends AppCompatActivity {
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_main);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Hello World!"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
Reference in New Issue
Block a user