1
0

Makefile 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include ${TOPDIR}/rules.mk
  4. PKG_NAME:= tntnet
  5. PKG_VERSION:= 1.6.4
  6. PKG_RELEASE:= 1
  7. PKG_MD5SUM:= e2c3c5075a890711a7569730493c0996
  8. PKG_DESCR:= small C++ application server
  9. PKG_SECTION:= www
  10. PKG_DEPENDS:= cxxtools zlib libiconv libpthread
  11. PKG_BUILDDEP+= cxxtools zlib libiconv
  12. ifneq (${ADK_COMPILE_TNTNET_WITH_OPENSSL},)
  13. PKG_BUILDDEP+= openssl
  14. else ifneq (${ADK_COMPILE_TNTNET_WITH_GNUTLS},)
  15. PKG_BUILDDEP+= gnutls
  16. endif
  17. PKG_URL:= http://www.tntnet.org
  18. PKG_SITES:= http://www.tntnet.org/download/
  19. #PKG_CXX:= TNTNET
  20. include ${TOPDIR}/mk/package.mk
  21. ifneq (${ADK_COMPILE_TNTNET_WITH_OPENSSL},)
  22. PKG_DEPENDS+= libopenssl
  23. else ifneq (${ADK_COMPILE_TNTNET_WITH_GNUTLS},)
  24. PKG_DEPENDS+= libgnutls
  25. endif
  26. $(eval $(call PKG_template,TNTNET,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  27. ifeq (${ADK_COMPILE_TNTNET_WITH_UCLIBCXX},y)
  28. TCXXFLAGS+= -fno-builtin -nostdinc++ -nodefaultlibs -I${STAGING_DIR}/usr/include/uClibc++ -Wl,-E
  29. TLDFLAGS+= -nodefaultlibs -luClibc++ -liconv -lpthread -lcxxtools -lm -ldl
  30. else
  31. TLDFLAGS+= -liconv -lpthread -lcxxtools -lm -ldl
  32. endif
  33. CONFIGURE_ARGS+= --without-epoll \
  34. --without-sdk \
  35. --without-cgi \
  36. --without-sendfile
  37. ifeq (${ADK_COMPILE_TNTNET_WITH_OPENSSL},y)
  38. CONFIGURE_ARGS+= --with-ssl=openssl
  39. else ifeq (${ADK_COMPILE_TNTNET_WITH_GNUTLS},y)
  40. CONFIGURE_ARGS+= --with-ssl=gnutls
  41. else
  42. CONFIGURE_ARGS+= --without-ssl
  43. endif
  44. CONFIGURE_ENV+= CXXFLAGS='${TCXXFLAGS}' \
  45. ac_cv_path_cxxtools_config=${STAGING_DIR}/usr/bin
  46. #ifeq (${ADK_COMPILE_TNTNET_WITH_UCLIBCXX},y)
  47. # add workaround because libtool tries to link libstdc++
  48. #post-configure:
  49. # ${SED} 's#postdeps="-lstdc.*#postdeps="-lm"#' \
  50. # ${WRKBUILD}/libtool
  51. #endif
  52. post-install:
  53. ${INSTALL_DIR} ${IDIR_TNTNET}/www
  54. ${INSTALL_DIR} ${IDIR_TNTNET}/etc/tntnet
  55. ${INSTALL_DIR} ${IDIR_TNTNET}/usr/bin
  56. ${INSTALL_DIR} ${IDIR_TNTNET}/usr/lib/tntnet
  57. ${INSTALL_DATA} ./files/tntnet.{conf,properties} \
  58. ${IDIR_TNTNET}/etc/tntnet
  59. ${INSTALL_DATA} ./files/mime.conf \
  60. ${IDIR_TNTNET}/etc/tntnet
  61. ${CP} ${WRKINST}/usr/bin/tntnet ${IDIR_TNTNET}/usr/bin
  62. ${CP} ${WRKINST}/usr/lib/tntnet/tntnet.so* \
  63. ${IDIR_TNTNET}/usr/lib/tntnet
  64. ${CP} ${WRKINST}/usr/lib/libtntnet.so.* \
  65. ${IDIR_TNTNET}/usr/lib
  66. include ${TOPDIR}/mk/pkg-bottom.mk