summaryrefslogtreecommitdiffstats
path: root/biology/L-Breeder/Makefile
blob: 1a2e3151c7b48ffe769413e711fd70051bcc2a5b (plain)
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
# New ports collection makefile for:	L-Breeder
# Date created:				30 May 2002
# Whom:					David Yeske <dyeske@yahoo.com> et al
#
# $FreeBSD$
#

PORTNAME=	L-Breeder
PORTVERSION=	1.0
CATEGORIES=	biology
MASTER_SITES=	http://pixie.oum.ox.ac.uk/L-Breeder/
DISTNAME=	LBreeder
EXTRACT_SUFX=	.tgz

MAINTAINER=	dyeske@yahoo.com
COMMENT=	Allows you to display and breed L-system forms

LIB_DEPENDS=	wx_gtk_gl-2.4.0:${PORTSDIR}/x11-toolkits/wxgtk-devel

WRKSRC=		${WRKDIR}/LBreeder/LBreeder
PATCH_WRKSRC=	${WRKDIR}/LBreeder

USE_X_PREFIX=	yes
USE_GNOME=	gtk12 gdkpixbuf
USE_MESA=	yes
USE_GMAKE=	yes
USE_REINPLACE=	yes

.if defined(WITH_OPTIMIZED_CFLAGS)
CFLAGS+=	-O3 -ffast-math
.endif

pre-everything::
.if !defined(WITH_OPTIMIZED_CFLAGS)
	@${ECHO_MSG} "You can enable additional compilation optimizations"
	@${ECHO_MSG} "by defining WITH_OPTIMIZED_CFLAGS"
.endif

.include <bsd.port.pre.mk>

.if ${OSVERSION} >= 500000
BROKEN=		"invalid C++"
.endif

post-patch:
	@${FIND} ${WRKDIR} -type f -name Makefile | \
		${XARGS} -n 10 ${REINPLACE_CMD} -E -e \
		's|/usr/lib/libm.a||; \
		s|-ldl||; \
		s|-lgtk||; \
		s|-lgmodule||; \
		s|-lpthread||; \
		s|-lgthread||; \
		s|/usr/lib/libGL.a|-lGL|; \
		s|/usr/lib/libGLU.so|-lGLU|; \
		s|-O2|"${CFLAGS} ${PTHREAD_CFLAGS}"|; \
		s|-lglib|`${GLIB_CONFIG} --libs`|; \
		s|g\+\+|${CXX} -I${X11BASE}/include|; \
		s|-lgdk|`${GDK_PIXBUF_CONFIG} --libs`|; \
		s|-lwx_gtk[[:space:]]|`wx-config --libs`|; \
		s|-lwx_gtk_gl|-lwx_gtk_gl-2.4|'

do-install:
	@${INSTALL_PROGRAM} ${WRKSRC}/L-Breeder ${PREFIX}/bin

.include <bsd.port.post.mk>
OpenPOWER on IntegriCloud