Magellan Linux

Diff of /trunk/mage/usr/lib/mage/smage2.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 833 by niro, Wed Apr 29 20:20:46 2009 UTC revision 875 by niro, Thu May 21 19:06:26 2009 UTC
# Line 20  SMAGENAME="$1" Line 20  SMAGENAME="$1"
20  SMAGESUFFIX="smage2"  SMAGESUFFIX="smage2"
21  MLIBDIR=/usr/lib/mage  MLIBDIR=/usr/lib/mage
22  SMAGEVERSION="$( < ${MLIBDIR}/version)"  SMAGEVERSION="$( < ${MLIBDIR}/version)"
23    SMAGE_LOG_CMD="tee -a /var/log/smage/${PKGNAME}.log"
24    
25    
26  ## only for tests -> normally in /etc/rc.d/init.d/functions  ## only for tests -> normally in /etc/rc.d/init.d/functions
27  COLRED="\033[1;6m\033[31m"  COLRED="\033[1;6m\033[31m"
# Line 937  source_pkg_build() Line 939  source_pkg_build()
939   echo -e "${COLGREEN}Source package ${COLBLUE}${PNAME}-${PVER}-${PBUILD}.${SRCPKGSUFFIX} ${COLGREEN}successfully builded.${COLDEFAULT}"   echo -e "${COLGREEN}Source package ${COLBLUE}${PNAME}-${PVER}-${PBUILD}.${SRCPKGSUFFIX} ${COLGREEN}successfully builded.${COLDEFAULT}"
940  }  }
941    
942    step_by_step()
943    {
944     if [[ ${STEP_BY_STEP} = true ]]
945     then
946     echo "${COLRED}Step-by-step enabled! Paused after $1.${COLDEFAULT}"
947     echo "Press [enter] to continue"
948     read
949     fi
950    }
951    
952    
953  # print out our version  # print out our version
954  showversion  showversion
# Line 1203  then Line 1215  then
1215   mage rmstamp   mage rmstamp
1216  fi  fi
1217    
1218  src_prepare || die "src_prepare failed"  # setup build loggins
1219  src_compile || die "src_compile failed"  [[ ! -d /var/log/smage ]] && install -d /var/log/smage
1220  src_install || die "src_install failed"  echo -e "### Build started on $(date) ###\n" > /var/log/smage/${PKGNAME}.log
1221    
1222    ( src_prepare || die "src_prepare failed" ) | ${SMAGE_LOG_CMD}
1223    step_by_step $_
1224    ( src_compile || die "src_compile failed" ) | ${SMAGE_LOG_CMD}
1225    step_by_step $_
1226    ( src_install || die "src_install failed" ) | ${SMAGE_LOG_CMD}
1227    step_by_step $_
1228    
1229    
1230  # compressing doc, info & man files  # compressing doc, info & man files
# Line 1286  case ${NOPKGBUILD} in Line 1305  case ${NOPKGBUILD} in
1305   ;;   ;;
1306  esac  esac
1307    
1308    if [[ ${SMAGE_BUILD_LOGGING} != false ]]
1309    then
1310     bzip2 -9f /var/log/smage/${PKGNAME}.log
1311    else
1312     [[ -f /var/log/smage/${PKGNAME}.log ]] && rm /var/log/smage/${PKGNAME}.log
1313    fi
1314    
1315  # for sure  # for sure
1316  unset NOPKGBUILD  unset NOPKGBUILD
1317  unset NOSTRIP  unset NOSTRIP

Legend:
Removed from v.833  
changed lines
  Added in v.875