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.

68 lines
2.0 KiB

  1. #
  2. # Copyright (C) 2006-2015 OpenWrt.org
  3. # 2014-2015 Vitaly Protsko
  4. #
  5. # This is free software, licensed under the GNU General Public License v2.
  6. # See /LICENSE for more information.
  7. #
  8. include $(TOPDIR)/rules.mk
  9. PKG_NAME:=gammu
  10. PKG_VERSION:=1.40.0
  11. PKG_RELEASE:=1
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  13. PKG_SOURCE_URL:=https://dl.cihar.com/gammu/releases
  14. PKG_HASH:=a760a3520d9f3a16a4ed73cefaabdbd86125bec73c6fa056ca3f0a4be8478dd6
  15. PKG_MAINTAINER:=Vitaly Protsko <villy@sft.ru>
  16. PKG_LICENCE:=GPL-2.0-or-later
  17. PKG_LICENSE_FILES:=COPYING
  18. PKG_BUILD_PARALLEL:=1
  19. CMAKE_INSTALL:=1
  20. include $(INCLUDE_DIR)/package.mk
  21. include $(INCLUDE_DIR)/nls.mk
  22. include $(INCLUDE_DIR)/cmake.mk
  23. define Package/gammu
  24. SECTION:=utils
  25. CATEGORY:=Utilities
  26. TITLE:=Cell phone/modem SMS and control tool
  27. URL:=https://wammu.eu/gammu/
  28. DEPENDS:=+libpthread +libcurl +glib2 $(ICONV_DEPENDS) $(INTL_DEPENDS)
  29. DEPENDS+=+PACKAGE_python:python +PACKAGE_bluez-libs:bluez-libs
  30. DEPENDS+=+PACKAGE_libmariadb:libmariadb +PACKAGE_unixodbc:unixodbc +PACKAGE_libpq:libpq
  31. DEPENDS+=+PACKAGE_libusb-1.0:libusb-1.0
  32. endef
  33. CMAKE_OPTIONS += -DWITH_LibDBI:BOOL=OFF
  34. ifneq ($(INTL_FULL),)
  35. CMAKE_OPTIONS += -DLIBINTL_INCLUDE_DIRS:PATH=$(INTL_PREFIX)/include
  36. CMAKE_OPTIONS += -DLIBINTL_LIBRARIES:STRING=intl
  37. endif
  38. ifneq ($(ICONV_FULL),)
  39. CMAKE_OPTIONS += -DDISABLE_ICONV=OFF
  40. CMAKE_OPTIONS += -DICONV_INCLUDE_DIRS:PATH=$(ICONV_PREFIX)/include
  41. CMAKE_OPTIONS += -DICONV_LIBRARIES:STRING=iconv
  42. endif
  43. define Package/gammu/install
  44. $(INSTALL_DIR) $(1)/usr/bin
  45. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gammu $(1)/usr/bin
  46. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gammu-{smsd,smsd-inject,smsd-monitor} $(1)/usr/bin
  47. $(INSTALL_DIR) $(1)/usr/lib
  48. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/lib{Gammu*,gsmsd*} $(1)/usr/lib
  49. $(INSTALL_DIR) $(1)/etc/init.d
  50. $(INSTALL_DIR) $(1)/etc/config
  51. $(INSTALL_CONF) ./files/gammu $(1)/etc/config/gammu
  52. $(INSTALL_BIN) ./files/gammu.init $(1)/etc/init.d/gammu
  53. endef
  54. define Package/gammu/conffiles
  55. /etc/config/gammu
  56. endef
  57. $(eval $(call BuildPackage,gammu))