Makefile 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. # $OpenBSD: Makefile,v 1.22 2017/05/09 22:22:36 gsoares Exp $
  2. ONLY_FOR_ARCHS = amd64 i386 powerpc
  3. BROKEN-powerpc = threading issues
  4. COMMENT = Plan 9 from user space
  5. DISTNAME = plan9port-20170505
  6. GH_ACCOUNT = 9fans
  7. GH_PROJECT = plan9port
  8. GH_COMMIT = c976381d67e1c1ff16f155cbcc6c905245d0520f
  9. CATEGORIES = plan9
  10. HOMEPAGE = http://swtch.com/plan9port/
  11. MAINTAINER = Gleydson Soares <gsoares@openbsd.org>
  12. # mostly LPL (see LICENSE)
  13. # certain fonts may NOT be redistributed separately
  14. PERMIT_PACKAGE_CDROM = Yes
  15. WANTLIB = X11 Xext c m pthread util fontconfig freetype z
  16. DISTFILES = ${GH_COMMIT}.tar.gz pgw.tar.bz2:1 \
  17. roget.tar.bz2:0 scat.tgz:1
  18. DIST_SUBDIR = plan9port
  19. MASTER_SITES0 = http://pdos.lcs.mit.edu/~rsc/software/plan9/
  20. MASTER_SITES1 = http://pdos.lcs.mit.edu/~rsc/
  21. BUILD_DEPENDS = archivers/bzip2
  22. RUN_DEPENDS = print/ghostscript/gnu \
  23. print/gv
  24. WRKDIST = ${WRKDIR}/plan9port-${GH_COMMIT}
  25. PLAN9 = ${PREFIX}/plan9
  26. NO_TEST = Yes
  27. SUBST_VARS += CC
  28. post-extract:
  29. cd ${WRKSRC}/dict && tar xjf ${FULLDISTDIR}/pgw.tar.bz2
  30. cd ${WRKSRC}/dict && tar xjf ${FULLDISTDIR}/roget.tar.bz2
  31. cd ${WRKSRC}/sky && tar xzf ${FULLDISTDIR}/scat.tgz
  32. post-patch:
  33. cd ${WRKSRC}/src/libthread && cp Darwin-x86_64-swapcontext.c \
  34. OpenBSD-x86_64.c && cp Darwin-x86_64-asm.s \
  35. OpenBSD-x86_64-asm.S && mv OpenBSD-386-asm.s \
  36. OpenBSD-386-asm.S
  37. find ${WRKSRC} -name .cvsignore -exec rm -f {} \;
  38. cd ${WRKSRC} && rm -rf .hg .hgignore .hgtags .gitignore
  39. pre-configure:
  40. ${SUBST_CMD} ${WRKSRC}/INSTALL ${WRKSRC}/bin/{9c,9l}
  41. do-build:
  42. cd ${WRKSRC} && env CC9="${CC}" CCFLAGS="${CFLAGS}" ./INSTALL -b
  43. do-install:
  44. find ${WRKSRC}/src -name '*.orig' -exec rm -f {} \+
  45. cd ${WRKSRC} && rm *.orig && sed -i 's#/usr/local#${TRUEPREFIX}#' \
  46. `cat lib/moveplan9.files`
  47. ${INSTALL_DATA_DIR} ${PLAN9}
  48. cd ${WRKSRC} && pax -rw . ${PLAN9}
  49. cd ${PREFIX} && ln -s ../plan9/bin/9 bin/9
  50. .include <bsd.port.mk>