summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbuild_efl_stable.sh62
1 files changed, 62 insertions, 0 deletions
diff --git a/build_efl_stable.sh b/build_efl_stable.sh
new file mode 100755
index 0000000..35acea6
--- /dev/null
+++ b/build_efl_stable.sh
@@ -0,0 +1,62 @@
+#! /bin/bash
+
+EFL_VER=1.7.3
+E_VER=0.17.0-omega
+PREFIX=/opt/efl
+OPTIONS="--disable-doc"
+SUDO_PASSWD=""
+export PKG_CONFIG_PATH="$PREFIX/lib/pkgconfig"
+
+EFL_PKGS="eina eet evas ecore eio embryo edje efreet e_dbus eeze emotion ethumb elementary"
+
+function e_get() {
+ echo "fetch archives"
+ for pkg in $EFL_PKGS; do
+ arch=${pkg}-${EFL_VER}.tar.gz
+ echo " - $arch"
+ [ -f $arch ] || curl http://download.enlightenment.org/releases/$arch -o $arch || exit 1
+ done
+ e_arch=enlightenment-${E_VER}.tar.gz
+ echo " - $e_arch"
+ [ -f $e_arch ] || curl http://download.enlightenment.org/releases/$e_arch -o $e_arch || exit 1
+}
+
+function e_extract() {
+ echo "extract archives"
+ for pkg in $EFL_PKGS; do
+ echo " - $arch"
+ [ -d $pkg-${EFL_VER} ] && rm -rf $pkg-${EFL_VER}
+ arch=${pkg}-${EFL_VER}.tar.gz
+ tar -xzf $arch || exit 1
+ done
+ echo " - $e_arch"
+ [ -d enlightenment-${E_VER} ] && rm -rf enlightenment-${E_VER}
+ e_arch=enlightenment-${E_VER}.tar.gz
+ tar -xzf $e_arch || exit 1
+}
+
+function e_build() {
+ echo "build and install"
+ for pkg in $EFL_PKGS; do
+ echo " - $pkg"
+ cd $pkg-${EFL_VER} && ./autogen.sh --prefix=$PREFIX $OPTIONS && make && echo "$PASSWD" | sudo -S make install && cd .. || exit 1
+ done
+ echo " - $e_arch"
+ cd enlightenment-${E_VER} && ./configure --prefix=$PREFIX $OPTIONS && make && echo "$PASSWD" | sudo -S make install && cd .. || exit 1
+}
+
+function get_sudopwd() {
+ sudo_test=/tmp/_sudo.test
+ echo -n "enter sudo-password: " && stty -echo && read SUDO_PASSWD && stty echo || exit 1
+ [ -e $sudo_test ] && rm -f $sudo_test
+ echo "$SUDO_PASSWD" | sudo -S touch $sudo_test
+ if [ ! -e $sudo_test ]; then
+ echo "cmdline provided sudo password failed!"
+ exit 1
+ fi
+}
+
+get_sudopwd
+e_get
+e_extract
+e_build