blob: 3e9eb836120074b8798bd5877c106c68795bf49f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
|
# $FreeBSD$
PORTNAME= dragonegg46
PORTVERSION= 3.4.r${SVN_REV}
PORTREVISION= 1
CATEGORIES= lang devel
MASTER_SITES= ${MASTER_SITE_LOCAL}
MASTER_SITE_SUBDIR= brooks
PKGNAMESUFFIX= -devel
DISTNAME= dragonegg-${PORTVERSION}
MAINTAINER= brooks@FreeBSD.org
COMMENT= GCC plugin to use the LLVM backend
CONFLICTS+= dragonegg46-3*
# XXX: not entierly sure if llvm-devel is a depend
BUILD_DEPENDS+= llvm-devel>=${PORTVERSION}:${PORTSDIR}/devel/llvm-devel
RUN_DEPENDS+= llvm-devel>=${PORTVERSION}:${PORTSDIR}/devel/llvm-devel
OPTIONS_DEFINE= DOCS
USES= compiler:features
USE_BZIP2= yes
USE_GCC= 4.6
USE_GMAKE= yes
USE_LDCONFIG= yes
DRAGONEGG_RELEASE= ${PORTVERSION:C/\.r[0-9]*//}
DRAGONEGG_SO= dragonegg-${DRAGONEGG_RELEASE}.so
DRAGONEGG_PATH= ${GCC_LIBDIR}/${DRAGONEGG_SO}
GCC_LIBDIR= lib/${CC}
ALL_TARGET=
MAKE_ARGS= GCC=${LOCALBASE}/bin/${CC} VERBOSE=1
.include "${.CURDIR}/../../devel/llvm-devel/Makefile.svn_rev"
PLIST_FILES= ${GCC_LIBDIR}/${DRAGONEGG_SO}
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MDOCS}
PORTDOCS= README
.endif
.include <bsd.port.pre.mk>
.if ${COMPILER_FEATURES:Mlibc++}
IGNORE= "Dragonegg can't work if LLVM was built with libc++"
.endif
.if defined(BOOTSTRAP) || defined(SVN_FETCH)
FETCH_DEPENDS+= svn:${PORTSDIR}/devel/subversion
do-fetch:
${MKDIR} ${WRKDIR}
svn export -r ${SVN_REV} \
http://llvm.org/svn/llvm-project/dragonegg/trunk \
${WRKDIR}/${DISTNAME}
cd ${WRKDIR}; tar cvfy ${DISTDIR}/${DISTNAME}.tar.bz2 ${DISTNAME}
.if ${USER} == brooks || ${USER} == bed22
scp ${DISTDIR}/${DISTNAME}.tar.bz2 \
brooks@freefall.freebsd.org:public_distfiles/
.endif
.endif
post-patch:
${REINPLACE_CMD} -e 's/%%CC%%/${CC}/' \
-e 's#%%PLUGINPATH%%#${LOCALBASE}/${DRAGONEGG_PATH}#' \
-e 's/arg-dragonegg/arg-dragonegg-${DRAGONEGG_RELEASE}/' \
${WRKSRC}/README
do-install:
mkdir -p ${STAGEDIR}${LOCALBASE}/${GCC_LIBDIR}
${INSTALL_LIB} ${WRKSRC}/dragonegg.so \
${STAGEDIR}${LOCALBASE}/${GCC_LIBDIR}/${DRAGONEGG_SO}
.if ${PORT_OPTIONS:MDOCS}
${MKDIR} ${STAGEDIR}${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR}
.endif
.include <bsd.port.post.mk>
|