Makefile 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115
  1. # $OpenBSD: Makefile,v 1.35 2017/04/10 11:46:22 sthen Exp $
  2. COMMENT-main= fully featured POP3 and IMAP4 proxy server
  3. COMMENT-ldap= LDAP backend for perdition mail proxy
  4. COMMENT-mysql= MySQL backend for perdition mail proxy
  5. COMMENT-pgsql= PostgreSQL backend for perdition mail proxy
  6. DISTVER= 2.2
  7. DISTNAME= perdition-${DISTVER}
  8. PKGNAME-main= perdition-${DISTVER:S/-//}
  9. PKGNAME-ldap= perdition-ldap-${DISTVER:S/-//}
  10. PKGNAME-mysql= perdition-mysql-${DISTVER:S/-//}
  11. PKGNAME-pgsql= perdition-pgsql-${DISTVER:S/-//}
  12. CATEGORIES= mail
  13. HOMEPAGE= http://horms.net/projects/perdition/
  14. MAINTAINER= Giovanni Bechis <giovanni@openbsd.org>
  15. SHARED_LIBS += perditiondb_bdb 0.0 # .0.0
  16. SHARED_LIBS += perditiondb_nis 0.0 # .0.0
  17. SHARED_LIBS += perditiondb_posix_regex 0.0 # .0.0
  18. SHARED_LIBS += perditiondb_daemon 0.0 # .0.0
  19. SHARED_LIBS += perditiondb_daemon_base 0.0 # .0.0
  20. SHARED_LIBS += perditiondb_ldap 0.0 # .0.0
  21. SHARED_LIBS += perditiondb_mysql 0.0 # .0.0
  22. SHARED_LIBS += perditiondb_postgresql 0.0 # .0.0
  23. # GPLv2+ (included COPYING is v3, but all files with a
  24. # copyright claim specify version 2 or above).
  25. PERMIT_PACKAGE_CDROM= Yes
  26. MASTER_SITES= ${HOMEPAGE}download/${DISTVER}/
  27. MODULES= devel/gettext
  28. USE_GMAKE= Yes
  29. CONFIGURE_STYLE= gnu
  30. CONFIGURE_ENV+= CPPFLAGS="-I${LOCALBASE}/include -I${LOCALBASE}/include/db4" \
  31. LDFLAGS="-L${LOCALBASE}/lib"
  32. CONFIGURE_ARGS+= --enable-ssl \
  33. --disable-cdb \
  34. --disable-gdbm \
  35. --disable-odbc \
  36. --disable-pam \
  37. --with-ssl-includes=/usr/include \
  38. --with-ssl-libraries=/usr/lib \
  39. --with-user=_perdition \
  40. --with-group=_perdition
  41. PSEUDO_FLAVORS= no_ldap no_mysql no_pgsql
  42. FLAVOR?=
  43. MULTI_PACKAGES= -main -mysql -pgsql -ldap
  44. .include <bsd.port.arch.mk>
  45. cWANTLIB= lib/db4/db>=4 vanessa_logger>=1.0
  46. cLIB_DEPENDS+= databases/db/v4 \
  47. vanessa_logger->=0.0.10:devel/vanessa/logger
  48. WANTLIB-main= ${cWANTLIB} ${MODGETTEXT_WANTLIB} \
  49. c crypto ssl util popt idn \
  50. vanessa_adt>=1.0 vanessa_socket>=1.0
  51. LIB_DEPENDS-main= ${cLIB_DEPENDS} ${LIB_DEPENDS} \
  52. ${MODGETTEXT_LIB_DEPENDS} \
  53. devel/popt devel/libidn \
  54. vanessa_adt->=0.0.9:devel/vanessa/adt \
  55. vanessa_socket->=0.0.12:devel/vanessa/socket
  56. LIB_DEPENDS-ldap= ${cLIB_DEPENDS} security/cyrus-sasl2 \
  57. openldap-client->=2,<3:databases/openldap
  58. WANTLIB-ldap= crypto lber-2.4 ldap-2.4 sasl2 ssl util ${cWANTLIB}
  59. .if !${BUILD_PACKAGES:M-ldap}
  60. CONFIGURE_ARGS+= --disable-ldap
  61. .else
  62. CONFIGURE_ARGS+= --with-ldap-libraries=${LOCALBASE}/lib \
  63. --with-ldap-includes=${LOCALBASE}/include \
  64. --disable-ldap-doc
  65. .endif
  66. LIB_DEPENDS-mysql= ${cLIB_DEPENDS} databases/mariadb \
  67. vanessa_adt->=0.0.9:devel/vanessa/adt
  68. WANTLIB-mysql= crypto pthread ssl ${LIBCXX} util m z \
  69. lib/mysql/mysqlclient ${cWANTLIB} \
  70. vanessa_adt>=1.0
  71. .if !${BUILD_PACKAGES:M-mysql}
  72. CONFIGURE_ARGS+= --disable-mysql
  73. .else
  74. CONFIGURE_ARGS+= --with-mysql-libraries=${LOCALBASE}/lib/mysql \
  75. --with-mysql-includes=${LOCALBASE}/include/mysql
  76. .endif
  77. LIB_DEPENDS-pgsql= ${cLIB_DEPENDS} databases/postgresql \
  78. vanessa_adt->=0.0.9:devel/vanessa/adt
  79. WANTLIB-pgsql= crypto pq ssl util ${cWANTLIB} vanessa_adt>=1.0
  80. .if !${BUILD_PACKAGES:M-pgsql}
  81. CONFIGURE_ARGS+= --disable-pg
  82. .else
  83. CONFIGURE_ARGS+= --enable-pg
  84. .endif
  85. EXAMPLE_DIR= ${PREFIX}/share/examples/perdition/
  86. post-install:
  87. ${INSTALL_DATA_DIR} ${EXAMPLE_DIR}
  88. @mv ${WRKINST}${SYSCONFDIR}/perdition/* ${EXAMPLE_DIR}
  89. .include <bsd.port.mk>