aboutsummaryrefslogtreecommitdiff
path: root/trunk/src/mkbuild
diff options
context:
space:
mode:
authorrudson <rudson@04377dda-e619-0410-9926-eae83683ac58>2007-03-17 05:16:58 +0000
committerrudson <rudson@04377dda-e619-0410-9926-eae83683ac58>2007-03-17 05:16:58 +0000
commitadc4bf8aef88e2ede163ae3c83df0deeddfa5d36 (patch)
treea606e0d9ae570d4054451310203ebcd798ebea23 /trunk/src/mkbuild
parentb63471ec1d3bfc84454738c5572a3756ee9c035c (diff)
downloadsimplepkg-adc4bf8aef88e2ede163ae3c83df0deeddfa5d36.tar.gz
simplepkg-adc4bf8aef88e2ede163ae3c83df0deeddfa5d36.tar.bz2
Correção ao simplepkg.SlackBuild
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@206 04377dda-e619-0410-9926-eae83683ac58
Diffstat (limited to 'trunk/src/mkbuild')
-rwxr-xr-xtrunk/src/mkbuild39
1 files changed, 21 insertions, 18 deletions
diff --git a/trunk/src/mkbuild b/trunk/src/mkbuild
index eb8b6a7..6dff76e 100755
--- a/trunk/src/mkbuild
+++ b/trunk/src/mkbuild
@@ -12,8 +12,8 @@
# Turn off debug
set +x
#
-# Version 0.9.14
-PROG_VERSION=0.9.14
+# Version 0.9.15
+PROG_VERSION=0.9.15
#--------------------------------------------------------------------
# Functions
@@ -267,7 +267,7 @@ function edit_configure()
$MK_TMPSRC/configure --help > $CONFIG_HELP
config_help
[ "$( cat $CONFIG_HELP | egrep '/usr/local')" != "" ] && MK_PREFIX=/usr || MK_PREFIX=/opt/kde
- MK_OPTIONS=""
+ MK_OPTIONS=" "
local ANS0=1
while [ $ANS0 -eq 1 ]; do
@@ -302,7 +302,7 @@ function edit_configure()
done
# Configure
- dialog --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title " Execute ./configure below? " --title "$MK_TITLE" --yesno "./configure --prefix=$MK_PREFIX $MK_OPTIONS" 6 70
+ dialog --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title " Execute ./configure below? " --yesno "./configure --prefix=$MK_PREFIX $MK_OPTIONS" 6 70
if [ $? -eq 0 ]; then
(
cd $MK_TMPSRC
@@ -313,7 +313,7 @@ function edit_configure()
read ANS0
fi
- dialog --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title " Configure line is ok? " --title "$MK_TITLE" --yesno "./configure --prefix=$MK_PREFIX $MK_OPTIONS" 6 70
+ dialog --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title " Configure line is ok? " --yesno "./configure --prefix=$MK_PREFIX $MK_OPTIONS" 6 70
ANS0=$?
done
@@ -371,9 +371,8 @@ function edit_arch()
# Change string $1 to $2 in all files in the current directory
function change_strings()
{
- # echo "$1 -> $2"
[ $# -ne 2 ] && mk_exit 1
- [ -z "$2" ] && return 0
+ #[ -z "$2" ] && return 0
eval "grep -l \"\[\[$1\]\]\" *" | while read FILE; do
edit_file "$1" "$2" $FILE
done
@@ -730,18 +729,22 @@ function edit_menu()
FLAG=`echo $STATUS | awk '{print $1}'`
INDEX=`echo $STATUS | awk '{print $2}'`
if [ "$FLAG" = "on" ]; then
- SECTION_FLAG[$INDEX]=`dialog --stdout --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title "$MK_TITLE" --radiolist "Change status from $SELECT" 0 0 0 "on" "enable section" "on" "off" "desable section" "off"`
+ SECTION_FLAG[$INDEX]=`dialog --stdout --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title "$MK_TITLE" --radiolist "Change $SELECT status?" 0 0 0 "on" "enable section" "on" "off" "desable section" "off"`
elif [ "$FLAG" = "off" ]; then
- SECTION_FLAG[$INDEX]=`dialog --stdout --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title "$MK_TITLE" --radiolist "Change status from $SELECT" 0 0 0 "on" "enable section" "off" "off" "desable section" "on"`
+ SECTION_FLAG[$INDEX]=`dialog --stdout --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title "$MK_TITLE" --radiolist "Change $SELECT status?" 0 0 0 "on" "enable section" "off" "off" "desable section" "on"`
fi
- if [ "${SECTION_FLAG[$INDEX]}" = "on" -o "${SECTION_FLAG[$INDEX]}" = "all" ]; then
- if [ "$SELECT" = "md5sum_download_and_check" ]; then
- md5sum_edit ${SELECT}_${MK_PKGNAME}.mkbuild
-# elif [ "$SELECT" = "gpg_signature_check" ]; then
-# gpg_edit
- else
- $MK_EDITOR ${SELECT}_${MK_PKGNAME}.mkbuild
+ if [ $? -eq 0 ]; then
+ if [ "${SECTION_FLAG[$INDEX]}" = "on" -o "${SECTION_FLAG[$INDEX]}" = "all" ]; then
+ if [ "$SELECT" = "md5sum_download_and_check" ]; then
+ md5sum_edit ${SELECT}_${MK_PKGNAME}.mkbuild
+# elif [ "$SELECT" = "gpg_signature_check" ]; then
+# gpg_edit
+ else
+ $MK_EDITOR ${SELECT}_${MK_PKGNAME}.mkbuild
+ fi
fi
+ else
+ SECTION_FLAG[$INDEX]=$FLAG
fi
fi
done
@@ -754,7 +757,7 @@ function md5sum_edit()
local FILE=$1
if ( grep '\[\[MD5SUM EXTENSION\]\]' $FILE &>/dev/null ); then
- SELECT=`dialog --stdout --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title "$MK_TITLE" --radiolist "Select one option" 0 0 0 "1" "{SRC//.tar.[[SOURCE EXTENSION]]}.[[MD5SUM EXTENSION]]" on "2" "SRC.[[MD5SUM EXTENSION]]" off "3" "MK5SUM CODE" off`
+ SELECT=`dialog --stdout --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" --title "$MK_TITLE" --radiolist "Select one option" 0 0 0 "1" "$MK_SRC_NAME-$MK_VERSION.[[MD5SUM EXT]]" on "2" "$MK_SRCNAME.[[MD5SUM EXT]]" off "3" "MK5SUM CODE" off`
case $SELECT in
1)
@@ -970,7 +973,7 @@ while [ $ANS0 -ne 0 ]; do
ANS0=`dialog --stdout --backtitle "Make SlackBuild $PROG_VERSION [$MK_PKGNAME]" \
--cancel-label "Exit" --menu "Main Menu:" 0 0 0 \
"1" "Create New SlackBuild" \
- "2" "Open edited SlackBuild" \
+ "2" "Open mkSlackBuild" \
"0" "Exit"`
if [ $? -ne 0 ]; then