From 449bc36e72973f151f73fc11901a4ee47192145d Mon Sep 17 00:00:00 2001 From: Michael Neves Date: Thu, 3 Jan 2013 16:51:17 +0100 Subject: check if file is ELF fix --- mltk | 33 +++++++++++++++++++++++---------- 1 file changed, 23 insertions(+), 10 deletions(-) (limited to 'mltk') diff --git a/mltk b/mltk index b7ade22d..bb9789fd 100755 --- a/mltk +++ b/mltk @@ -1,4 +1,6 @@ +#!/bin/bash # ----------------------------------------------------------------------------- +# # Copyright (c) 2011 - OpenSLX GmbH # # This program is free software distributed under the GPL version 2. @@ -13,27 +15,38 @@ # Mini-Linux Toolkit # # ----------------------------------------------------------------------------- -#!/bin/bash - SELF=$(readlink -f $0) ROOT_DIR=$(dirname ${SELF}) +banner () { + echo -e "\t __ __ __ " + echo -e "\t.--------.| | | |_| |--." + echo -e "\t| || |_| _| < " + echo -e "\t|__|__|__||____|____|__|__|" + echo -e "\t " + echo -e "\t ** OpenSLX Project // 2011 **" + echo -e "\t http://lab.openslx.org/" + echo -e "" +} + print_usage() { echo "Toolkit for creating preboot mini-linux for OpenSLX NG (mltk)" echo "Usage: $(basename ${SELF}) MODULE [OPTION]" - echo -e " MODULE:" - echo -e " \t core \t minimal initramfs (stage 3.1) to mount the system-container (stage 3.2)." - echo -e " \t tools \t minimal systemd-based rootfs including basic tools." + echo " MODULE:" + echo -e " core \t minimal initramfs (stage 3.1) to mount the system-container (stage 3.2)." + echo -e " tools \t minimal systemd-based rootfs including basic tools." echo -e " OPTION:" - echo -e " \t build \t builds [MODULE]" - echo -e " \t clean \t clean build files for [MODULE]" + echo -e " build \t builds [MODULE]" + echo -e " clean \t clean build files for [MODULE]" echo -e "" echo -e " Module specific option:" - echo -e " \t tools \t build [TOOL]" - echo -e " \t \t TOOL can be: \t base, busybox, dbus, udev, systemd, plymouth" + echo -e " tools \t build [TOOL]" + echo -e " TOOL can be: \t base, busybox, dbus, udev, systemd, plymouth" } +banner + if [ "x$1" = "x" ]; then print_usage exit 0 @@ -58,7 +71,7 @@ if [ "x$1" = "xcore" ]; then exit 1 fi elif [ "x$1" = "xtools" ]; then - [ -e ${SETUP_TOOLS} ] && . ${SETUP_TOOLS} + [ -e ${SETUP_TOOLS} ] && . $SETUP_TOOLS shift if [ "x$1" = "xbuild" ]; then # shift away first 2 parameters -- cgit v1.2.3-55-g7522