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.

89 lines
2.3 KiB

  1. #
  2. # Copyright (C) 2007-2016 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:=libzdb
  9. PKG_VERSION:=3.1
  10. PKG_RELEASE:=3
  11. PKG_LICENSE:=GPL-3.0
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  13. PKG_SOURCE_URL:=http://www.tildeslash.com/libzdb/dist/
  14. PKG_MD5SUM:=01d8519a596d62f6b43559cc29ecd36d
  15. PKG_FIXUP:=autoreconf
  16. PKG_INSTALL:=1
  17. PKG_BUILD_DEPENDS:=libzdb/host
  18. include $(INCLUDE_DIR)/package.mk
  19. define Package/libzdb
  20. SECTION:=libs
  21. CATEGORY:=Libraries
  22. TITLE:=A thread-safe multi database connection pool library
  23. MAINTAINER:=Gergely Kiss <mail.gery@gmail.com>
  24. URL:=http://www.tildeslash.com/libzdb/
  25. DEPENDS:=+libsqlite3 +libpq +libmysqlclient +zlib +libpthread +libopenssl
  26. endef
  27. define Package/libzdb/description
  28. zdb is a database library with thread-safe connection pooling. The library can connect
  29. transparently to multiple database systems. It has zero runtime configuration and connections
  30. are specified via a URL scheme. A modern object-oriented API is provided.
  31. zdb supports MySQL, PostgreSQL, SQLite, and Oracle.
  32. NOTE: This package does not include Oracle support.
  33. endef
  34. CONFIGURE_ARGS += --disable-profiling \
  35. --enable-optimized \
  36. --with-mysql \
  37. --with-postgresql \
  38. --with-sqlite \
  39. --enable-sqliteunlock \
  40. --enable-openssl
  41. TARGET_CPPFLAGS += -std=c99
  42. include $(INCLUDE_DIR)/host-build.mk
  43. define Hooks/HostConfigure/Pre
  44. endef
  45. define Host/Configure
  46. endef
  47. define Host/Compile
  48. $(HOSTCC) $(HOST_BUILD_DIR)/tools/filterh/lex.yy.c -o $(HOST_BUILD_DIR)/tools/bin/filterh
  49. endef
  50. define Host/Install
  51. $(INSTALL_DIR) $(STAGING_DIR_HOSTPKG)/bin
  52. $(CP) $(HOST_BUILD_DIR)/tools/bin/filterh $(STAGING_DIR_HOSTPKG)/bin/
  53. endef
  54. $(eval $(call HostBuild))
  55. define Build/Compile
  56. $(call Build/Compile/Default)
  57. endef
  58. define Build/InstallDev
  59. $(INSTALL_DIR) $(1)/usr/include/zdb
  60. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  61. $(CP) $(PKG_INSTALL_DIR)/usr/include/zdb/ $(1)/usr/include/
  62. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libzdb* $(1)/usr/lib/
  63. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/zdb.pc $(1)/usr/lib/pkgconfig
  64. endef
  65. define Package/libzdb/install
  66. $(INSTALL_DIR) $(1)/usr/lib
  67. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libzdb.so* $(1)/usr/lib/
  68. endef
  69. $(eval $(call BuildPackage,libzdb))