Merge pull request #16078 from ja-pa/fix-email
[feed/packages.git] / libs / libuv / Makefile
1 #
2 # Copyright (C) 2015-2017 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=libuv
11 PKG_VERSION:=1.41.1
12 PKG_RELEASE:=$(AUTORELEASE)
13
14 PKG_SOURCE:=$(PKG_NAME)-v$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://dist.libuv.org/dist/v$(PKG_VERSION)/
16 PKG_HASH:=65db0c7f2438bc8cd48865de282bf6670027f3557d6e3cb62fb65b2e350a687d
17 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-v$(PKG_VERSION)
18
19 PKG_MAINTAINER:=Marko Ratkaj <marko.ratkaj@sartura.hr>
20 PKG_LICENSE:=MIT
21 PKG_LICENSE_FILES:=LICENSE
22 PKG_CPE_ID:=cpe:/a:libuv_project:libuv
23
24 CMAKE_BINARY_SUBDIR:=out/cmake
25
26 include $(INCLUDE_DIR)/package.mk
27 include $(INCLUDE_DIR)/cmake.mk
28
29 define Package/libuv
30 SECTION:=libs
31 CATEGORY:=Libraries
32 TITLE:=Cross-platform asychronous I/O library
33 URL:=https://libuv.org/
34 DEPENDS:=+libpthread +librt
35 ABI_VERSION:=1
36 endef
37
38 define Package/libuv/description
39 libuv is a multi-platform support library with a focus on asynchronous I/O. It
40 was primarily developed for use by Node.js, but it's also used by Luvit, Julia,
41 pyuv, and others.
42 endef
43
44 CMAKE_OPTIONS += -DBUILD_TESTING=OFF
45
46 define Build/InstallDev
47 $(call Build/InstallDev/cmake,$(1))
48 $(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libuv.pc
49 $(SED) 's,/usr/lib,$$$${prefix}/lib,g' $(1)/usr/lib/pkgconfig/libuv.pc
50 $(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libuv-static.pc
51 $(SED) 's,/usr/lib,$$$${prefix}/lib,g' $(1)/usr/lib/pkgconfig/libuv-static.pc
52 endef
53
54 define Package/libuv/install
55 $(INSTALL_DIR) $(1)/usr/lib/
56 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libuv.so* $(1)/usr/lib/
57 endef
58
59 $(eval $(call BuildPackage,libuv))