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.

58 lines
1.8 KiB

  1. #
  2. # Copyright (C) 2013 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:=libhttp-parser
  9. PKG_VERSION:=2.9.2
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=https://codeload.github.com/nodejs/http-parser/tar.gz/v$(PKG_VERSION)?
  13. PKG_HASH:=5199500e352584852c95c13423edc5f0cb329297c81dd69c3c8f52a75496da08
  14. PKG_BUILD_DIR:=$(BUILD_DIR)/http-parser-$(PKG_VERSION)
  15. PKG_MAINTAINER:=Ramanathan Sivagurunathan <ramzthecoder@gmail.com>, Hirokazu MORIKAWA <morikw2@gmail.com>
  16. PKG_LICENSE:=MIT
  17. PKG_LICENSE_FILES:=LICENSE-MIT
  18. PKG_BUILD_PARALLEL:=1
  19. PKG_INSTALL:=1
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/libhttp-parser
  22. SECTION:=libs
  23. CATEGORY:=Libraries
  24. TITLE:=A library to parse http request and response
  25. URL:=https://github.com/nodejs/http-parser
  26. endef
  27. define Package/libhttp-parser/description
  28. A parser for HTTP messages written in C. It parses both requests and responses.
  29. The parser is designed to be used in performance HTTP applications.
  30. It does not make any syscalls nor allocations, it does not buffer data,
  31. it can be interrupted at anytime. Depending on your architecture,
  32. it only requires about 40 bytes of data per message stream
  33. (in a web server that is per connection).
  34. endef
  35. MAKE_FLAGS+=library
  36. define Build/InstallDev
  37. $(INSTALL_DIR) $(1)/usr/include
  38. $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/local/include/http_parser.h $(1)/usr/include/
  39. $(INSTALL_DIR) $(1)/usr/lib
  40. $(CP) $(PKG_INSTALL_DIR)/usr/local/lib/libhttp_parser.so* $(1)/usr/lib/
  41. endef
  42. define Package/libhttp-parser/install
  43. $(INSTALL_DIR) $(1)/usr/lib
  44. $(CP) $(PKG_INSTALL_DIR)/usr/local/lib/libhttp_parser.so* $(1)/usr/lib/
  45. endef
  46. $(eval $(call BuildPackage,libhttp-parser))