update to pupnp 1.6.3 closes #2576
[openwrt/svn-archive/archive.git] / libs / libupnp / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=libupnp
12 PKG_VERSION:=1.6.3
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=@SF/pupnp
17 PKG_MD5SUM:=553f3491fe4da88aba1763497730e2c0
18
19 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
20 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/libupnp
25 SECTION:=libs
26 CATEGORY:=Libraries
27 DEPENDS:=+libpthread
28 TITLE:=A Portable Open Source UPnP Development Kit
29 URL:=http://pupnp.sourceforge.net/
30 endef
31
32 define Package/libupnp/description
33 The portable SDK for UPnP Devices (libupnp) provides developers with an
34 API and open source code for building control points, devices, and
35 bridges that are compliant with Version 1.0 of the Universal Plug and
36 Play Device Architecture Specification and support several operating
37 systems like Linux, *BSD, Solaris and others.
38 endef
39
40 define Build/Configure
41 $(call Build/Configure/Default, \
42 --enable-shared \
43 --enable-static \
44 );
45 endef
46
47 define Build/Compile
48 $(MAKE) -C $(PKG_BUILD_DIR) \
49 CCOPT="$(TARGET_CFLAGS)" \
50 DESTDIR="$(PKG_INSTALL_DIR)" \
51 all install
52 endef
53
54 define Build/InstallDev
55 mkdir -p $(1)/usr/include
56 $(CP) $(PKG_INSTALL_DIR)/usr/include/upnp $(1)/usr/include/
57 mkdir -p $(1)/usr/lib
58 $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{ixml,threadutil,upnp}.{a,so*} $(1)/usr/lib/
59 mkdir -p $(1)/usr/lib/pkgconfig
60 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libupnp.pc $(1)/usr/lib/pkgconfig/
61 endef
62
63 define Package/libupnp/install
64 $(INSTALL_DIR) $(1)/usr/lib
65 $(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{ixml,threadutil,upnp}.so.* $(1)/usr/lib/
66 endef
67
68 $(eval $(call BuildPackage,libupnp))