[leaf-commits] src/bering-uclibc4/source/bridge bridge-utils-1.2.tar.gz, NONE, 1.1 bridge_if-post-down, NONE, 1.1 bridge_if-pre-up, NONE, 1.1 bridge_if-up, NONE, 1.1 buildtool.cfg, NONE, 1.1 buildtool.mk, NONE, 1.1

Andrew <[email protected]>
Newsgroups gmane.linux.leaf.cvs
Message-ID <[email protected]>
Update of /cvsroot/leaf/src/bering-uclibc4/source/bridge
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv19996/source/bridge

Added Files:
	bridge-utils-1.2.tar.gz bridge_if-post-down bridge_if-pre-up 
	bridge_if-up buildtool.cfg buildtool.mk 
Log Message:
Fixed perl modules path


--- NEW FILE: bridge-utils-1.2.tar.gz ---
(This appears to be a binary file; contents omitted.)

--- NEW FILE: bridge_if-pre-up ---
#!/bin/sh

# You don't usually need to touch this file at all, the full configuration
# of the bridge can be done in a standard way on /etc/network/interfaces.

# Have a look at /usr/share/doc/bridge-utils/README.Debian.gz if you want
# more info about the way on wich a bridge is set up on Debian.

if [ ! -x /usr/sbin/brctl ]
then
  exit 0
fi

case "$IF_BRIDGE_PORTS" in
    "")
	exit 0
	;;
    none)
	INTERFACES=""
	;;
    all)
	INTERFACES=`grep eth /proc/net/dev|sed 's/\(\ *\)\(eth[^:]*\)\(.*\)/\2/'`
	;;
    *)
	INTERFACES="$IF_BRIDGE_PORTS"
	;;
esac

brctl addbr $IFACE &&

for i in $INTERFACES
do
  if [ -x /etc/network/if-pre-up.d/vlan ]; then
    env IFACE=$i /etc/network/if-pre-up.d/vlan
  fi
  brctl addif $IFACE $i && ip link set dev $i up
done

if [ "$IF_BRIDGE_AGEING" ]
then
  brctl setageing $IFACE $IF_BRIDGE_AGEING
fi

if [ "$IF_BRIDGE_BRIDGEPRIO" ]
then
  brctl setbridgeprio $IFACE $IF_BRIDGE_BRIDGEPRIO
fi

if [ "$IF_BRIDGE_FD" ]
then
  brctl setfd $IFACE $IF_BRIDGE_FD
fi

if [ "$IF_BRIDGE_GCINT" ]
then
  brctl setgcint $IFACE $IF_BRIDGE_GCINT
fi

if [ "$IF_BRIDGE_HELLO" ]
then
  brctl sethello $IFACE $IF_BRIDGE_HELLO
fi

if [ "$IF_BRIDGE_MAXAGE" ]
then
  brctl setmaxage $IFACE $IF_BRIDGE_MAXAGE
fi

if [ "$IF_BRIDGE_PATHCOST" ]
then
  brctl setpathcost $IFACE $IF_BRIDGE_PATHCOST
fi

if [ "$IF_BRIDGE_PORTPRIO" ]
then
  brctl setportprio $IFACE $IF_BRIDGE_PORTPRIO
fi

if [ "$IF_BRIDGE_STP" ]
then
  brctl stp $IFACE $IF_BRIDGE_STP
fi

--- NEW FILE: bridge_if-post-down ---
#!/bin/sh

# You don't usually need to touch this file at all, the full configuration
# of the bridge can be done in a standard way on /etc/network/interfaces.

# Have a look at /usr/share/doc/bridge-utils/README.Debian.gz if you want
# more info about the way on wich a bridge is set up on Debian.

if [ ! -x /usr/sbin/brctl ]
then
  exit 0
fi

