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.

51 lines
1.2 KiB

  1. #
  2. # Copyright (C) 2006-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:=libmodbus
  9. PKG_VERSION:=3.0.6
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=http://libmodbus.org/releases
  13. PKG_MD5SUM:=c80f88b6ca19cabc4ceffc195ca07771
  14. PKG_FIXUP:=autoreconf
  15. PKG_INSTALL:=1
  16. include $(INCLUDE_DIR)/package.mk
  17. define Package/libmodbus
  18. SECTION:=libs
  19. CATEGORY:=Libraries
  20. URL:=http://www.libmodbus.org
  21. TITLE:=libmodbus
  22. MAINTAINER:=Michael Heimpold <mhei@heimpold.de>
  23. endef
  24. define Package/libmodbus/description
  25. A Modbus library for Linux, Mac OS X, FreeBSD, QNX and Win32
  26. endef
  27. TARGET_CFLAGS += $(FPIC)
  28. define Build/InstallDev
  29. $(INSTALL_DIR) $(1)/usr/include
  30. $(CP) $(PKG_INSTALL_DIR)/usr/include/modbus $(1)/usr/include/
  31. $(INSTALL_DIR) $(1)/usr/lib
  32. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libmodbus.{so*,la} $(1)/usr/lib/
  33. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  34. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libmodbus.pc $(1)/usr/lib/pkgconfig/
  35. endef
  36. define Package/libmodbus/install
  37. $(INSTALL_DIR) $(1)/usr/lib
  38. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libmodbus.so* $(1)/usr/lib/
  39. endef
  40. $(eval $(call BuildPackage,libmodbus))