Magellan Linux

Diff of /branches/mage-next/src/pkg_all_sources.in

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

revision 423 by niro, Mon Feb 5 17:11:36 2007 UTC revision 2268 by niro, Fri Oct 25 06:48:57 2013 UTC
# Line 1  Line 1 
1  #!/bin/bash  #!/bin/bash
2  # build all source packages for given distribution  # build all source packages for given distribution
3    # $Id$
4    
5  if [[ $(id -u) != 0 ]]  : ${MAGERC="/etc/mage.rc"}
6    
7    source /etc/mage.rc.global
8    source ${MAGERC}
9    source ${MLIBDIR}/mage4.functions.sh
10    source ${MLIBDIR}/smage2.functions.sh
11    
12    if ! have_root_privileges
13  then  then
14   echo "You must be r00t"   echo "You must be r00t"
15   exit 1   exit 1
# Line 15  then Line 23  then
23   exit 1   exit 1
24  fi  fi
25    
 source /etc/mage.rc.global  
 source /etc/mage.rc  
   
 sminclude() { true; }  
   
26  blacklisted()  blacklisted()
27  {  {
28   local EXCLUDED="${MROOT}/etc/mage-profile/package.blacklist-${ARCH}-${DISTRI}"   local EXCLUDED="${MROOT}/etc/mage-profile/package.blacklist-${ARCH}-${DISTRI}"
# Line 29  blacklisted() Line 32  blacklisted()
32    
33   local SMAGEFILE="$1"   local SMAGEFILE="$1"
34    
35   source ${SMAGEFILE}   smagesource ${SMAGEFILE}
36    
37   local EXPCAT EXPNAME EXPVER EXPBUILD   local EXPCAT EXPNAME EXPVER EXPBUILD
38   while read EXPCAT EXPNAME EXPVER EXPBUILD   while read EXPCAT EXPNAME EXPVER EXPBUILD
39   do   do
40   # ignore spaces and comments   # ignore spaces and comments
41           case "${EXPCAT}" in   case "${EXPCAT}" in
42                   \#*|"") continue ;;   \#*|"") continue ;;
43           esac   esac
44    
45   # exclude full pver   # exclude full pver
46   if [[ -n ${PCATEGORIE} ]] && [[ -n ${PNAME} ]] &&   if [[ -n ${PCAT} ]] && [[ -n ${PNAME} ]] &&
47   [[ -n ${EXPCAT} ]] && [[ -n ${EXPNAME} ]] &&   [[ -n ${EXPCAT} ]] && [[ -n ${EXPNAME} ]] &&
48   [[ -n ${PVER} ]] && [[ -n ${PBUILD} ]] &&   [[ -n ${PVER} ]] && [[ -n ${PBUILD} ]] &&
49   [[ -n ${EXPVER} ]] && [[ -n ${EXPBUILD} ]]   [[ -n ${EXPVER} ]] && [[ -n ${EXPBUILD} ]]
50   then   then
51   [[ ${EXPCAT}/${EXPNAME}-${EXPVER}-${EXPBUILD} = ${PCATEGORIE}/${PNAME}-${PVER}-${PBUILD} ]] && return 1   [[ ${EXPCAT}/${EXPNAME}-${EXPVER}-${EXPBUILD} = ${PCAT}/${PNAME}-${PVER}-${PBUILD} ]] && return 1
52   fi   fi
53    
54   # exclude pcat/pname only   # exclude pcat/pname only
55   if [[ -n ${PCATEGORIE} ]] && [[ -n ${PNAME} ]] &&   if [[ -n ${PCAT} ]] && [[ -n ${PNAME} ]] &&
56   [[ -n ${EXPCAT} ]] && [[ -n ${EXPNAME} ]] &&   [[ -n ${EXPCAT} ]] && [[ -n ${EXPNAME} ]] &&
57   [[ -z ${EXPVER} ]] && [[ -z ${EXPBUILD} ]]   [[ -z ${EXPVER} ]] && [[ -z ${EXPBUILD} ]]
58   then   then
59   [[ ${EXPCAT}/${EXPNAME} = ${PCATEGORIE}/${PNAME} ]] && return 1   [[ ${EXPCAT}/${EXPNAME} = ${PCAT}/${PNAME} ]] && return 1
60   fi   fi
61   done << EOF   done << EOF
62  $(cat ${EXCLUDED}; echo)  $(cat ${EXCLUDED}; echo)

Legend:
Removed from v.423  
changed lines
  Added in v.2268