Makefile 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. # $OpenBSD: Makefile,v 1.56 2016/11/19 15:28:40 sthen Exp $
  2. BROKEN = pkg_add fails: problem with symlinks
  3. COMMENT = GNU system administration tool for networks
  4. DISTNAME = cfengine-3.7.2
  5. SHARED_LIBS += promises 0.0 # 1.0
  6. CATEGORIES = sysutils
  7. HOMEPAGE = http://cfengine.com/
  8. MAINTAINER = Rodrigo Mosconi <openbsd@mosconi.mat.br>
  9. # GPLv3 only
  10. PERMIT_PACKAGE_CDROM = Yes
  11. WANTLIB += c crypto iconv lzma m pam pcre pthread ssl qdbm xml2 z
  12. MASTER_SITES = https://cfengine-package-repos.s3.amazonaws.com/tarballs/
  13. CFENGINE_BASE = /var/cfengine
  14. CFENGINE_EXAMPLES = ${PREFIX}/share/examples/cfengine
  15. SUBST_VARS += CFENGINE_BASE CFENGINE_EXAMPLES
  16. FLAVORS = pgsql mysql
  17. FLAVOR ?=
  18. SEPARATE_BUILD = Yes
  19. CONFIGURE_STYLE = gnu
  20. USE_GMAKE = Yes
  21. LIB_DEPENDS = converters/libiconv \
  22. databases/qdbm \
  23. devel/pcre \
  24. security/openpam \
  25. textproc/libxml
  26. CONFIGURE_ENV += CPPFLAGS="-I${LOCALBASE}/include" \
  27. LDFLAGS="-L${LOCALBASE}/lib"
  28. CONFIGURE_ARGS = --with-openssl=/usr \
  29. --without-libacl \
  30. --without-libvirt \
  31. --with-libxml2 \
  32. --without-libyaml \
  33. --without-lmdb \
  34. --with-pam \
  35. --with-pcre \
  36. --with-qdbm \
  37. --without-tokyocabinet \
  38. --disable-fhs \
  39. --with-workdir=${CFENGINE_BASE}
  40. MAKE_FLAGS += examplesdir="${CFENGINE_EXAMPLES}" \
  41. masterfilesdir="${CFENGINE_EXAMPLES}/CoreBase"
  42. .if ${FLAVOR:Mpgsql}
  43. WANTLIB += pq
  44. CONFIGURE_ARGS += --with-postgresql
  45. LIB_DEPENDS += databases/postgresql
  46. .else
  47. CONFIGURE_ARGS += --without-postgresql
  48. .endif
  49. .if ${FLAVOR:Mmysql}
  50. WANTLIB += mysqlclient_r
  51. CONFIGURE_ARGS += --with-mysql
  52. LIB_DEPENDS += databases/mariadb
  53. .else
  54. CONFIGURE_ARGS += --without-mysql
  55. .endif
  56. # tests not yet working
  57. NO_TEST = Yes
  58. # also note some formatting errors with manpages (e.g. "You can think
  59. # of.B cfengine as..." and poor formatting in INFORMATION sections;
  60. # these are present with either mandoc or groff.
  61. post-extract:
  62. perl -i -pe \
  63. 's|^sbin_PROGRAMS.*rpmvercmp||;' \
  64. ${WRKDIST}/ext/Makefile.in
  65. post-install:
  66. ${INSTALL_PROGRAM_DIR} ${WRKINST}${CFENGINE_BASE}/bin
  67. .for i in cf-agent cf-execd cf-key cf-monitord cf-promises cf-upgrade \
  68. cf-runagent cf-serverd
  69. ln -s ${TRUEPREFIX}/bin/$i ${WRKINST}${CFENGINE_BASE}/bin/
  70. .endfor
  71. .include <bsd.port.mk>