#!/bin/sh

. config/options

$SCRIPTS/install Python
$SCRIPTS/install glib
$SCRIPTS/install libffi

PYTHON_LIB_DIR=`ls -d $INSTALL/usr/lib/python*`

mkdir -p $INSTALL/usr/lib
cp $PKG_BUILD/glib/.libs/libpyglib*.so* $INSTALL/usr/lib

mkdir -p $PYTHON_LIB_DIR/site-packages/gtk-2.0/gobject
cp $PKG_BUILD/dsextras.pyc $PYTHON_LIB_DIR/site-packages/gtk-2.0
cp $PKG_BUILD/gobject/.libs/*.so $PYTHON_LIB_DIR/site-packages/gtk-2.0/gobject
cp $PKG_BUILD/gobject/*.pyc $PYTHON_LIB_DIR/site-packages/gtk-2.0/gobject

mkdir -p $PYTHON_LIB_DIR/site-packages/gtk-2.0/glib
cp $PKG_BUILD/glib/.libs/_glib.so $PYTHON_LIB_DIR/site-packages/gtk-2.0/glib
cp $PKG_BUILD/glib/*.pyc $PYTHON_LIB_DIR/site-packages/gtk-2.0/glib

mkdir -p $PYTHON_LIB_DIR/site-packages/gtk-2.0/gio
cp $PKG_BUILD/gio/.libs/_gio.so $PYTHON_LIB_DIR/site-packages/gtk-2.0/gio
cp $PKG_BUILD/gio/.libs/unix.so $PYTHON_LIB_DIR/site-packages/gtk-2.0/gio
cp $PKG_BUILD/gio/*.pyc $PYTHON_LIB_DIR/site-packages/gtk-2.0/gio
