About

Supporting the site

App Repository‎ > ‎

mc-4.8.1

Overview

Midnight Commander is the classic file manager. It requires zlib, ffiglib, and ncurses. For anyone accessing the DroboFS via SSH, this is a much welcomed application. This is a statically compiled version.

This version offers one more important feature than the previous one: support for SMB servers.

Preparation

Make sure you have a cross-compiling virtual machine properly setup.

Compilation

export DEST=/mnt/DroboFS/Shares/DroboApps/mc
cd ~/code/

wget http://ftp.gnu.org/gnu/ncurses/ncurses-5.9.tar.gz
tar zxf ncurses-5.9.tar.gz
cd ncurses-5.9/
CFLAGS="$CFLAGS -O3" ./configure --host=arm-none-linux-gnueabi --prefix=$DEST --enable-widec --without-shared
make clean && make && make install.data
cd include
ln -s . ncurses
cd ..
NCURSES=`pwd`
cd ..

wget http://zlib.net/zlib-1.2.5.tar.gz
tar zxf zlib-1.2.5.tar.gz
cd zlib-1.2.5
CFLAGS="$CFLAGS -O3" ./configure --prefix=$DEST --static
make clean && make
ZLIB=`pwd`
cd ..

wget ftp://sourceware.org/pub/libffi/libffi-3.0.10.tar.gz
tar zxf libffi-3.0.10.tar.gz
cd libffi-3.0.10
CFLAGS="$CFLAGS -O3" ./configure --host=arm-none-linux-gnueabi --prefix=$DEST --disable-shared
make clean && make
FFI=`pwd`
cd ..

pushd /usr/bin/
sudo ln -s python2.6 python2.5
popd

wget http://ftp.gnome.org/pub/gnome/sources/glib/2.31/glib-2.31.4.tar.xz
tar Jxf glib-2.31.4.tar.xz
cd glib-2.31.4
ZLIB_CFLAGS="-I$ZLIB" ZLIB_LIBS="-L$ZLIB -lz" LIBFFI_CFLAGS="-I$FFI/arm-none-linux-gnueabi/include" LIBFFI_LIBS="-L$FFI/arm-none-linux-gnueabi/.libs -lffi" CFLAGS="$CFLAGS -O3 ${ZLIB_CFLAGS}" LDFLAGS="$LDFLAGS ${ZLIB_LIBS}" glib_cv_stack_grows=no glib_cv_uscore=no ac_cv_func_posix_getpwuid_r=yes ac_cv_func_posix_getgrgid_r=yes ./configure --host=arm-none-linux-gnueabi --prefix=$DEST --enable-static --disable-shared
make clean && make
pushd glib/.libs/
ln -s libglib-2.0.a libglib.a
popd
GLIB=`pwd`
cd ..

wget http://www.midnight-commander.org/downloads/mc-4.8.1.tar.xz
tar Jxf mc-4.8.1.tar.xz
cd mc-4.8.1
fu_cv_sys_stat_statfs2_bsize=yes samba_cv_HAVE_GETTIMEOFDAY_TZ=yes ac_cv_search_has_colors="-lncursesw" GLIB_CFLAGS="-I$GLIB -I$GLIB/glib" GLIB_LIBDIR="$GLIB/glib/.libs" GLIB_LIBS="-L$GLIB/glib/.libs" GMODULE_CFLAGS="-I$GLIB" GMODULE_LIBS="-L$GLIB/gmodule/.libs" CFLAGS="$CFLAGS -O3 $GLIB_CFLAGS $GMODULE_CFLAGS" LDFLAGS="$GLIB_LIBS $GMODULE_LIBS" LIBS="-lglib-2.0 -lgmodule-2.0" ./configure --host=arm-none-linux-gnueabi --prefix=$DEST --with-screen=ncurses --with-ncurses-includes="$NCURSES/include" --with-ncurses-libs="$NCURSES/lib" --without-gpm-mouse --with-glib-static --enable-vfs-smb --without-x --with-smb-configdir=$DEST/etc --with-smb-codepagedir=$DEST/etc/codepages
make clean && make && make install

Packaging

cd $DEST
~/bin/package.sh

Installing

Download the TGZ file below and place it in you DroboApps share. If you do not have SSH access, reboot your Drobo. Otherwise, SSH in and type:

/usr/bin/DroboApps.sh install

Final remarks

This is not a conventional DroboApp in the sense that once installed, it is ready for use. This one just makes the mc binary available for further use, and does not attempt to change the DroboFS configuration in any way.

Please visit the DroboSpace forums to leave your comments, suggestions and feedback.

ċ
mc.tgz
Download
DroboApp for DroboFS  2912k v. 1 Dec 19, 2011, 8:05 AM Ricardo Padilha
Comments