case "$IF_BRIDGE_PORTS" in
    "")
	exit 0
	;;
    none)
	INTERFACES=""
	;;
    all)
	INTERFACES=`grep eth /proc/net/dev|sed 's/\(\ *\)\(eth[^:]*\)\(.*\)/\2/'`
	;;
    *)
	INTERFACES="$IF_BRIDGE_PORTS"
	;;
esac

brctl delbr $IFACE

for i in $INTERFACES
do
  ip link set $i down
done

--- NEW FILE: buildtool.mk ---
# makefile for bridge
include $(MASTERMAKEFILE)

BRIDGE-UTILS_DIR:=bridge-utils-1.2
BRIDGE-UTILS_TARGET_DIR:=$(BT_BUILD_DIR)/bridge
export AUTOCONF=$(BT_STAGING_DIR)/bin/autoconf
PERLVER=$(shell ls $(BT_STAGING_DIR)/usr/lib/perl5 2>/dev/null)

$(BRIDGE-UTILS_DIR)/.source:
	zcat $(BRIDGE-UTILS_SOURCE) | tar -xvf -
#	zcat $(BRIDGE-UTILS_PATCH1) | patch -d $(BRIDGE-UTILS_DIR) -p1
	touch $(BRIDGE-UTILS_DIR)/.source

source: $(BRIDGE-UTILS_DIR)/.source
                        
$(BRIDGE-UTILS_DIR)/.configured: $(BRIDGE-UTILS_DIR)/.source
	(cd $(BRIDGE-UTILS_DIR) ;  export PERLLIB=$(BT_STAGING_DIR)/usr/lib/perl5/$(PERLVER); \
	$(AUTOCONF) ; CC=$(TARGET_CC) LD=$(TARGET_LD) CFLAGS="$(BT_COPT_FLAGS)" \
	./configure --prefix=/usr --with-linux-headers=$(BT_LINUX_DIR)/include )
	touch $(BRIDGE-UTILS_DIR)/.configured
                                                                 
