summaryrefslogtreecommitdiff
path: root/x11/gtk3/Makefile
blob: 88403bd26b59893d242158b6c52cab68f5a8e51d (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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# $NetBSD: Makefile,v 1.40 2013/06/04 22:17:20 tron Exp $

DISTNAME=	gtk+-3.8.2
PKGNAME=	${DISTNAME:S/gtk/gtk3/}
PKGREVISION=	3
CATEGORIES=	x11 gnome
MASTER_SITES=	ftp://ftp.gtk.org/pub/gtk/${PKGVERSION_NOREV:R}/ \
		${MASTER_SITE_GNOME:=sources/gtk+/${PKGVERSION_NOREV:R}/}
EXTRACT_SUFX=	.tar.xz

MAINTAINER=	pkgsrc-users@NetBSD.org
HOMEPAGE=	http://www.gtk.org/
COMMENT=	GIMP Toolkit v3 - libraries for building X11 user interfaces
LICENSE=	gnu-lgpl-v2.1

USE_PKGLOCALEDIR=	yes
USE_TOOLS+=		gmake msgfmt perl pkg-config bash
USE_LANGUAGES=		c c++
USE_LIBTOOL=		yes
PTHREAD_AUTO_VARS=	yes

GNU_CONFIGURE=		yes
# XXX there is a subtle bashism in "configure" or a bug in NetBSD's sh
CONFIG_SHELL=		bash
CONFIGURE_ARGS+=	--sysconfdir=${PREFIX}/libdata
# Work around build problems, disable unstable PAPI, PR #41608:
CONFIGURE_ARGS+=	--disable-papi
# XXX for now, to avoid conflict
CONFIGURE_ARGS+=	--enable-gtk2-dependency
# Avoid regeneration of Makefile.in after configure.ac patch
CONFIGURE_ARGS+=	--disable-maintainer-mode
DEPENDS+=		gtk2+-[0-9]*:../../x11/gtk2
MAKE_ENV+=		PKGLOCALEDIR=${PKGLOCALEDIR}
TEST_TARGET=		check

PKGCONFIG_OVERRIDE+=	gdk-3.0.pc.in
PKGCONFIG_OVERRIDE+=	gtk+-3.0.pc.in
PKGCONFIG_OVERRIDE+=	gtk+-unix-print-3.0.pc.in
PKGCONFIG_OVERRIDE+=	gail-3.0.pc.in

INSTALLATION_DIRS+=	lib/gtk-3.0/immodules
INSTALLATION_DIRS+=	lib/gtk-3.0/modules
INSTALLATION_DIRS+=	lib/gtk-3.0/3.0.0/filesystems

#REQD_DIRS+=		${PREFIX}/libdata/gtk-2.0

BUILD_DIRS=		. demos/gtk-demo

.include "../../mk/bsd.prefs.mk"

# gtk/Makefile.am hardcodes 'grep -o' so require GNU grep on platforms
# which do not have it.
.if ${OPSYS} == "SunOS"
BUILD_DEPENDS+=		grep-[0-9]*:../../textproc/grep
TOOLS_PATH.grep=	${LOCALBASE}/bin/ggrep
.endif
# isnan and isinf are part of libc, not libm on DragonFly
# conf tests fail detection due to conflicting definitions, just skip them
.if ${OPSYS} == "DragonFly"
CONFIGURE_ENV+=		ac_cv_func_isnan=yes
CONFIGURE_ENV+=		ac_cv_func_isinf=yes
.endif

CFLAGS.SunOS+=		-std=gnu99

CPPFLAGS+=		-DPREFIX="\"${PREFIX}\""

# We remove the module databases during post-install since we create them
# anew in the +INSTALL script as part of the POST-INSTALL action.
#
post-install:
	${RM} -f ${DESTDIR}${GTK3_IMMODULES_DB}

_BUILDING_GTK3=	yes
.include "modules.mk"

.include "../../databases/shared-mime-info/buildlink3.mk"
BUILDLINK_API_DEPENDS.atk+=	atk>=2.7.5
.include "../../devel/atk/buildlink3.mk"
.include "../../devel/gettext-lib/buildlink3.mk"
BUILDLINK_API_DEPENDS.glib2+=	glib2>=2.35.3
.include "../../devel/glib2/buildlink3.mk"
BUILDLINK_API_DEPENDS.gdk-pixbuf2+=	gdk-pixbuf2>=2.27.1
.include "../../graphics/gdk-pixbuf2/buildlink3.mk"
BUILDLINK_DEPMETHOD.gobject-introspection:=	build
BUILDLINK_API_DEPENDS.gobject-introspection+=	gobject-introspection>=1.32
.include "../../devel/gobject-introspection/buildlink3.mk"

.include "options.mk"

.include "../../devel/glib2/schemas.mk"

BUILDLINK_API_DEPENDS.pango+=	pango>=1.32.4
.include "../../devel/pango/buildlink3.mk"
.include "../../fonts/fontconfig/buildlink3.mk"
BUILDLINK_API_DEPENDS.cairo+=	cairo>=1.10.0
.include "../../graphics/cairo/buildlink3.mk"
.include "../../graphics/cairo-gobject/buildlink3.mk"
.include "../../graphics/freetype2/buildlink3.mk"

.include "../../mk/bsd.pkg.mk"