]> git.sesse.net Git - vlc/blob - contrib/src/upnp/rules.mak
contrib: run $(RECONF) in an arbitrary list of packages
[vlc] / contrib / src / upnp / rules.mak
1 # UPNP
2 UPNP_VERSION := 1.6.14
3 UPNP_URL := $(SF)/pupnp/libupnp-$(UPNP_VERSION).tar.bz2
4
5 PKGS += upnp
6
7 $(TARBALLS)/libupnp-$(UPNP_VERSION).tar.bz2:
8         $(call download,$(UPNP_URL))
9
10 .sum-upnp: libupnp-$(UPNP_VERSION).tar.bz2
11
12 ifdef HAVE_WIN32
13 DEPS_upnp += pthreads $(DEPS_pthreads)
14 LIBUPNP_ECFLAGS = -DPTW32_STATIC_LIB
15 endif
16
17 upnp: libupnp-$(UPNP_VERSION).tar.bz2 .sum-upnp
18         $(UNPACK)
19 ifdef HAVE_WIN32
20         $(APPLY) $(SRC)/upnp/libupnp-configure.patch
21         $(APPLY) $(SRC)/upnp/libupnp-win32.patch
22         $(APPLY) $(SRC)/upnp/libupnp-win64.patch
23 endif
24         $(MOVE)
25
26 .upnp: upnp
27         $(RECONF)
28         cd $< && $(HOSTVARS) CFLAGS="$(CFLAGS) -O3 -DUPNP_STATIC_LIB $(LIBUPNP_ECFLAGS)" ./configure --disable-samples --without-documentation --disable-webserver $(HOSTCONF)
29         cd $< && $(MAKE) install
30         touch $@