• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1//
2// Copyright (C) 2014 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8//      http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15//
16
17//
18// To update:
19//
20
21//  git merge aosp/upstream-master
22//  mma -j
23//  # (Make any necessary Android.bp changes and test the new libxml2.)
24//  git push aosp HEAD:master  # Push directly, avoiding gerrit.
25//  git push aosp HEAD:refs/for/master  # Push to gerrit.
26//
27//  # Now commit any necessary Android.bp changes like normal:
28//  repo start post-sync .
29//  git commit -a
30//
31
32// This comes from the automake-generated Makefile.
33// We deliberately exclude nanoftp.c and nanohttp.c, the trio library, and zlib.
34cc_library {
35    name: "libxml2",
36    vendor_available: true,
37    vndk: {
38        enabled: true,
39    },
40    host_supported: true,
41    srcs: [
42        "SAX.c",
43        "entities.c",
44        "encoding.c",
45        "error.c",
46        "parserInternals.c",
47        "parser.c",
48        "tree.c",
49        "hash.c",
50        "list.c",
51        "xmlIO.c",
52        "xmlmemory.c",
53        "uri.c",
54        "valid.c",
55        "xlink.c",
56        "debugXML.c",
57        "xpath.c",
58        "xpointer.c",
59        "xinclude.c",
60        "DOCBparser.c",
61        "catalog.c",
62        "globals.c",
63        "threads.c",
64        "c14n.c",
65        "xmlstring.c",
66        "buf.c",
67        "xmlregexp.c",
68        "xmlschemas.c",
69        "xmlschemastypes.c",
70        "xmlunicode.c",
71        "xmlreader.c",
72        "relaxng.c",
73        "dict.c",
74        "SAX2.c",
75        "xmlwriter.c",
76        "legacy.c",
77        "chvalid.c",
78        "pattern.c",
79        "xmlsave.c",
80        "xmlmodule.c",
81        "schematron.c",
82    ],
83    export_include_dirs: ["include"],
84    cflags: [
85        "-DLIBXML_THREAD_ENABLED=1",
86
87        "-Wno-missing-field-initializers",
88        "-Wno-self-assign",
89        "-Wno-sign-compare",
90        "-Wno-tautological-pointer-compare",
91        "-Wno-unused-parameter",
92    ],
93    static: {
94        cflags: ["-fvisibility=hidden"],
95    },
96    target: {
97        host: {
98            host_ldlibs: ["-ldl"],
99        },
100        vendor: {
101            exclude_shared_libs: ["libicuuc"],
102        },
103    },
104    shared_libs: ["libicuuc"],
105    export_shared_lib_headers: ["libicuuc"],
106}
107