2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR)/rules.mk
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=@SF/pupnp
17 PKG_MD5SUM:=8918dcf7428cd119d0c8275765ff2833
19 include $(INCLUDE_DIR)/package.mk
21 define Package/libupnp/Default
24 URL:=http://upnp.sourceforge.net/
27 define Package/libupnp
28 $(call Package/libupnp/Default)
30 TITLE:=UPnP SDK library
34 define Package/libupnp/description
35 The portable SDK for UPnP Devices (libupnp) provides developers with an
36 API and open source code for building control points, devices, and
37 bridges that are compliant with Version 1.0 of the Universal Plug and
38 Play Device Architecture Specification and support several operating
39 systems like Linux, *BSD, Solaris and others.
42 define Package/libupnp-sample
43 $(call Package/libupnp/Default)
45 TITLE:=UPnP sample applications
48 define Package/libupnp-sample/description
49 TVcontrolpoint & tvdevice sample applications
50 run inside /etc/upnp-tvdevice/
53 define Build/Configure
54 $(call Build/Configure/Default, \
60 TARGET_CFLAGS += $(FPIC)
63 $(MAKE) -C $(PKG_BUILD_DIR) \
64 CCOPT="$(TARGET_CFLAGS)" \
65 DESTDIR="$(PKG_INSTALL_DIR)" \
67 $(MAKE) -C $(PKG_BUILD_DIR)/upnp/sample/ upnp_tv_device upnp_tv_ctrlpt
70 define Build/Compile/libupnp-sample
71 $(MAKE) -C $(PKG_BUILD_DIR) \
72 CCOPT="$(TARGET_CFLAGS)" \
73 DESTDIR="$(PKG_INSTALL_DIR)" \
77 define Build/InstallDev
78 mkdir -p $(1)/usr/include
79 $(CP) $(PKG_INSTALL_DIR)/usr/include/upnp $(1)/usr/include/
81 $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{ixml,threadutil,upnp}.{a,so*} $(1)/usr/lib/
82 mkdir -p $(1)/usr/lib/pkgconfig
83 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libupnp.pc $(1)/usr/lib/pkgconfig/
86 define Package/libupnp/install
87 $(INSTALL_DIR) $(1)/usr/lib
88 $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{ixml,threadutil,upnp}.so.* $(1)/usr/lib/
91 define Package/libupnp-sample/install
92 $(INSTALL_DIR) $(1)/usr/bin
93 $(INSTALL_BIN) $(PKG_BUILD_DIR)/upnp/sample/upnp_tv_device $(1)/usr/bin
94 $(INSTALL_BIN) $(PKG_BUILD_DIR)/upnp/sample/upnp_tv_ctrlpt $(1)/usr/bin
95 $(INSTALL_DIR) $(1)/etc/upnp-tvdevice/web
96 $(CP) $(PKG_BUILD_DIR)/upnp/sample/web/* $(1)/etc/upnp-tvdevice
99 $(eval $(call BuildPackage,libupnp))
100 $(eval $(call BuildPackage,libupnp-sample))