2 # Copyright (C) 2015 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=https
://codeload.github.com
/obgm
/libcoap
/tar.gz
/v
$(PKG_VERSION
)?
16 PKG_HASH
:=1a195adacd6188d3b71c476e7b21706fef7f3663ab1fb138652e8da49a9ec556
18 PKG_MAINTAINER
:=Anton Glukhov
<anton.a.glukhov@gmail.com
>
19 PKG_LICENSE
:=GPL-2.0
-or-later BSD-2-Clause
20 PKG_LICENSE_FILES
:=COPYING LICENSE.GPL LICENSE.BSD
21 PKG_CPE_ID
:=cpe
:/a
:libcoap
:libcoap
27 include $(INCLUDE_DIR
)/package.mk
29 define Package
/libcoap
32 TITLE
:=CoAP
(RFC
7252) library
33 URL
:=https
://libcoap.net
/
37 define Package
/libcoap
/description
38 Constrained Application Protocol
(RFC
7252) library
41 define Package
/coap-client
45 TITLE
:=CoAP
(RFC
7252) client tool
48 define Package
/coap-client
/description
49 Constrained Application Protocol
(RFC7252
) client tool
52 define Package
/coap-server
56 TITLE
:=CoAP
(RFC
7252) server programs
59 define Package
/coap-server
/description
60 Constrained Application Protocol
(RFC
7252) server and resource directory server
63 TARGET_CFLAGS
+= $(FPIC
)
67 --disable-documentation \
73 define Build
/InstallDev
74 $(INSTALL_DIR
) $(1)/usr
/include
75 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/* $(1)/usr
/include/
77 $(INSTALL_DIR
) $(1)/usr
/lib
78 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/* $(1)/usr
/lib
/
81 define Package
/libcoap
/install
82 $(INSTALL_DIR
) $(1)/usr
/lib
83 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libcoap-
$(ABI_VERSION
)*.so
* $(1)/usr
/lib
/
86 define Package
/coap-client
/install
87 $(INSTALL_DIR
) $(1)/usr
/bin
88 $(CP
) $(PKG_INSTALL_DIR
)/usr
/bin
/coap-client
$(1)/usr
/bin
/
91 define Package
/coap-server
/install
92 $(INSTALL_DIR
) $(1)/usr
/bin
93 $(CP
) $(PKG_INSTALL_DIR
)/usr
/bin
/coap-server
$(1)/usr
/bin
/
94 $(CP
) $(PKG_INSTALL_DIR
)/usr
/bin
/coap-rd
$(1)/usr
/bin
/
97 $(eval
$(call BuildPackage
,libcoap
))
98 $(eval
$(call BuildPackage
,coap-client
))
99 $(eval
$(call BuildPackage
,coap-server
))