summaryrefslogtreecommitdiffstats
path: root/rules/pygobject.make
blob: 3694820b0ec9176c68d93aa7885c5ce1149b6d41 (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
# -*-makefile-*-
#
# Copyright (C) 2010 by Uwe Kleine-Koenig <u.kleine-koenig@pengutronix.de>
#
# See CREDITS for details about who has contributed to this project.
#
# For further information about the PTXdist project and license conditions
# see the README file.
#

#
# We provide this package
#
PACKAGES-$(PTXCONF_PYGOBJECT) += pygobject

#
# Paths and names
#
PYGOBJECT_VERSION	:= 2.21.5
PYGOBJECT_MD5		:= ef1ef7def7faa407c07b4bbd6d068ff2
PYGOBJECT		:= pygobject-$(PYGOBJECT_VERSION)
PYGOBJECT_SUFFIX	:= tar.gz
PYGOBJECT_URL		:= http://ftp.gnome.org/pub/GNOME/sources/pygobject/$(basename $(PYGOBJECT_VERSION))/$(PYGOBJECT).$(PYGOBJECT_SUFFIX)
PYGOBJECT_SOURCE	:= $(SRCDIR)/$(PYGOBJECT).$(PYGOBJECT_SUFFIX)
PYGOBJECT_DIR		:= $(BUILDDIR)/$(PYGOBJECT)
PYGOBJECT_LICENSE	:= LGPL-2.1-or-later

# ----------------------------------------------------------------------------
# Prepare
# ----------------------------------------------------------------------------

PYGOBJECT_CONF_ENV = \
	$(CROSS_ENV) \
	PYTHON=$(CROSS_PYTHON)

PYGOBJECT_CONF_TOOL := autoconf
PYGOBJECT_CONF_OPT := \
	$(CROSS_AUTOCONF_USR) \
	--disable-docs \
	--disable-introspection \
	--disable-silent-rules \
	--enable-thread \
	--with-ffi

# ----------------------------------------------------------------------------
# Target-Install
# ----------------------------------------------------------------------------

$(STATEDIR)/pygobject.targetinstall:
	@$(call targetinfo)

	@$(call install_init, pygobject)
	@$(call install_fixup, pygobject,PRIORITY,optional)
	@$(call install_fixup, pygobject,VERSION,$(PYGOBJECT_VERSION))
	@$(call install_fixup, pygobject,SECTION,base)
	@$(call install_fixup, pygobject,AUTHOR,"Uwe Kleine-Koenig <u.kleine-koenig@pengutronix.de>")
	@$(call install_fixup, pygobject,DESCRIPTION,missing)

	@$(call install_lib, pygobject, 0, 0, 0644, libpyglib-2.0-python$(PYTHON_MAJORMINOR))

	@$(call install_copy, pygobject, 0, 0, 0644, -, $(PYTHON_SITEPACKAGES)/pygtk.pth)

	@$(foreach pyc, \
		pygtk.pyc \
		gtk-2.0/glib/option.pyc \
		gtk-2.0/glib/__init__.pyc \
		gtk-2.0/gobject/__init__.pyc \
		gtk-2.0/gobject/constants.pyc \
		gtk-2.0/gobject/propertyhelper.pyc \
		gtk-2.0/dsextras.pyc \
		gtk-2.0/gio/__init__.pyc, \
	$(call install_copy, pygobject, 0, 0, 0644, -, $(PYTHON_SITEPACKAGES)/$(pyc)); \
	)

	@$(foreach pyso, \
		gtk-2.0/glib/_glib.so \
		gtk-2.0/gobject/_gobject.so \
		gtk-2.0/gio/_gio.so \
		gtk-2.0/gio/unix.so, \
	$(call install_copy, pygobject, 0, 0, 0644, -, $(PYTHON_SITEPACKAGES)/$(pyso)); \
	)

	@$(call install_finish, pygobject)
	@$(call touch)

# vim: syntax=make