]> gitweb.fluxo.info Git - simplepkg.git/commitdiff
mkbuild-1.1.2: mudanças nas mensagens (verbose); generic.mkSlackBuild: correção à...
authorrudson <rudson@04377dda-e619-0410-9926-eae83683ac58>
Tue, 6 Nov 2007 18:23:08 +0000 (18:23 +0000)
committerrudson <rudson@04377dda-e619-0410-9926-eae83683ac58>
Tue, 6 Nov 2007 18:23:08 +0000 (18:23 +0000)
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@452 04377dda-e619-0410-9926-eae83683ac58

trunk/mkbuild/generic.mkSlackBuild
trunk/src/mkbuild

index 18ecc6a9204e320583f9b4249db038d50ef69f0d..72f891794d85f07a1070d1bc87c40658d8296caa 100644 (file)
@@ -4,8 +4,8 @@
 ## Version 0.8.1 - Luis ( luis at riseup d0t net)
 ##
 ###################################################
-<head> off
 #!/bin/bash
+<head> off
 #
 #  [[PROGRAM NAME]].SlackBuild is free software; you can redistribute
 #  it and/or modify it under the terms of the GNU General Public License as
index eeb548c6c7bff11a39e85f06d743a140b4d0c103..99f631e3175d9b7c66c98e3dbddd0fd280db7ee2 100755 (executable)
@@ -18,8 +18,8 @@
 #
 # Based in model generic.SlackBuild of Luiz
 #
-# Version 1.1.1
-PROG_VERSION=1.1.1
+# Version 1.1.2
+PROG_VERSION=1.1.2
 PROG_NAME=`basename $0`
 
 #--------------------------------------------------------------------
@@ -330,6 +330,7 @@ function set_status {
     # $3 - file
     [ $# -ne 3 ] && mkbuild_error $ERROR_PROGRAM
     if [ "`get_status $1 $3`" != "all" ]; then
+        [ $VERBOSE -eq $on ] && echo "Section $1 $2"
         eval "sed 's/^<$1>.*$/<$1> $2/' $3" > $AUX_TMP
         mv $AUX_TMP $3
     else
@@ -359,13 +360,16 @@ function activate_sections {
 
 function build_slackbuild {
 
-    # Remove off sections
+    # Clean SlackBuild
+    # Make SlackBuild backup
     [ -e $SLACKBUILD ] && mv $SLACKBUILD $SLACKBUILD.old
+    # Remove off sections
     sed '/^<[a-z].*> off/, /^<\/[a-z].*>$/ d' $SLACKBUILD_TEMP > $AUX_TMP
     # Remove sections names
     sed '/^<.*$/ d' $AUX_TMP > $SLACKBUILD_TEMP
     # Remove clear lines
     sed ':i ; $! N; s/\n/<NL>/ ; t i' $SLACKBUILD_TEMP | sed 's/<NL><NL><NL>/<NL><NL>/g' | sed 's/<NL><NL><NL>/<NL><NL>/g' | sed 's/<NL>/\n/g' > $AUX_TMP
+    # Remove from frist line do #!/... line
     sed '1,/^#\!/ {/^#\!/ b; d }' $AUX_TMP > $SLACKBUILD
 }
 
@@ -381,6 +385,7 @@ function section_edit {
 
     # Change sections
     for i in $SECTION_LIST; do
+        [ $VERBOSE -eq $on ] && echo "Change section $i"
         if [ "$i" = "slackdesc" ]; then
             # Special slackdesc section
             slackdesc_edit > $AUX_TMP
@@ -728,30 +733,30 @@ else
 
     #
     # Start build SlackBuild
+    [ $VERBOSE -eq $on ] && echo -e "\nStart SlackBuild make"
     SLACKBUILD=${PKG_NAME}.SlackBuild
     SLACKBUILD_TEMP=$SLACKBUILD.tmp
     cp $MODEL_DIR/$MODEL $SLACKBUILD_TEMP
-    [ $VERBOSE -eq $on ] && echo -en "\nStart SlackBuild make"
 
     # Change strings from model
+    [ $VERBOSE -eq $on ] && echo -e "\nStart build $PACKAGE.SlackBuild..."
     start_build $SLACKBUILD_TEMP
-    [ $VERBOSE -eq $on ] && echo -en "\nEdit mkSlackBuild model .."
 
     # On/Off sections
+    [ $VERBOSE -eq $on ] && echo -e "\nEnable/desable sections ..."
     activate_sections
-    [ $VERBOSE -eq $on ] && echo -en ".\nEnable and desable sections .."
 
     # Change sections
+    [ $VERBOSE -eq $on ] && echo -e "\nEdit sections ..."
     section_edit
-    [ $VERBOSE -eq $on ] && echo -en ".\nChange sections .."
 
     # Remove off sections
+    [ $VERBOSE -eq $on ] && echo -e "\nRemove off sections ..."
     build_slackbuild
-    [ $VERBOSE -eq $on ] && echo -en ".\nRemove off sections .."
 
     # Make slack-required file
+    [ $VERBOSE -eq $on ] && echo -e "\nMake slack-required file ..."
     make_slack_required
-    [ $VERBOSE -eq $on ] && echo -en ".\nMake slack-required file .."
 
     if [ -e slack-required ]; then
         DEPENDENCY_LIST="`cat slack-required | awk '{print $1}' | grep '^[a-z]' | tr '\012' ' '`"
@@ -761,13 +766,13 @@ else
     fi
 
     # Others changes
+    [ $VERBOSE -eq $on ] && echo -e "\nEdit others [[]] parameters ..."
     change_others_parameters
-    [ $VERBOSE -eq $on ] && echo -en ".\nEdit others [[]] parameters ..\n"
 
     # Commit SlackBuild
     [ $COMMIT -eq $on ] && commit_slackbuild
 fi
 
 # Clear temporary files
+[ $VERBOSE -eq $on ] && echo -e "\nRemove temporary files ..."
 clear_files
-[ $VERBOSE -eq $on ] && echo -e ".\nRemove temporary files ..."