📄 lrk-preload
字号:
#!/bin/bash## Linux Rom Kitchen dependancy & sanity check script## Copyright (C) 2007-2008 Pau Oliva Fora - <pof@eslack.org>## This program is free software; you can redistribute it and/or modify it# under the terms of the GNU General Public License as published by the# Free Software Foundation; either version 3 of the License, or (at your# opinion) any later version. See <http://www.gnu.org/licenses/gpl.html>#export VERSION=1.1TOOLS="/usr/share/LinuxRomKitchen"APPS="$TOOLS/rgucomp.exe $TOOLS/ImgfsFromDump.exe $TOOLS/ImgfsToNb.exe $TOOLS/ImgfsToDump.exe $TOOLS/NBMerge.exe $TOOLS/RomMaster.exe $TOOLS/dumprom.exe $TOOLS/cereg400.dll $TOOLS/cecompr_nt.dll $TOOLS/RecMod.exe"ZENITY=`which zenity`GTKDIALOG=""if [ "`which gtkdialog3`" != "" ]; then GTKDIALOG=gtkdialog3elif [ "`which gtkdialog`" != "" ]; then GTKDIALOG=gtkdialogfierror() { export ERROR_DIALOG=' <window title="LRK: Error"> <vbox> <hbox> <pixmap><input file stock="gtk-dialog-error"></input></pixmap> <text wrap="true" width-chars="55"><label>"'$1'"</label></text> </hbox> <hbox> <button> <input file stock="gtk-close"></input> <label>Close</label> <action type="closewindow">ERROR_DIALOG</action> </button> </hbox> </vbox> </window> ' RESULT=`$GTKDIALOG --program=ERROR_DIALOG --center` echo $1}# we need either zenity or gtkdialog to show GUI errorsif [ -z "$GTKDIALOG" ] && [ -z $ZENITY ] ; then echo "ERROR: gtkdialog and zenity are not installed" exit 1fiif [ -z "$ZENITY" ]; then error "ERROR: zenity is not installed" exit 1fiif [ -z "$GTKDIALOG" ]; then ERROR="ERROR: gtkdialog is not installed" $ZENITY --error --text="$ERROR" echo $ERROR exit 1fiif ! [ -e $TOOLS ]; then error "ERROR: $TOOLS does not exist" exit 1fifor app in $APPS ; do if ! [ -e $app ]; then error "ERROR: LRK-tools is not installed!Download from http://www.eslack.org/pof/LRK/LRK-tools.tgzCopy the contents to $TOOLS" exit 1 fidoneif [ "`which wine`" = "" ]; then error "ERROR: wine is not installed" exit 1fiif [ "`which lcab`" = "" ]; then error "ERROR: lcab is not installedHint: http://lcab.move-to-cork.com/" exit 1fiif [ "`which dsminfo`" = "" ]; then error "ERROR: dsminfo is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which dsmbuild`" = "" ]; then error "ERROR: dsminfo is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which nbsplit`" = "" ]; then error "ERROR: nbsplit is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which ImgfsFromNb`" = "" ]; then error "ERROR: ImgfsFromNb is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which sofbuild`" = "" ]; then error "ERROR: sofbuild is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which HTCFlasher`" = "" ]; then error "ERROR: HTCFlasher is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which yangGUI`" = "" ]; then error "ERROR: yangGUI is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which HTCFlasherGUI`" = "" ]; then error "ERROR: HTCFlasherGUI is not installedHint: Make sure you have installed latest version of htc-flasher" exit 1fiif [ "`which cabextract`" = "" ]; then error "ERROR: cabextract is not installed" exit 1fiif [ "`which dos2unix`" = "" ]; then error "ERROR: dos2unix is not installed" exit 1fiif [ "`which iconv`" = "" ]; then error "ERROR: iconv is not installed" exit 1fiif ! [ -d ~/.lrk/ ]; then mkdir -p ~/.lrk/fiif ! [ -d ~/LRK/ ]; then mkdir -p ~/LRK/firm ~/.lrk/lrk.log 2>/dev/nullINFF=`ls ~/LRK/SYS/OEM_Lang_*/initflashfiles.dat`if [ -z $INFF ]; then INFF="$HOME/.lrk/initflashfiles.txt" echo "Please extract ROM packages first!" > $INFFfiif ! [ -e $HOME/.lrk/rominfo.txt ]; then echo "Please extract ROM packages first!" > ~/.lrk/rominfo.txtficd ~/LRK/if [ $? != 0 ]; then error "Problem with kitchen project folder" exit 1fi
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -