]> oss.titaniummirror.com Git - tinyos-2.x.git/commitdiff
Applied patches from Joel Granados.
authorscipio <scipio>
Fri, 15 Jan 2010 20:42:53 +0000 (20:42 +0000)
committerscipio <scipio>
Fri, 15 Jan 2010 20:42:53 +0000 (20:42 +0000)
tools/release/build-rpms
tools/release/extractor
tools/release/tinyos-tools.files
tools/release/tinyos.files

index 1883a01f6164363faea6673a5c0366195c81c769..57c1ec41bc614a9a34917ef485dccbd91fe1ecb9 100755 (executable)
@@ -1,48 +1,24 @@
 #!/bin/bash
-## NOTE: This is for MY rpm setup. Don't expect it to work for you...
-
-# For linux, change to /usr/src/redhat
-# For my cygwin: /cygdrive/c/rpmsrc
-if [ -z $RPMS ]; then #test to see if RPMS is overridden by the environment
-               RPMS=/usr/src/rpm
-fi             
-TINYOS_VERSION=2.1.0
-TINYOS_TOOLS_VERSION=1.3.0
-TINYOS_DEPUTY_VERREL=1.1-1
+
+RPMS="`rpm --eval=\"%_topdir\"`"
+
+TOS_NAME="tinyos"
+TOS_VERSION=2.1.1
+
+TOS_TOOLS_NAME="tinyos-tools"
+TOS_TOOLS_VERSION=1.3.1
+
+TOS_DEPUTY_NAME="tinyos-deputy"
+TOS_DEPUTY_VERSION=1.1-1
+
 echo "*** Building tarballs"
-#rm ../../../*.tar.gz
-sh tinyos.files
-sh tinyos-tools.files
+sh tinyos.files $TOS_NAME $TOS_VERSION $RPMS/SOURCES/$TOS_NAME-$TOS_VERSION.tar.gz
+sh tinyos-tools.files $TOS_TOOLS_NAME $TOS_TOOLS_VERSION $RPMS/SOURCES/$TOS_TOOLS_NAME-$TOS_TOOLS_VERSION.tar.gz
 sh deputy.files
-#sh contrib/contrib.files
-#sh vm/vm.files
-#sh task-tinydb/task-tinydb.files
-
-HERE=$PWD
-
-echo "*** Removing old srcs and rpms"
-cd $RPMS
-#rm -f $RPMS/SOURCES/*.tar.gz
-#rm -f $RPMS/RPMS/noarch/*.rpm
-#rm -f $RPMS/RPMS/i386/*.rpm
-
-echo "*** Installing new tarballs"
-cd $HERE/../../..
-cp tinyos-$TINYOS_VERSION.tar.gz $RPMS/SOURCES
-cp tinyos-tools-$TINYOS_TOOLS_VERSION.tar.gz $RPMS/SOURCES
-cp tinyos-deputy-$TINYOS_DEPUTY_VERREL.tar.gz $RPMS/SOURCES
-cp tinyos-deputy-$TINYOS_DEPUTY_VERREL.patch $RPMS/SOURCES
-#cp tinyos-vm-$VM_VERSION.tar.gz $RPMS/SOURCES
-#cp tinyos-contrib-$CONTRIB_VERSION.tar.gz $RPMS/SOURCES
-#cp task-tinydb-$TINYDB_VERSION.tar.gz $RPMS/SOURCES
 
 echo "*** Creating rpms"
-cd $RPMS
-rpmbuild -bb $HERE/tinyos.spec
-rpmbuild -bb $HERE/tinyos-tools.spec
-rpmbuild -bb $HERE/deputy.spec
-#rpmbuild -bb $HERE/task-tinydb/task-tinydb.spec
-#rpmbuild -bb $HERE/contrib/contrib.spec
-#rpmbuild -bb $HERE/vm/vm.spec
+rpmbuild -bb tinyos.spec
+rpmbuild -bb tinyos-tools.spec
+rpmbuild -bb deputy.spec
 
 
index dc9b894f4c74eb792d8d0fe5eed482ed5b8ae449..97679f5bf098910a64a93676681c8d2df37843c0 100755 (executable)
@@ -1,5 +1,6 @@
 #!/usr/bin/perl
 $name = $ARGV[0];
+$file_path = $ARGV[1];
 
 @files = split /\n/, `find .`;
 @result = @files;
@@ -20,7 +21,7 @@ mkdir $name;
 open TAR, "|tar cf - -T - --no-recursion | tar xf - -C $name";
 print TAR join("\n", @result);
 close TAR;
-#print join("\n", @result);
-system("tar cf - $name");
+system("tar cfz $file_path $name");
+system("rm -rf $name");
 
 
index d341370d6d1c858677b7e391a5ff287e88da0d89..20145b9ed168ec464fb7b5f51960d900a7a4a0dd 100755 (executable)
@@ -1,9 +1,9 @@
-NAME=tinyos-tools
-VERSION=1.3.0
+NAME="$1"
+VERSION="$2"
+OUTPUT_FILE="$3"
 
-cd ../..
-rm -rf $NAME-$VERSION
-tools/release/extractor $NAME-$VERSION <<'EOF' | gzip >../$NAME-$VERSION.tar.gz
+pushd ../../
+./tools/release/extractor $NAME-$VERSION $OUTPUT_FILE <<'EOF'
 !^./apps
 !^./doc
 !^./support
@@ -16,4 +16,4 @@ tools/release/extractor $NAME-$VERSION <<'EOF' | gzip >../$NAME-$VERSION.tar.gz
 !~$
 !#
 EOF
-rm -rf $NAME-$VERSION
+popd
index dc093b24734c0a81886cf68900eb21ac0f606a5c..7f562471f77328e1b335a182ff0a4dcfa187d4af 100644 (file)
@@ -1,9 +1,9 @@
-NAME=tinyos
-VERSION=2.1.0
+NAME="$1"
+VERSION="$2"
+OUTPUT_FILE="$3"
 
-cd ../..
-rm -rf $NAME-$VERSION
-tools/release/extractor $NAME-$VERSION <<'EOF' | gzip >../$NAME-$VERSION.tar.gz
+pushd ../../
+./tools/release/extractor $NAME-$VERSION $OUTPUT_FILE <<'EOF' 
 !^./apps/tests/(eyesIFX|mica2|msp430|rf230|mts300|telosb)
 !^./apps/tests/(RadioStress|TestAlarm|TestAM|TestAMOnOff|TestAMService|TestBroadcast|TestCollection|TestLocalTime|TestMultihopLqi|TestOscilloscopeLQI|TestPowerManager|TestPowerup|TestPrintf|TestRadioPM|TestScheduler|TestSerialBandwidth|TestSharedResource|TestSimTimers|TestSleep|TestTimerSync|TestTreeRouting|TestTrickleTimer|TestTymo)
 !^/apps/(BlinkAlarm|BlinkMSP430|BlinkTask|BlinkToRadio|Test|TestADC|TestArbiter|TestCC2420|TestRadio|TestSPI|TestScheduler|TestSchedulerTemp|TestSerial)
@@ -45,4 +45,4 @@ tools/release/extractor $NAME-$VERSION <<'EOF' | gzip >../$NAME-$VERSION.tar.gz
 ./tests/TestSerial/TestSerial.class
 ./RadioCountToLeds/RadioCountMsg.class
 EOF
-rm -rf $NAME-$VERSION
+popd