pkgsrc-wip/p4/Makefile.common

62 lines
1.6 KiB
Makefile

# $NetBSD: Makefile.common,v 1.7 2011/08/18 20:56:05 bubuchka Exp $
#
# used by devel/p4/Makefile
# used by devel/p4-docs/Makefile
# used by devel/p4d/Makefile
# used by devel/p4web/Makefile
# used by wip/p4/Makefile
# used by wip/p4api/Makefile
# used by wip/p4d/Makefile
# used by wip/py-p4/Makefile
P4_VER= 2010.2
P4_VER_PL= 295040
PKGNAME?= ${DISTNAME}-${P4_VER}
CATEGORIES= devel scm
MAINTAINER?= schmonz@NetBSD.org
LICENSE?= perforce-license
NO_CONFIGURE?= yes
BUILD_DIRS= # empty
WRKSRC= ${WRKDIR}/${DISTNAME}-${P4_VER}.${P4_VER_PL}
DIST_SUBDIR= perforce-${P4_VER}
.if defined(P4BINONLY)
DIST_SUBDIR= perforce-${P4_VER}/${P4ARCH}
MASTER_SITES= ftp://ftp.perforce.com/pub/perforce/r10.2/bin.${P4ARCH}/
DISTFILES?= ${DISTNAME}
EMUL_PLATFORMS+= darwin-i386 darwin-x86_64 darwin-powerpc
EMUL_PLATFORMS+= freebsd-i386 freebsd-x86_64
EMUL_PLATFORMS+= linux-i386 linux-x86_64
EMUL_PLATFORMS+= netbsd-i386 netbsd-x86_64
EMUL_REQD= netbsd>=3.0
. include "../../mk/bsd.prefs.mk"
. if ${EMUL_PLATFORM:Mdarwin-*}
P4ARCH?= darwin90u
. elif ${EMUL_PLATFORM} == "freebsd-i386"
P4ARCH?= freebsd60x86
. elif ${EMUL_PLATFORM} == "freebsd-x86_64"
P4ARCH?= freebsd60x86_64
. elif ${EMUL_PLATFORM} == "linux-i386"
P4ARCH?= linux26x86
. elif ${EMUL_PLATFORM} == "linux-x86_64"
P4ARCH?= linux26x86_64
. elif ${EMUL_PLATFORM} == "netbsd-i386" || ${EMUL_PLATFORM} == "netbsd-x86_64"
P4ARCH?= netbsd31x86
. else
P4ARCH?= none
PKG_FAIL_REASON= "no p4 binary available for ${EMUL_PLATFORM}"
. endif
.endif # P4BINONLY
# p4 distfiles may have no files to extract, but the following unifies WRKSRC
post-extract:
${TEST} -d ${WRKSRC} || ${MKDIR} ${WRKSRC}