You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

59 lines
1.7 KiB

  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. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=libuv
  9. PKG_VERSION:=1.41.1
  10. PKG_RELEASE:=$(AUTORELEASE)
  11. PKG_SOURCE:=$(PKG_NAME)-v$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=http://dist.libuv.org/dist/v$(PKG_VERSION)/
  13. PKG_HASH:=65db0c7f2438bc8cd48865de282bf6670027f3557d6e3cb62fb65b2e350a687d
  14. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-v$(PKG_VERSION)
  15. PKG_MAINTAINER:=Marko Ratkaj <marko.ratkaj@sartura.hr>
  16. PKG_LICENSE:=MIT
  17. PKG_LICENSE_FILES:=LICENSE
  18. PKG_CPE_ID:=cpe:/a:libuv_project:libuv
  19. CMAKE_BINARY_SUBDIR:=out/cmake
  20. include $(INCLUDE_DIR)/package.mk
  21. include $(INCLUDE_DIR)/cmake.mk
  22. define Package/libuv
  23. SECTION:=libs
  24. CATEGORY:=Libraries
  25. TITLE:=Cross-platform asychronous I/O library
  26. URL:=https://libuv.org/
  27. DEPENDS:=+libpthread +librt
  28. ABI_VERSION:=1
  29. endef
  30. define Package/libuv/description
  31. libuv is a multi-platform support library with a focus on asynchronous I/O. It
  32. was primarily developed for use by Node.js, but it's also used by Luvit, Julia,
  33. pyuv, and others.
  34. endef
  35. CMAKE_OPTIONS += -DBUILD_TESTING=OFF
  36. define Build/InstallDev
  37. $(call Build/InstallDev/cmake,$(1))
  38. $(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libuv.pc
  39. $(SED) 's,/usr/lib,$$$${prefix}/lib,g' $(1)/usr/lib/pkgconfig/libuv.pc
  40. $(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/libuv-static.pc
  41. $(SED) 's,/usr/lib,$$$${prefix}/lib,g' $(1)/usr/lib/pkgconfig/libuv-static.pc
  42. endef
  43. define Package/libuv/install
  44. $(INSTALL_DIR) $(1)/usr/lib/
  45. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libuv.so* $(1)/usr/lib/
  46. endef
  47. $(eval $(call BuildPackage,libuv))