-
Notifications
You must be signed in to change notification settings - Fork 51
/
make_e2_oe1.5.sh
executable file
·35 lines (27 loc) · 1.03 KB
/
make_e2_oe1.5.sh
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
#!/bin/sh
[ -d ./tmp ] && rm -rf ./tmp
DEVKIT_ROOT=/opt/dmm/oe1.5/dm7025/build/tmp
CROSS=${DEVKIT_ROOT}/cross/mipsel-linux/bin/
export CFLAGS+="-I${DEVKIT_ROOT}/staging/mipsel-linux/include \
-I${DEVKIT_ROOT}/staging/mipsel-linux/include/libxml2 \
-I${DEVKIT_ROOT}/staging/mipsel-linux/include/python2.5"
export LDFLAGS="-L${DEVKIT_ROOT}/staging/mipsel-linux/lib"
export CC=${CROSS}gcc
export STRIP=${CROSS}strip
export SWIG=${DEVKIT_ROOT}/staging/i686-linux/bin/swig
export D=./tmp
make && make install
if [ $? != 0 ]; then
echo compile error
exit 1
fi
mkdir -p tmp/CONTROL
cp contrib/control tmp/CONTROL/
VERSION=`cat src/version.h | grep RELEASE | sed "s/.*RELEASE \"//" | sed "s/\"//" | sed "s/\ /-/" | sed "s/\ /-/" | sed "s/(//" | sed "s/)//"`
echo "Package: enigma2-plugin-systemplugins-crossepg-oe1.5" >> tmp/CONTROL/control
echo "Version: $VERSION" >> tmp/CONTROL/control
echo "Architecture: mipsel" >> tmp/CONTROL/control
sh ipkg-build -o root -g root tmp/
[ ! -d out ] && mkdir out
mv *.ipk out
echo "Package moved in `pwd`/out folder"