summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDerek Foreman <derek.foreman@collabora.co.uk>2011-05-13 19:19:51 (GMT)
committerDerek Foreman <derek.foreman@collabora.co.uk>2011-05-13 19:19:51 (GMT)
commit0b860274b116de4e80157b7f346719c8e6e449b2 (patch)
tree65222aba1994c868343814b60a70e93d5582acff
parentb2b850222ac5ad68188d6db2d9ac114674c88ec5 (diff)
downloadlibxml2-0b860274b116de4e80157b7f346719c8e6e449b2.tar.gz
libxml2-0b860274b116de4e80157b7f346719c8e6e449b2.tar.xz
Support building for Android
-rw-r--r--.gitignore1
-rw-r--r--Android.mk31
-rw-r--r--Makefile.am11
3 files changed, 43 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index f9605db..a4d8025 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,6 +1,7 @@
.deps
.libs
.memdump
+xml2.mk
COPYING
Makefile
Makefile.in
diff --git a/Android.mk b/Android.mk
new file mode 100644
index 0000000..3a7e144
--- /dev/null
+++ b/Android.mk
@@ -0,0 +1,31 @@
+LOCAL_PATH:= $(call my-dir)
+
+include $(CLEAR_VARS)
+
+XML2_BUILT_SOURCES := \
+ xml2.mk
+
+xml2-configure-real:
+ cd $(XML2_TOP) ; \
+ CC="$(CONFIGURE_CC)" \
+ CFLAGS="$(CONFIGURE_CFLAGS)" \
+ LD=$(TARGET_LD) \
+ LDFLAGS="$(CONFIGURE_LDFLAGS)" \
+ CPP=$(CONFIGURE_CPP) \
+ CPPFLAGS=$(CONFIGURE_CPPFLAGS) \
+ PKG_CONFIG_LIBDIR="$(CONFIGURE_PKG_CONFIG_LIBDIR)" \
+ PKG_CONFIG_TOP_BUILD_DIR=$(PKG_CONFIG_TOP_BUILD_DIR) \
+ $(XML2_TOP)/$(CONFIGURE) --host=arm-linux-androideabi && \
+ for file in $(XML2_BUILT_SOURCES); do \
+ rm -f $$file && \
+ make -C $$(dirname $$file) $$(basename $$file) ; \
+ done
+
+xml2-configure: xml2-configure-real
+
+.PHONY: xml2-configure
+
+CONFIGURE_TARGETS += xml2-configure
+
+#include all the subdirs...
+-include $(XML2_TOP)/xml2.mk
diff --git a/Makefile.am b/Makefile.am
index b8cbb4a..d823457 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1205,6 +1205,17 @@ EXTRA_DIST = xml2-config.in xml2Conf.sh.in libxml.spec.in libxml2.spec \
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libxml-2.0.pc
+xml2.mk: Makefile.am
+ androgenizer -:PROJECT xml2 -:SHARED xml2 -:TAGS eng debug \
+ -:REL_TOP $(top_srcdir) -:ABS_TOP $(abs_top_srcdir) \
+ -:SOURCES $(libxml2_la_SOURCES) \
+ -:CFLAGS $(DEFS) $(CFLAGS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+ $(libxml2_la_CFLAGS) \
+ -:CPPFLAGS $(CPPFLAGS) $(AM_CPPFLAGS) $(libxml2_la_CPPFLAGS) \
+ -:LDFLAGS $(libxml2_la_LIBADD) \
+ > $@
+
+
#
# Install the tests program sources as examples
#