Commit 023049e3 authored by Martin Storsjö's avatar Martin Storsjö Committed by Rafaël Carré

contrib: zlib: Set the CHOST variable

This fixes cross compilation from OS X.
Modified-by: default avatarRafaël Carré <funman@videolan.org>
Signed-off-by: default avatarRafaël Carré <funman@videolan.org>
parent dce9f3d2
......@@ -7,6 +7,12 @@ ifeq ($(call need_pkg,"zlib"),)
PKGS_FOUND += zlib
endif
ifeq ($(shell uname),Darwin) # zlib tries to use libtool on Darwin
ifdef HAVE_CROSS_COMPILE
ZLIB_CONFIG_VARS=CHOST=$(HOST)
endif
endif
$(TARBALLS)/zlib-$(ZLIB_VERSION).tar.gz:
$(call download,$(ZLIB_URL))
......@@ -18,6 +24,6 @@ zlib: zlib-$(ZLIB_VERSION).tar.gz .sum-zlib
$(MOVE)
.zlib: zlib
cd $< && $(HOSTVARS) ./configure --prefix=$(PREFIX) --static
cd $< && $(HOSTVARS) $(ZLIB_CONFIG_VARS) ./configure --prefix=$(PREFIX) --static
cd $< && $(MAKE) install
touch $@
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment