.*so did not packed into rootfs

Hi,
I was trying to add a new package named 'pygobject' in my sdk, and it could be compiled successfully. But then I came across a problem that the *.so files did not packed into the rootfs. I have checked the ipkg directory of 'pygobject' in the compile_dir, it seemed everything was ok since it contained the *.so files, as follows:

.
`-- python-gobject
    |-- CONTROL
    |   |-- control
    |   |-- postinst
    |   `-- prerm
    `-- usr
        `-- lib
            |-- libpyglib-2.0-python.so -> libpyglib-2.0-python.so.0.0.0
            |-- libpyglib-2.0-python.so.0 -> libpyglib-2.0-python.so.0.0.0
            |-- libpyglib-2.0-python.so.0.0.0
            `-- python2.7
                `-- site-packages
                    |-- gtk-2.0
                    |   |-- dsextras.py
                    |   |-- gio
                    |   |   |-- __init__.py
                    |   |   |-- _gio.so
                    |   |   `-- unix.so
                    |   |-- glib
                    |   |   |-- __init__.py
                    |   |   |-- _glib.so
                    |   |   `-- option.py
                    |   `-- gobject
                    |       |-- __init__.py
                    |       |-- _gobject.so
                    |       |-- constants.py
                    |       `-- propertyhelper.py
                    |-- pygtk.pth
                    `-- pygtk.py

10 directories, 19 files

Only 'libpyglib-2.0-python.so*' were missing, but the whole 'python2.7' directory was successfully packed into the rootfs.

Could anybody give some advices? Thanks!

Can you share your makefile? Did you use any premade install templates from python.mk or similar?

I referenced the legacy packages found in 'archive.git' of openwrt:
here

Here is the Makefile:

#
# Copyright (C) 2008 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#

include $(TOPDIR)/rules.mk

PKG_NAME:=pygobject
PKG_VERSION:=2.21.5
PKG_RELEASE:=1

PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=@GNOME/$(PKG_NAME)/2.21
PKG_MD5SUM:=77ad7e8dbf13188364c9f56f907e530a
PKG_FIXUP:=autoreconf
PKG_INSTALL:=1

include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/nls.mk
$(call include_mk, python-package.mk)

EXTRA_LDFLAGS+= \
	-L$(ICONV_PREFIX) -L$(INTL_PREFIX)

TARGET_CFLAGS += $(FPIC)
CONFIGURE_ARGS += --enable-static --disable-instrospection

define Package/python-gobject
  SUBMENU:=Python
  SECTION:=lang
  CATEGORY:=Languages
  TITLE:=GLib bindings for python
  URL:=http://www.pygtk.org/
  DEPENDS:=+python-mini +glib2 +libffi
endef

define Package/python-gobject/description
  GLib bindings for python
endef

define Build/Configure
	$(call Build/Configure/Default, \
		--with-libffi --disable-introspection \
	)
endef

define Build/InstallDev
	$(INSTALL_DIR) $(1)/usr/include/pygtk-2.0/
	$(INSTALL_DATA) \
		$(PKG_INSTALL_DIR)/usr/include/pygtk-2.0/* \
		$(1)/usr/include/pygtk-2.0/

	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
	$(INSTALL_DATA) \
		$(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
		$(1)/usr/lib/pkgconfig/

	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig/
	$(CP) \
		$(PKG_INSTALL_DIR)/usr/lib/*.{so,a,la} \
		$(1)/usr/lib/

	$(SED) \
		"s,^\(prefix\|exec_prefix\|datadir\)=,\1=$(STAGING_DIR),g" \
		$(1)/usr/lib/pkgconfig/pygobject-2.0.pc

	$(INSTALL_DIR) $(1)/usr/share/pygobject/2.0/codegen
	$(INSTALL_DATA) \
		$(PKG_INSTALL_DIR)/usr/share/pygobject/2.0/codegen/*.py \
		$(1)/usr/share/pygobject/2.0/codegen

	$(INSTALL_DIR) $(1)/usr/share/pygobject/2.0/defs
	$(INSTALL_DATA) \
		$(PKG_INSTALL_DIR)/usr/share/pygobject/2.0/defs/* \
		$(1)/usr/share/pygobject/2.0/defs

	$(INSTALL_DIR) $(2)/bin
	$(INSTALL_BIN) \
		$(PKG_INSTALL_DIR)/usr/bin/* \
		$(2)/bin

	$(SED) \
		"s,^\(prefix\|datadir\)=,\1=$(STAGING_DIR),g" \
		$(2)/bin/pygobject-codegen-2.0
endef

define Package/python-gobject/install
	$(INSTALL_DIR) $(1)/usr/lib
	$(CP) \
		$(PKG_INSTALL_DIR)/usr/lib/*.so* \
		$(1)/usr/lib

	$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)
	$(INSTALL_DATA) \
		$(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/*.{pth,py} \
		$(1)$(PYTHON_PKG_DIR)/

	$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)/gtk-2.0
	$(INSTALL_DATA) \
		$(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/gtk-2.0/*.py \
		$(1)$(PYTHON_PKG_DIR)/gtk-2.0/

	$(foreach d,gobject gio glib, \
		$(INSTALL_DIR) $(1)$(PYTHON_PKG_DIR)/gtk-2.0/$(d); \
		$(INSTALL_DATA) \
			$(PKG_INSTALL_DIR)$(PYTHON_PKG_DIR)/gtk-2.0/$(d)/*.{py,so} \
			$(1)$(PYTHON_PKG_DIR)/gtk-2.0/$(d); \
	)
endef

$(eval $(call BuildPackage,python-gobject))

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.