$(BRIDGE-UTILS_DIR)/.build: $(BRIDGE-UTILS_DIR)/.configured
	mkdir -p $(BRIDGE-UTILS_TARGET_DIR)
	mkdir -p $(BRIDGE-UTILS_TARGET_DIR)/usr/sbin
	mkdir -p $(BRIDGE-UTILS_TARGET_DIR)/etc/network/if-pre-up.d
	mkdir -p $(BRIDGE-UTILS_TARGET_DIR)/etc/network/if-post-down.d
	mkdir -p $(BRIDGE-UTILS_TARGET_DIR)/etc/network/if-up.d
	make -C $(BRIDGE-UTILS_DIR) all  
	-$(BT_STRIP) $(BT_STRIP_BINOPTS) $(BRIDGE-UTILS_DIR)/brctl/brctl
	cp -a $(BRIDGE-UTILS_DIR)/brctl/brctl $(BRIDGE-UTILS_TARGET_DIR)/usr/sbin
	cp -a bridge_if-pre-up $(BRIDGE-UTILS_TARGET_DIR)/etc/network/if-pre-up.d/bridge	
	cp -a bridge_if-post-down $(BRIDGE-UTILS_TARGET_DIR)/etc/network/if-post-down.d/bridge
	cp -a bridge_if-up $(BRIDGE-UTILS_TARGET_DIR)/etc/network/if-up.d/bridge
	cp -a $(BRIDGE-UTILS_TARGET_DIR)/* $(BT_STAGING_DIR)
	touch $(BRIDGE-UTILS_DIR)/.build

build: $(BRIDGE-UTILS_DIR)/.build
                                                                                         
clean:
	make -C $(BRIDGE-UTILS_DIR) clean
	rm -rf $(BRIDGE-UTILS_TARGET_DIR)
	rm -f $(BRIDGE-UTILS_DIR)/.build
	rm -f $(BRIDGE-UTILS_DIR)/.configured
                                                                                                                 
srcclean: clean
	rm -rf $(BRIDGE-UTILS_DIR) 

--- NEW FILE: bridge_if-up ---
#!/bin/sh

# You don't usually need to touch this file at all, the full configuration
# of the bridge can be done in a standard way on /etc/network/interfaces.

# Have a look at /usr/share/doc/bridge-utils/README.Debian.gz if you want
# more info about the way on wich a bridge is set up on Debian.

if [ ! "$IF_BRIDGE_PORTS" -o ! -x /usr/sbin/brctl ]
then
  exit 0
fi

if [ "$IF_BRIDGE_MAXWAIT" ]
then
  MAXWAIT=$IF_BRIDGE_MAXWAIT
else
  MAXWAIT=`brctl showstp $IFACE|sed -n 's/^.*forward delay[ 	]*\(.*\)\..*bridge forward delay[ 	]*\(.*\)\..*$/\1 \2/p'`
  if [ "$MAXWAIT" ]
  then
    if [ ${MAXWAIT% *} -gt ${MAXWAIT#* } ]
    then
      MAXWAIT=$((2*(${MAXWAIT% *}+1)))
    else
      MAXWAIT=$((2*(${MAXWAIT#* }+1)))
    fi
  else
    if [ "$IF_BRIDGE_FD" ]
    then
      MAXWAIT=$((2*(${IF_BRIDGE_FD%.*}+1)))
    else
      MAXWAIT=32
    fi
    echo Waiting $MAXWAIT seconds for $IFACE to get ready.
    sleep $MAXWAIT
    MAXWAIT=0
  fi
fi

if [ "$MAXWAIT" != 0 ]
then
  echo "Waiting for $IFACE to get ready (MAXWAIT is $MAXWAIT seconds)."

  unset BREADY
  COUNT=0

  while [ ! "$BREADY" -a $COUNT -lt $MAXWAIT ]
  do
    sleep 1
    COUNT=$(($COUNT+1))
    BREADY=true
    for i in `brctl showstp $IFACE|sed -n 's/^.*port id.*state[ 	]*\(.*\)$/\1/p'`
    do
      if [ "$i" != "forwarding" -a "$i" != "blocking" ]
      then
        unset BREADY
      fi
    done
  done

fi

--- NEW FILE: buildtool.cfg ---
<File buildtool.mk>
  Server = cvs4-sourceforge
  Revision = HEAD
  Directory = bridge-utils
</File>
                 
<File bridge-utils-1.2.tar.gz>
  Server = cvs4-sourceforge
  Revision = HEAD
  envname = BRIDGE-UTILS_SOURCE
  Directory = bridge-utils
</File>

<File bridge_if-up>
  Server = cvs4-sourceforge
  Revision = HEAD
  Directory = bridge-utils
</File>

<File bridge_if-post-down>
  Server = cvs4-sourceforge
  Revision = HEAD
  Directory = bridge-utils
</File>

<File bridge_if-pre-up>
  Server = cvs4-sourceforge
  Revision = HEAD
  Directory = bridge-utils
</File>


<Package>
	<bridge>
		Version = 1.2
		Revision = 1

		Help <<EOF
		Utilities for configuring the Linux 2.4 and 2.6 bridge
		Homepage: http://bridge.sourceforge.net
		LEAF package by __PACKAGER__, __BUILDDATE__		
		EOF
		
		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		
		<Contents>
			<File>          
				Source          = usr/sbin/brctl
				Filename        = usr/sbin/brctl
				Type            = binary
				Permissions = 755
			</File>		
			<File>          
				Source          = etc/network/if-pre-up.d/bridge
				Filename        = etc/network/if-pre-up.d/bridge
				Type            = binary
				Permissions = 755
			</File>		
			<File>          
				Source          = etc/network/if-post-down.d/bridge
				Filename        = etc/network/if-post-down.d/bridge
				Type            = binary
				Permissions = 755
			</File>		
			<File>          
				Source          = etc/network/if-up.d/bridge
				Filename        = etc/network/if-up.d/bridge
				Type            = binary
				Permissions = 755
			</File>		
		</Contents>			
	</bridge>
</Package>


------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.