Magellan Linux

Diff of /branches/mage-next/src/smage2.sh

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

revision 1593 by niro, Thu Dec 29 15:20:20 2011 UTC revision 1600 by niro, Mon Jan 2 15:51:28 2012 UTC
# Line 177  download_sources() Line 177  download_sources()
177   fi   fi
178    
179   echo -e "${COLBLUE}==>${COLGREEN} fetching ${uri}${COLDEFAULT}"   echo -e "${COLBLUE}==>${COLGREEN} fetching ${uri}${COLDEFAULT}"
180   mdownload --uri "${uri}" --dir "${outputdir}" || die "Could not download '${uri}'"   # do not die here, mchecksum catches download errors
181     mdownload --uri "${uri}" --dir "${outputdir}"
182    
183   # unset them to be sure   # unset them to be sure
184   unset uri   unset uri
# Line 464  mstriplibtoolarchive() Line 465  mstriplibtoolarchive()
465   local stripdir="$@"   local stripdir="$@"
466    
467   [[ -z ${stripdir} ]] && stripdir="${BINDIR}"   [[ -z ${stripdir} ]] && stripdir="${BINDIR}"
468   find ${stripdir} ! -type d -name \*.la | xargs file | grep "libtool library" | cut -f 1 -d : | xargs --no-run-if-empty rm -f -- 2> /dev/null   find ${stripdir} ! -type d -name \*.la | xargs --no-run-if-empty file | grep "libtool library" | cut -f 1 -d : | xargs --no-run-if-empty rm -f -- 2> /dev/null
469  }  }
470    
471  mpurgetargets()  mpurgetargets()
# Line 793  regen_mage_tree() Line 794  regen_mage_tree()
794   unset STATE   unset STATE
795   unset DESCRIPTION   unset DESCRIPTION
796   unset HOMEPAGE   unset HOMEPAGE
797   unset PKGTYPE   # unset PKGTYPE <-- don't do that either; smage needs this var
798   unset INHERITS   unset INHERITS
799   unset DEPEND   unset DEPEND
800   unset SDEPEND   unset SDEPEND
# Line 1509  echo Line 1510  echo
1510  if mqueryfeature "!compressdoc"  if mqueryfeature "!compressdoc"
1511  then  then
1512   echo -e "!compressdoc detected; documentation will not be compressed ..."   echo -e "!compressdoc detected; documentation will not be compressed ..."
1513    elif mqueryfeature "!pkgbuild"
1514    then
1515     echo "!pkgbuild detected; skipping documentation compression..."
1516  else  else
1517   # compressing doc, info & man files   # compressing doc, info & man files
1518   if [[ -n ${SPLIT_PACKAGES} ]]   if [[ -n ${SPLIT_PACKAGES} ]]
# Line 1524  fi Line 1528  fi
1528    
1529  if mqueryfeature "!libtool"  if mqueryfeature "!libtool"
1530  then  then
1531     if mqueryfeature "!pkgbuild"
1532     then
1533     echo "!pkgbuild detected; skipping libtool archive stripping ..."
1534     else
1535   if [[ -n ${SPLIT_PACKAGES} ]]   if [[ -n ${SPLIT_PACKAGES} ]]
1536   then   then
1537   for subpackage in ${SPLIT_PACKAGES}   for subpackage in ${SPLIT_PACKAGES}
# Line 1535  then Line 1543  then
1543   echo -e "${COLBLUE}===${COLGREEN} stripping libtool archives ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} stripping libtool archives ...${COLDEFAULT}"
1544   mstriplibtoolarchive ${BINDIR}   mstriplibtoolarchive ${BINDIR}
1545   fi   fi
1546     fi
1547  fi  fi
1548    
1549  if mqueryfeature "purge"  if mqueryfeature "purge"
1550  then  then
1551     if mqueryfeature "!pkgbuild"
1552     then
1553     echo "!pkgbuild detected; skipping file purgation..."
1554     else
1555   if [[ -n ${SPLIT_PACKAGES} ]]   if [[ -n ${SPLIT_PACKAGES} ]]
1556   then   then
1557   for subpackage in ${SPLIT_PACKAGES}   for subpackage in ${SPLIT_PACKAGES}
# Line 1550  then Line 1563  then
1563   echo -e "${COLBLUE}===${COLGREEN} purging all purge targets ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} purging all purge targets ...${COLDEFAULT}"
1564   mpurgetargets ${BINDIR}   mpurgetargets ${BINDIR}
1565   fi   fi
1566     fi
1567  fi  fi
1568    
1569  # stripping all bins and libs  # stripping all bins and libs
1570  if mqueryfeature "!strip"  if mqueryfeature "!strip"
1571  then  then
1572   echo -e "!strip detected; Package will not be stripped ..."   echo -e "!strip detected; Package will not be stripped ..."
1573    elif mqueryfeature "!pkgbuild"
1574    then
1575     echo "!pkgbuild detected; skipping stripping of the package ..."
1576  else  else
1577   if [[ -n ${SPLIT_PACKAGES} ]]   if [[ -n ${SPLIT_PACKAGES} ]]
1578   then   then
1579   for subpackage in ${SPLIT_PACKAGES}   for subpackage in ${SPLIT_PACKAGES}
1580   do   do
1581   echo -e "${COLBLUE}===${COLGREEN} stripping binaries for '${subpackage}' ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} stripping binaries for '${subpackage}' ...${COLDEFAULT}"
1582   mstripbins ${BINDIR}_${subpackage}   mstripbins ${BINDIR}_${subpackage}
1583   echo -e "${COLBLUE}===${COLGREEN} stripping dynamic libraries for '${subpackage}' ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} stripping dynamic libraries for '${subpackage}' ...${COLDEFAULT}"
1584   mstriplibs ${BINDIR}_${subpackage}   mstriplibs ${BINDIR}_${subpackage}
1585   echo -e "${COLBLUE}===${COLGREEN} stripping static libraries for '${subpackage}' ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} stripping static libraries for '${subpackage}' ...${COLDEFAULT}"
1586   mstripstatic ${BINDIR}_${subpackage}   mstripstatic ${BINDIR}_${subpackage}
1587   done   done
1588   else   else
1589   echo -e "${COLBLUE}===${COLGREEN} stripping binaries ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} stripping binaries ...${COLDEFAULT}"
1590   mstripbins ${BINDIR}   mstripbins ${BINDIR}
1591   echo -e "${COLBLUE}===${COLGREEN} stripping dynamic libraries ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} stripping dynamic libraries ...${COLDEFAULT}"
1592   mstriplibs ${BINDIR}   mstriplibs ${BINDIR}
1593   echo -e "${COLBLUE}===${COLGREEN} stripping static libraries ...${COLDEFAULT}"   echo -e "${COLBLUE}===${COLGREEN} stripping static libraries ...${COLDEFAULT}"
1594   mstripstatic ${BINDIR}   mstripstatic ${BINDIR}
1595   fi   fi
1596  fi  fi
1597    
1598  if mqueryfeature "!buildpkg"  if mqueryfeature "!pkgbuild"
1599  then  then
1600   echo -e "!buildpkg detected; Package will not be build ..."   echo -e "!pkgbuild detected; Package will not be build ..."
1601  else  else
1602   # build several targets   # build several targets
1603   if [[ -n ${MAGE_TARGETS} ]]   if [[ -n ${MAGE_TARGETS} ]]
# Line 1620  else Line 1637  else
1637   export PNAME="${subpackage}"   export PNAME="${subpackage}"
1638   split_info_${PNAME}   split_info_${PNAME}
1639    
1640   # jump to next one if !buildpkg is set in split_info   # jump to next one if !pkgbuild is set in split_info
1641   mqueryfeature "!buildpkg" && continue   mqueryfeature "!pkgbuild" && continue
1642    
1643   # check if an special subpackage_pkgbuild exists   # check if an special subpackage_pkgbuild exists
1644   if typeset -f ${PNAME}_pkgbuild > /dev/null   if typeset -f ${PNAME}_pkgbuild > /dev/null

Legend:
Removed from v.1593  
changed lines
  Added in v.1600