blob: 487859d71db4d1be42d2e73246c92216137eb820 (
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
67
68
69
70
71
72
73
74
75
76
77
|
# $NetBSD: Makefile,v 1.65 2017/01/06 07:23:09 plunky Exp $
#
DISTNAME= qcad-3.16.4.0
CATEGORIES= cad
MASTER_SITES= ${MASTER_SITE_GITHUB:=qcad/}
EXTRACT_SUFX= .zip
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://www.qcad.org/
COMMENT= 2D CAD system
LICENSE= gnu-gpl-v3
GITHUB_TAG= v${PKGVERSION_NOREV}
DEPENDS+= bash-[0-9]*:../../shells/bash
DEPENDS+= qt4-tiff-[0-9]*:../../x11/qt4-tiff
DEPENDS+= qt4-sqlite3-[0-9]*:../../x11/qt4-sqlite3
MAKE_JOBS_SAFE= no
USE_TOOLS+= chmod find make pax
USE_LANGUAGES= c c++
USE_LIBTOOL= yes
SUBST_CLASSES+= paths
SUBST_STAGE.paths= post-patch
SUBST_MESSAGE.paths= Attending to hard-coded paths.
SUBST_FILES.paths+= shared.pri src/core/RS.cpp src/core/RSettings.cpp
SUBST_FILES.paths+= scripts/Help/ShowReadme/ShowReadme.js
SUBST_FILES.paths+= scripts/Widgets/LibraryBrowser/LibraryBrowser.js
SUBST_SED.paths= -e 's,@PREFIX@,${PREFIX},g'
AUTO_MKDIRS= yes
#
# Fix permissions from zip file
#
post-extract:
${FIND} ${WRKSRC} -type f -exec ${CHMOD} u=rw,go=r "{}" "+"
#
# The QCad build system normally links direct to a release dir but this
# causes a lot of problems with libtool dependencies. We patch it so that
# the libs are linked from the source dirs and add an install target to
# allow pkgsrc to use DESTDIR
#
# The Qt script bindings are built in Qt version specific subdirectory
# which we can't patch directly, so we create a fake qtscript.pro file
# and use it to overwrite Makefiles. Makefile.qtscript is ignored
#
do-configure:
cd ${WRKSRC} && ${QTDIR}/bin/qmake -r -after DESTDIR=
cd ${WRKSRC}/src/3rdparty && ${QTDIR}/bin/qmake -r -after DESTDIR= \
INSTALLS+=target target.path=${PREFIX}/lib/${PKGBASE}/plugins/script \
qtscript.pro -o Makefile.qtscript
do-install:
cd ${WRKSRC} && make INSTALL_ROOT=${DESTDIR} install
${INSTALL_DATA} ${WRKSRC}/qcad.desktop \
${DESTDIR}${PREFIX}/share/applications
${INSTALL_MAN} ${WRKSRC}/qcad.1 \
${DESTDIR}${PREFIX}/${PKGMANDIR}/man1
${FIND} ${WRKSRC}/scripts -name \*.orig -delete
cd ${WRKSRC} && ${PAX} -rwpm fonts linetypes patterns \
plugins scripts themes ts ${DESTDIR}${PREFIX}/lib/${PKGBASE}
cd ${WRKSRC} && ${PAX} -rwpm readme.txt examples libraries \
${DESTDIR}${PREFIX}/share/${PKGBASE}
.include "../../sysutils/desktop-file-utils/desktopdb.mk"
.include "../../devel/libexecinfo/buildlink3.mk"
.include "../../x11/qt4-libs/buildlink3.mk"
BUILDLINK_API_DEPENDS.qt4-libs+= qt4-libs>=4.7
.include "../../x11/qt4-tools/buildlink3.mk"
BUILDLINK_API_DEPENDS.qt4-tools+= qt4-tools>=4.7
BUILDLINK_DEPMETHOD.qt4-tools= full
.include "../../mk/bsd.pkg.mk"
|