source: packages/lang/pygobject/Makefile @ 13928

Last change on this file since 13928 was 13928, checked in by lars, 7 years ago

Update pygobject 2.16.0

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 2.6 KB
Line 
1#
2# Copyright (C) 2008 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7# $Id$
8
9include $(TOPDIR)/rules.mk
10
11PKG_NAME:=pygobject
12PKG_VERSION:=2.16.0
13PKG_RELEASE:=1
14
15PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16PKG_SOURCE_URL:=@GNOME/$(PKG_NAME)/2.16
17PKG_MD5SUM:=431e7d4632163b93d1ee43cd071a389c
18PKG_FIXUP:=libtool
19PKG_INSTALL:=1
20
21include $(INCLUDE_DIR)/package.mk
22-include $(if $(DUMP),,$(STAGING_DIR)/mk/python-package.mk)
23
24EXTRA_LDFLAGS+= \
25        -L$(STAGING_DIR)/usr/lib/libintl/lib/ \
26        -L$(STAGING_DIR)/usr/lib/libiconv/lib/
27
28define Package/python-gobject
29  SUBMENU:=Python
30  SECTION:=lang
31  CATEGORY:=Languages
32  TITLE:=GLib bindings for python
33  URL:=http://www.pygtk.org/
34  DEPENDS:=python-core +glib2
35endef
36
37define Package/python-gobject/description
38  GLib bindings for python
39endef
40
41define Build/Configure
42        $(call Build/Configure/Default, \
43                --with-libffi \
44        )
45endef
46
47define Build/InstallDev
48        $(INSTALL_DIR) $(1)/usr/include/pygtk-2.0/
49        $(INSTALL_DATA) \
50                $(PKG_INSTALL_DIR)/usr/include/pygtk-2.0/* \
51                $(1)/usr/include/pygtk-2.0/
52
53        $(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
54        $(INSTALL_DATA) \
55                $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
56                $(1)/usr/lib/pkgconfig/
57
58        $(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
59        $(CP) \
60                $(PKG_INSTALL_DIR)/usr/lib/*.{so,a,la} \
61                $(1)/usr/lib/
62
63        $(SED) \
64                "s,^\(prefix\|exec_prefix\|datadir\)=,\1=$(STAGING_DIR),g" \
65                $(1)/usr/lib/pkgconfig/pygobject-2.0.pc
66
67        $(INSTALL_DIR) $(1)/usr/share/pygobject/2.0/codegen
68        $(INSTALL_DATA) \
69                $(PKG_INSTALL_DIR)/usr/share/pygobject/2.0/codegen/*.py \
70                $(1)/usr/share/pygobject/2.0/codegen
71
72        $(INSTALL_DIR) $(1)/usr/share/pygobject/2.0/defs
73        $(INSTALL_DATA) \
74                $(PKG_INSTALL_DIR)/usr/share/pygobject/2.0/defs/* \
75                $(1)/usr/share/pygobject/2.0/defs
76
77        $(INSTALL_DIR) $(2)/bin
78        $(INSTALL_BIN) \
79                $(PKG_INSTALL_DIR)/usr/bin/* \
80                $(2)/bin
81
82        $(SED) \
83                "s,^\(prefix\|datadir\)=,\1=$(STAGING_DIR),g" \
84                $(2)/bin/pygobject-codegen-2.0
85endef
86
87define Package/python-gobject/install
88        $(INSTALL_DIR) $(1)/usr/lib
89        $(CP) \
90                $(PKG_INSTALL_DIR)/usr/lib/*.so* \
91                $(1)/usr/lib
92
93        $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
94        $(INSTALL_DATA) \
95                $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/*.{pth,py} \
96                $(1)$(PYTHON_PKG_DIR)/
97
98        $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)/gtk-2.0
99        $(INSTALL_DATA) \
100                $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/gtk-2.0/*.py \
101                $(1)$(PYTHON_PKG_DIR)/gtk-2.0/
102
103        $(foreach d,gobject gio glib, \
104                $(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)/gtk-2.0/$(d); \
105                $(INSTALL_DATA) \
106                        $(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/gtk-2.0/$(d)/*.{py,so} \
107                        $(1)$(PYTHON_PKG_DIR)/gtk-2.0/$(d); \
108        )
109endef
110
111$(eval $(call BuildPackage,python-gobject))
Note: See TracBrowser for help on using the repository browser.