lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 1 | |
| 2 | include $(COMMON_BASE_MK) |
| 3 | |
| 4 | NAME=expat |
| 5 | SRC_DIR=expat-2.1.0 |
| 6 | SRC_TAR=expat-2.1.0.tar.gz |
| 7 | INSTALL_DIR=$(LIB_DIR)/$(NAME)/install |
| 8 | BUILD_DIR=build |
| 9 | GEN_MAKEFILE=$(SRC_DIR)/Makefile |
| 10 | |
| 11 | CONFIG_OPTS = --target=arm-buildroot-linux --host=arm-buildroot-linux --build=x86_64-unknown-linux-gnu |
| 12 | #CONFIG_OPTS += --exec-prefix=$(INSTALL_DIR)/usr |
| 13 | #CONFIG_OPTS += --sysconfdir=$(INSTALL_DIR)/etc |
| 14 | #CONFIG_OPTS += --localstatedir=/var |
| 15 | #CONFIG_OPTS += --program-prefix= |
| 16 | CONFIG_OPTS += --disable-gtk-doc |
| 17 | CONFIG_OPTS += --disable-gtk-doc-html |
| 18 | CONFIG_OPTS += --disable-doc |
| 19 | CONFIG_OPTS += --disable-docs |
| 20 | CONFIG_OPTS += --disable-documentation |
| 21 | CONFIG_OPTS += --with-xmlto=no |
| 22 | CONFIG_OPTS += --with-fop=no |
| 23 | CONFIG_OPTS += --disable-dependency-tracking |
| 24 | CONFIG_OPTS += --enable-ipv6 |
| 25 | CONFIG_OPTS += --disable-nls |
| 26 | CONFIG_OPTS += --enable-static |
| 27 | CONFIG_OPTS += --enable-shared |
| 28 | |
| 29 | |
| 30 | export ac_cv_have_abstract_sockets=yes |
| 31 | |
| 32 | export CFLAGS := |
| 33 | export LDFLAGS := |
| 34 | |
| 35 | all: $(GEN_MAKEFILE) |
| 36 | make -C $(SRC_DIR) all |
| 37 | make -C $(SRC_DIR) install |
| 38 | |
| 39 | $(GEN_MAKEFILE): |
| 40 | mkdir -p $(BUILD_DIR) |
| 41 | sha256sum -c $(NAME).sig |
| 42 | tar xf $(TOPDIR_AP)/downloads/$(SRC_TAR) |
| 43 | cd $(SRC_DIR); ./configure --prefix=$(INSTALL_DIR) $(CONFIG_OPTS) |
| 44 | |
| 45 | clean: |
| 46 | -make -C $(SRC_DIR) distclean |
| 47 | -rm -fr $(BUILD_DIR) $(INSTALL_DIR) $(SRC_DIR) |
| 48 | |
| 49 | romfs: |
| 50 | cd $(INSTALL_DIR)/lib; \ |
| 51 | for i in *.so*; do \ |
| 52 | if [ -L $$i ]; then \ |
| 53 | $(ROMFSINST) -s `find $$i -printf %l` /lib/$$i; \ |
| 54 | elif [ -f $$i ]; then \ |
| 55 | $(ROMFSINST) /lib/$$i; \ |
| 56 | fi; \ |
| 57 | done |
| 58 | |
| 59 | populate_sdk: |
| 60 | cp -afvp $(INSTALL_DIR)/include/* $(CROSS_COMPILE_SYSROOT)/usr/include/ |
| 61 | cp -afvp $(INSTALL_DIR)/lib/* $(CROSS_COMPILE_SYSROOT)/usr/lib/ |
| 62 | cp -afvp $(INSTALL_DIR)/bin/* $(CROSS_COMPILE_SYSROOT)/usr/bin/ |
| 63 | |