diff options
author | Ulf Samuelsson <ulf.samuelsson@atmel.com> | 2007-07-16 20:13:22 +0000 |
---|---|---|
committer | Ulf Samuelsson <ulf.samuelsson@atmel.com> | 2007-07-16 20:13:22 +0000 |
commit | f9a0f110303addb2dce2702cc241a190a0aef724 (patch) | |
tree | 00554726dd1b98b7c66c52333edc3acbd5e6c480 /package | |
parent | 739c51d175bb81204e3b30856bebd9013391b036 (diff) | |
download | buildroot-novena-f9a0f110303addb2dce2702cc241a190a0aef724.tar.gz buildroot-novena-f9a0f110303addb2dce2702cc241a190a0aef724.zip |
Add libxml2 package
Diffstat (limited to 'package')
-rw-r--r-- | package/Config.in | 1 | ||||
-rw-r--r-- | package/libxml2/Config.in | 8 | ||||
-rw-r--r-- | package/libxml2/libxml2.mk | 77 |
3 files changed, 86 insertions, 0 deletions
diff --git a/package/Config.in b/package/Config.in index 2a79a469e..150e0ba8a 100644 --- a/package/Config.in +++ b/package/Config.in @@ -68,6 +68,7 @@ source "package/libevent/Config.in" source "package/libfloat/Config.in" source "package/liblockfile/Config.in" source "package/libsysfs/Config.in" +source "package/libxml2/Config.in" source "package/lockfile-progs/Config.in" source "package/lsof/Config.in" source "package/ltp-testsuite/Config.in" diff --git a/package/libxml2/Config.in b/package/libxml2/Config.in new file mode 100644 index 000000000..cb5c49594 --- /dev/null +++ b/package/libxml2/Config.in @@ -0,0 +1,8 @@ +config BR2_PACKAGE_LIBXML2 + bool "libxml2" + default n + help + XML C Parser + Requires WCHAR + + ftp://xmlsoft.org/libxml2 diff --git a/package/libxml2/libxml2.mk b/package/libxml2/libxml2.mk new file mode 100644 index 000000000..2264e2f81 --- /dev/null +++ b/package/libxml2/libxml2.mk @@ -0,0 +1,77 @@ +############################################################# +# +# libxml2 +# +############################################################# + +LIBXML2_VERSION=2.6.29 +LIBXML2_SOURCE=libxml2-sources-$(LIBXML2_VERSION).tar.gz +LIBXML2_SITE=ftp://xmlsoft.org/libxml2 +LIBXML2_DIR=$(BUILD_DIR)/libxml2-$(LIBXML2_VERSION) +LIBXML2_CAT:=$(ZCAT) + +$(DL_DIR)/$(LIBXML2_SOURCE): + $(WGET) -P $(DL_DIR) $(LIBXML2_SITE)/$(LIBXML2_SOURCE) + +$(LIBXML2_DIR)/.unpacked: $(DL_DIR)/$(LIBXML2_SOURCE) + $(LIBXML2_CAT) $(DL_DIR)/$(LIBXML2_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) - + touch $(LIBXML2_DIR)/.unpacked + +$(LIBXML2_DIR)/.configured: $(LIBXML2_DIR)/.unpacked + (cd $(LIBXML2_DIR); rm -rf config.cache; \ + $(TARGET_CONFIGURE_OPTS) \ + $(TARGET_CONFIGURE_ARGS) \ + ./configure \ + --target=$(GNU_TARGET_NAME) \ + --host=$(GNU_TARGET_NAME) \ + --build=$(GNU_HOST_NAME) \ + --prefix=/usr \ + --sysconfdir=/etc \ + --enable-shared \ + $(DISABLE_NLS) \ + ); + touch $(LIBXML2_DIR)/.configured + +$(LIBXML2_DIR)/libxml2.la: $(LIBXML2_DIR)/.configured + rm -f $@ + $(MAKE) CC=$(TARGET_CC) -C $(LIBXML2_DIR) + +$(STAGING_DIR)/usr/lib/libxml2.so: $(LIBXML2_DIR)/libxml2.la + $(MAKE) DESTDIR=$(STAGING_DIR) -C $(LIBXML2_DIR) install + +$(TARGET_DIR)/usr/lib/libxml2.so: $(STAGING_DIR)/usr/lib/libxml2.so + cp -dpf $(STAGING_DIR)/usr/lib/libxml2.so* $(TARGET_DIR)/usr/lib/ + $(STRIP) --strip-unneeded $(TARGET_DIR)/usr/lib/libxml2.so* + +$(TARGET_DIR)/usr/lib/libxml2.a: $(STAGING_DIR)/usr/lib/libxml2.so + mkdir -p $(TARGET_DIR)/usr/include + cp -dpf $(STAGING_DIR)/usr/lib/libxml2.*a $(TARGET_DIR)/usr/lib/ +# cp -dpf $(STAGING_DIR)/usr/include/mad.h $(TARGET_DIR)/usr/include/ + +libxml2: uclibc $(TARGET_DIR)/usr/lib/libxml2.so + +libxml2-headers: $(TARGET_DIR)/usr/lib/libxml2.a + +libxml2-source: $(DL_DIR)/$(LIBXML2_SOURCE) + +libxml2-clean: + @if [ -d $(LIBXML2_DIR)/Makefile ] ; then \ + $(MAKE) -C $(LIBXML2_DIR) clean ; \ + fi; + rm -f $(STAGING_DIR)/usr/lib/libxml2.* + rm -f $(TARGET_DIR)/usr/lib/libxml2.* + + +libxml2-dirclean: + rm -rf $(LIBXML2_DIR) +############################################################# +# +# Toplevel Makefile options +# +############################################################# +ifeq ($(strip $(BR2_PACKAGE_LIBXML2)),y) +TARGETS+=libxml2 +endif +ifeq ($(strip $(BR2_PACKAGE_LIBXML2_TARGET_HEADERS)),y) +TARGETS+=libxml2-headers +endif |