aboutsummaryrefslogtreecommitdiff
path: root/emoji/core/build.gradle
blob: a86304dceef77d07de4b657351bbece4c4a37911 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
import static androidx.build.dependencies.DependenciesKt.*
import androidx.build.LibraryGroups
import androidx.build.LibraryVersions
import androidx.build.Publish

plugins {
    id("AndroidXPlugin")
    id("com.android.library")
}

ext {
    fontDir = project(':noto-emoji-compat').projectDir
}

configurations {
    repackage
}

dependencies {
    repackage project(path: ':noto-emoji-compat', configuration: "parser")
    // Wrap the noto-emoji-compat dependency in a FileCollection so that the Android Gradle plugin
    // treats this as local jar and package it inside the aar.
    api files(configurations.repackage)

    api("androidx.core:core:1.1.0-rc01")
    implementation(project(':collection'))

    androidTestImplementation(ANDROIDX_TEST_EXT_JUNIT)
    androidTestImplementation(ANDROIDX_TEST_CORE)
    androidTestImplementation(ANDROIDX_TEST_RUNNER)
    androidTestImplementation(ANDROIDX_TEST_RULES)
    androidTestImplementation(ESPRESSO_CORE, libs.exclude_for_espresso)
    androidTestImplementation(MOCKITO_CORE, libs.exclude_bytebuddy) // DexMaker has it"s own MockMaker
    androidTestImplementation(DEXMAKER_MOCKITO, libs.exclude_bytebuddy) // DexMaker has it"s own MockMaker
    androidTestImplementation project(':internal-testutils')
}

android {
    sourceSets {
        main {
            // We use a non-standard manifest path.
            manifest.srcFile 'AndroidManifest.xml'
            res.srcDirs += 'src/main/res-public'
            resources {
                srcDirs = [fontDir.getAbsolutePath()]
                includes = ["LICENSE_UNICODE", "LICENSE_OFL"]
            }
        }

        androidTest {
            assets {
                srcDirs = [new File(fontDir, "font").getAbsolutePath(),
                           new File(fontDir, "supported-emojis").getAbsolutePath()]
            }
        }
    }
}

androidx {
    name = "Android Emoji Compat"
    publish = Publish.SNAPSHOT_AND_RELEASE
    mavenVersion = LibraryVersions.EMOJI
    mavenGroup = LibraryGroups.EMOJI
    inceptionYear = "2017"
    description = "Core library to enable emoji compatibility in Kitkat and newer devices to avoid the empty emoji characters."

    license {
        name = "SIL Open Font License, Version 1.1"
        url = "http://scripts.sil.org/cms/scripts/page.php?item_id=OFL_web"
    }

    license {
        name = "Unicode, Inc. License"
        url = "http://www.unicode.org/copyright.html#License"
    }
}