ports/devel/cvs2svn/Makefile
Mathieu Arnold 551be3c723 Convert Python ports to FLAVORS.
Ports using USE_PYTHON=distutils are now flavored.  They will
  automatically get flavors (py27, py34, py35, py36) depending on what
  versions they support.

  There is also a USE_PYTHON=flavors for ports that do not use distutils
  but need FLAVORS to be set.  A USE_PYTHON=noflavors can be set if
  using distutils but flavors are not wanted.

  A new USE_PYTHON=optsuffix that will add PYTHON_PKGNAMESUFFIX has been
  added to cope with Python ports that did not have the Python
  PKGNAMEPREFIX but are flavored.

  USES=python now also exports a PY_FLAVOR variable that contains the
  current python flavor.  It can be used in dependency lines when the
  port itself is not python flavored.  For example, deskutils/calibre.

  By default, all the flavors are generated.  To only generate flavors
  for the versions in PYTHON2_DEFAULT and PYTHON3_DEFAULT, define
  BUILD_DEFAULT_PYTHON_FLAVORS in your make.conf.

  In all the ports with Python dependencies, the *_DEPENDS entries MUST
  end with the flavor so that the framework knows which to build/use.
  This is done by appending '@${PY_FLAVOR}' after the origin (or
  @${FLAVOR} if in a Python module with Python flavors, as the content
  will be the same).  For example:

    RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}six>0:devel/py-six@${PY_FLAVOR}

PR:		223071
Reviewed by:	portmgr, python
Sponsored by:	Absolight
Differential Revision:	https://reviews.freebsd.org/D12464
2017-11-30 15:50:30 +00:00

81 lines
2.2 KiB
Makefile

# Created by: Hye-Shik Chang
# $FreeBSD$
PORTNAME= cvs2svn
PORTVERSION= 2.4.0
PORTREVISION= 5
CATEGORIES= devel
MASTER_SITES= http://cvs2svn.tigris.org/files/documents/1462/49237/ \
LOCAL/ohauer
PATCHFILES= ${PORTNAME}-${PORTVERSION}-r${PATCHREV}.diff.bz2
PATCH_SITES= LOCAL/ohauer
MAINTAINER= ohauer@FreeBSD.org
COMMENT= CVS to Subversion Repository Converter
BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}gdbm>0:databases/py-gdbm@${FLAVOR}
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}gdbm>0:databases/py-gdbm@${FLAVOR} \
cvs:devel/cvs
# 2.4.0 -> svn r5392
PATCHREV= 5433
USES= shebangfix python:2.7
USE_PYTHON= distutils autoplist
NO_ARCH= yes
SHEBANG_FILES= cvs2svn cvs2git cvs2bzr *.py \
contrib/* cvs2svn_lib/*.py \
svntest/* cvs2svn_rcsparse/*.py
OPTIONS_MULTI= SCM
OPTIONS_MULTI_SCM= SUBVERSION GIT BAZAAR
OPTIONS_DEFAULT= SUBVERSION
SUBVERSION_DESC= Build with subversion support
GIT_DESC= Build with git support
BAZAAR_DESC= Build with Bazaar support
SUBVERSION_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}subversion>=0:devel/py-subversion@${FLAVOR}
GIT_RUN_DEPENDS= ${LOCALBASE}/bin/git:devel/git
BAZAAR_RUN_DEPENDS= ${LOCALBASE}/bin/bzr:devel/bzr
# documents from ${WRKSRC}/doc
DOCS1= design-notes.txt making-releases.txt \
revision-reader.txt symbol-notes.txt
# documents from ${WRKSRC}/www
DOCS2= cvs2bzr.html cvs2git.html cvs2svn.html \
faq.html features.html index.html issue_tracker.html \
project_license.html project_tools.html
PORTDOCS:= ${DOCS1} ${DOCS2}
PORTEXAMPLES= cvs2bzr-example.options cvs2git-example.options \
cvs2hg-example.options cvs2svn-example.options
MANPAGES= cvs2svn.1.gz \
cvs2git.1.gz \
cvs2bzr.1.gz
PLIST_FILES+= ${MANPAGES:S|^|man/man1/|}
post-patch:
# be consistent with PORTVERSION
@${REINPLACE_CMD} -e 's|2.5.0-dev|2.4.0|' \
${WRKSRC}/PKG-INFO \
${WRKSRC}/cvs2svn_lib/version.py
post-build:
${MAKE} man -C ${WRKSRC}
post-install:
@${INSTALL_MAN} ${MANPAGES:R:S|^|${WRKSRC}/|} ${STAGEDIR}${PREFIX}/man/man1
@${MKDIR} ${STAGEDIR}${DOCSDIR}
@${INSTALL_DATA} ${DOCS1:S|^|${WRKSRC}/doc/|} ${STAGEDIR}${DOCSDIR}
@${INSTALL_DATA} ${DOCS2:S|^|${WRKSRC}/www/|} ${STAGEDIR}${DOCSDIR}
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
@${INSTALL_DATA} ${PORTEXAMPLES:S|^|${WRKSRC}/|} ${STAGEDIR}${EXAMPLESDIR}
.include <bsd.port.mk>