407a717c6090ab4a8a7357163d9a1dfe5858565b
[feed/packages.git] / libs / libupnp / Makefile
1 include $(TOPDIR)/rules.mk
2
3 PKG_NAME:=libupnp
4 PKG_VERSION:=1.8.4
5 PKG_RELEASE:=2
6
7 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
8 PKG_SOURCE_URL:=@SF/pupnp
9 PKG_HASH:=188d3f786d92fe14191f17634d2d87847eee7d2b568a5257ea23262fec9973d6
10 PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
11
12 PKG_FIXUP:=autoreconf
13 PKG_BUILD_PARALLEL:=1
14 PKG_INSTALL:=1
15
16 include $(INCLUDE_DIR)/package.mk
17
18 define Package/libupnp/Default
19 SECTION:=libs
20 CATEGORY:=Libraries
21 URL:=http://pupnp.sourceforge.net/
22 endef
23
24 define Package/libupnp
25 $(call Package/libupnp/Default)
26 DEPENDS:=+libpthread
27 TITLE:=UPnP SDK library
28 MENU:=1
29 endef
30
31 define Package/libupnp/description
32 The portable SDK for UPnP Devices (libupnp) provides developers with an API and
33 open source code for building control points, devices, and bridges that are
34 compliant with Version 1.0 of the Universal Plug and Play Device Architecture
35 Specification.
36 endef
37
38 define Package/libupnp-sample
39 $(call Package/libupnp/Default)
40 DEPENDS:=libupnp
41 TITLE:=UPnP sample applications
42 endef
43
44 define Package/libupnp-sample/description
45 TVcontrolpoint & tvdevice sample applications run inside /etc/upnp-tvdevice/
46 endef
47
48 TARGET_CFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -flto
49 TARGET_LDFLAGS += -flto
50
51 CONFIGURE_VARS += ac_cv_lib_compat_ftime=no
52
53 define Build/InstallDev
54 $(INSTALL_DIR) $(1)/usr/include
55 $(CP) $(PKG_INSTALL_DIR)/usr/include/upnp $(1)/usr/include/
56 $(INSTALL_DIR) $(1)/usr/lib
57 $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{ixml,upnp}.{a,so*,la} $(1)/usr/lib/
58 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
59 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libupnp.pc $(1)/usr/lib/pkgconfig/
60 endef
61
62 define Package/libupnp/install
63 $(INSTALL_DIR) $(1)/usr/lib
64 $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{ixml,upnp}.so.* $(1)/usr/lib/
65 endef
66
67 define Package/libupnp-sample/install
68 $(INSTALL_DIR) $(1)/usr/bin
69 $(INSTALL_BIN) $(PKG_BUILD_DIR)/upnp/sample/.libs/* $(1)/usr/bin
70 $(INSTALL_DIR) $(1)/etc/upnp-tvdevice/web
71 $(INSTALL_DATA) $(PKG_BUILD_DIR)/upnp/sample/web/* $(1)/etc/upnp-tvdevice
72 endef
73
74 $(eval $(call BuildPackage,libupnp))
75 $(eval $(call BuildPackage,libupnp-sample))