#!/bin/bash

PKG=/mnt/hda2/emelfm2/pkg

tar xvf emelfm2*.xz
cd emelfm2-0.7.3
make PREFIX=/usr/local
make PREFIX=${PKG}/usr/local install
make PREFIX=${PKG}/usr/local install_i18n

cd "$PKG"
find . | xargs file | grep "executable" | grep ELF | grep "not stripped" | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
find . | xargs file | grep "shared object" | grep ELF | grep "not stripped" | cut -f 1 -d : | xargs strip -g 2> /dev/null
