aboutsummaryrefslogtreecommitdiff
path: root/java/kaffe-devel/Makefile
blob: 39db34069d213553879fee44092ba6e5464d8c2c (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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# New ports collection makefile for:    kaffe
# Date created:         4 August 2003
# Whom:                 Mark Huizer <xaa+ports@timewasters.nl>
#
# $FreeBSD$
#

# Configure AWT implementation used (this can be put in make.conf)
#
# KAFFE_AWT = no        No AWT classes
# KAFFE_AWT = X         X AWT classes
# KAFFE_AWT = QT        Qt AWT classes

PORTNAME=	kaffe
PORTVERSION=	1.1.3
PORTREVISION=	1
CATEGORIES=	java
MASTER_SITES=	ftp://ftp.kaffe.org/pub/kaffe/v1.1.x-development/
PKGNAMESUFFIX=	-devel

MAINTAINER=	xaa+ports@timewasters.nl
COMMENT=	Multi-platform Java virtual machine with JIT compiler and AWT package

LIB_DEPENDS=	jpeg.9:${PORTSDIR}/graphics/jpeg \
		ungif.5:${PORTSDIR}/graphics/libungif \
		png.5:${PORTSDIR}/graphics/png \
		gmp.6:${PORTSDIR}/math/libgmp4

WRKSRC=		${WRKDIR}/kaffe-${PORTVERSION}

NOT_FOR_ARCHS=	amd64 alpha

USE_LIBTOOL=	yes
USE_GMAKE=	yes
USE_ICONV=	yes
LIBTOOLFLAGS=
INSTALLS_SHLIB=	yes
GNU_CONFIGURE=	yes
CONFIGURE_ARGS=	CPPFLAGS=-I${LOCALBASE}/include LDFLAGS=-L${LOCALBASE}/lib --with-iconv-prefix=${LOCALBASE}

WANT_GNOME=	esound

MAN1=		kaffe.1

OPTIONS=	KAFFE_AWT_X "Use AWT widgets with X" On \
		KAFFE_AWT_QT "Use AWT widgets with Qt" Off \
		KAFFE_AWT_NO "Do not use AWT widgets" Off

.include <bsd.port.pre.mk>

.if !defined(WITH_KAFFE_AWT_X) && !defined(WITH_KAFFE_AWT_QT) && !defined(WITH_KAFFE_AWT_NO)
BROKEN=	"Choose one of the options in 'make config'"
.endif

.if defined(WITH_KAFFE_AWT_X)
. if defined(WITH_KAFFE_AWT_QT) || defined(WITH_KAFFE_AWT_NO)
    BROKEN=	"Choose only one of the options in 'make config'"
. endif
  CONFIGURE_ARGS+=	--with-awt=X
  USE_XLIB=		yes
  AWT=			yes
  WITH_ESOUND=		yes
.endif
.if defined(WITH_KAFFE_AWT_QT)
. if defined(WITH_KAFFE_AWT_X) || defined(WITH_KAFFE_AWT_NO)
    BROKEN=	"Choose only one of the options in 'make config'"
. endif
  CONFIGURE_ARGS+=	--with-awt=qt --with-qtdir=${X11BASE}
  AWT=			yes
  USE_QT_VER=		3
  WITH_ESOUND=		yes
.endif
.if defined(WITH_KAFFE_AWT_NO)
. if defined(WITH_KAFFE_AWT_X) || defined(WITH_KAFFE_AWT_QT)
    BROKEN=	"Choose only one of the options in 'make config'"
. endif
  CONFIGURE_ARGS+=	--with-awt=no
.endif

.if defined(AWT)
  PLIST_SUB+=	SUB_AWT=""
.else
  PLIST_SUB+=	SUB_AWT="@comment "
.endif

.if defined(WITH_ESOUND)
  USE_GNOME+=	esound
  PLIST_SUB+=	SUB_ESOUND=""
.else
  PLIST_SUB+=	SUB_ESOUND="@comment "
.endif

PLIST_SUB+=	PORTVER=${PORTVERSION} ARCH=${ARCH}

post-install:
	@${MKDIR} ${DATADIR}
	${INSTALL_SCRIPT} ${WRKSRC}/BUILD_ENVIRONMENT ${DATADIR}
	${INSTALL_DATA} ${WRKSRC}/license.terms ${DATADIR}

.include <bsd.port.post.mk>