Makefile 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. #
  2. # Copyright (C) 2011-2014 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:=jansson
  9. PKG_VERSION:=2.7
  10. PKG_RELEASE:=1
  11. PKG_LICENSE:=MIT
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  13. PKG_SOURCE_URL:=http://www.digip.org/jansson/releases/
  14. PKG_MD5SUM:=3a106a465bbb77637550b422f5b262ef
  15. PKG_INSTALL:=1
  16. PKG_BUILD_PARALLEL:=1
  17. include $(INCLUDE_DIR)/package.mk
  18. define Package/jansson
  19. SECTION:=libs
  20. CATEGORY:=Libraries
  21. TITLE:=Jansson library
  22. URL:=http://www.digip.org/jansson/
  23. MAINTAINER:=Gergely Kiss <mail.gery@gmail.com>
  24. endef
  25. define Package/jansson/description
  26. Jansson is a C library for encoding, decoding and manipulating JSON data
  27. endef
  28. TARGET_CFLAGS += $(FPIC)
  29. TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib -lm
  30. define Build/InstallDev
  31. $(INSTALL_DIR) $(1)/usr/{lib,include}
  32. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  33. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libjansson* $(1)/usr/lib
  34. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* $(1)/usr/lib/pkgconfig
  35. $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
  36. endef
  37. define Package/jansson/install
  38. $(INSTALL_DIR) $(1)/usr/lib
  39. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libjansson*so* $(1)/usr/lib/
  40. endef
  41. $(eval $(call BuildPackage,jansson))