summaryrefslogtreecommitdiff
path: root/cad/klayout/Makefile
blob: 537c65877ba806b3ce8bab524160c7f90ba51e94 (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
# $NetBSD: Makefile,v 1.11 2018/07/04 13:40:10 jperkin Exp $

DISTNAME=	klayout-0.24.10
PKGREVISION=	1
CATEGORIES=	cad
MASTER_SITES=	http://www.klayout.org/downloads/source/

MAINTAINER=	pkgsrc-users@NetBSD.org
HOMEPAGE=	http://www.klayout.de/
COMMENT=	Simple GDS and OASIS file viewer and Editor
LICENSE=	gnu-gpl-v2

USE_LANGUAGES=	c c++
USE_TOOLS+=	gmake

CFLAGS+=	-I${PREFIX}/include/python${PYVERSUFFIX}
NO_CONFIGURE=	yes

SUBST_CLASSES+= 	rpath
SUBST_MESSAGE.rpath=	Add COMPILER_RPATH_FLAG and PREFIX to NetBSD specific config file
SUBST_FILES.rpath+=	config/Makefile.conf.netbsd-32-gcc-release
SUBST_STAGE.rpath=	pre-configure
SUBST_VARS.rpath=	COMPILER_RPATH_FLAG PREFIX
SUBST_SED.rpath=	-e 's|@@LDFLAGS@@|${LDFLAGS}|'

AUTO_MKDIRS=		yes
INSTALL_BINDIR=		${DESTDIR}${PREFIX}/bin
INSTALL_LIBDIR=		${DESTDIR}${PREFIX}/lib
REL_DIR=		build.netbsd-32-gcc-release

OTHER_BIN= \
	strm2cif \
	strm2dxf \
	strm2gds \
	strm2gdstxt \
	strm2oas \
	strm2txt \
	strmclip \
	strmcmp \
	strmxor

do-build:
	cd ${WRKSRC} && ${PKGSRC_SETENV} ${MAKE_ENV} sh build.sh -python python${PYVERSSUFFIX} -qt ${PREFIX}/qt4

do-install:
	(cd ${WRKSRC}; \
	pwd; \
	${INSTALL_PROGRAM} ${REL_DIR}/main/klayout ${INSTALL_BINDIR}; \
	${INSTALL_LIB} ${REL_DIR}/main/libklayout.so ${INSTALL_LIBDIR} ;\
	for bin in ${OTHER_BIN}; do \
	  ${INSTALL_PROGRAM} ${REL_DIR}/main/$$bin ${INSTALL_BINDIR} ;\
	done ;\
	${CHMOD} 755 ${INSTALL_BINDIR}/* ;\
	)

.include "../../lang/python/pyversion.mk"
.include "../../lang/ruby/buildlink3.mk"
.include "../../x11/qt4-libs/buildlink3.mk"
# libQtDesigner
.include "../../x11/qt4-tools/buildlink3.mk"
BUILDLINK_DEPMETHOD.qt4-tools=	full
.include "../../mk/bsd.pkg.mk"