- Timestamp:
- Jan 20, 2007, 10:21:59 PM (19 years ago)
- Children:
- 145c3b8
- Parents:
- de3cb1f5
- Location:
- scripts
- Files:
-
- 1 added
- 9 edited
-
download.pl (modified) (2 diffs)
-
md5sum.bsd (modified) (1 diff)
-
patch-kernel.sh (modified) (3 diffs)
-
restore-defaultconf.sh (modified) (1 diff)
-
scan-pkgs.sh (modified) (1 diff)
-
scan-tools.sh (modified) (1 diff)
-
split-cfg.sh (added)
-
uname.fake (modified) (1 diff)
-
update-patches (modified) (2 diffs)
-
which.mac (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
scripts/download.pl
rde3cb1f5 rb9492d5 1 1 #!/usr/bin/perl 2 # $FreeWRT$ 3 #- 4 # This file is part of the FreeWRT project. FreeWRT is copyrighted 5 # material, please see the LICENCE file in the top-level directory 6 # or at http://www.freewrt.org/licence for details. 7 2 8 use strict; 3 9 use warnings; … … 38 44 $sum = $1; 39 45 40 if ($sum ne $md5sum) { 41 print STDERR "MD5 sum of the downloaded file does not match - deleting download.\n"; 42 cleanup(); 43 return; 46 if ($md5sum ne 'NO') { 47 if ($sum ne $md5sum) { 48 print STDERR "MD5 sum of the downloaded file does not match - deleting download.\n"; 49 cleanup(); 50 return; 51 } 44 52 } 45 53 -
scripts/md5sum.bsd
rde3cb1f5 rb9492d5 1 1 #!/bin/sh 2 # $FreeWRT : src/share/misc/licence.template,v 1.7 2006/04/09 22:08:49 tg Rel $ */2 # $FreeWRT$ 3 3 #- 4 # Copyright (c) 2006 5 # Thorsten Glaser <tg@mirbsd.de> 6 # 7 # Licensee is hereby permitted to deal in this work without restric- 8 # tion, including unlimited rights to use, publicly perform, modify, 9 # merge, distribute, sell, give away or sublicence, provided all co- 10 # pyright notices above, these terms and the disclaimer are retained 11 # in all redistributions or reproduced in accompanying documentation 12 # or other materials provided with binary redistributions. 13 # 14 # All advertising materials mentioning features or use of this soft- 15 # ware must display the following acknowledgement: 16 # This product includes material provided by Thorsten Glaser. 17 # This acknowledgement does not need to be reprinted if this work is 18 # linked into a bigger work whose licence does not allow such clause 19 # and the author of this work is given due credit in the bigger work 20 # or its documentation. Specifically, re-using this code in any work 21 # covered by the GNU General Public License version 1 or Library Ge- 22 # neral Public License (any version) is permitted. 23 # 24 # Licensor offers the work "AS IS" and WITHOUT WARRANTY of any kind, 25 # express, or implied, to the maximum extent permitted by applicable 26 # law, without malicious intent or gross negligence; in no event may 27 # licensor, an author or contributor be held liable for any indirect 28 # or other damage, or direct damage except proven a consequence of a 29 # direct error of said person and intended use of this work, loss or 30 # other issues arising in any way out of its use, even if advised of 31 # the possibility of such damage or existence of a nontrivial bug. 4 # This file is part of the FreeWRT project. FreeWRT is copyrighted 5 # material, please see the LICENCE file in the top-level directory 6 # or at http://www.freewrt.org/licence for details. 32 7 33 8 md5 "$@" | sed 's#MD5 (\([^)]*\)) = \(.*\)#\2 \1#' -
scripts/patch-kernel.sh
rde3cb1f5 rb9492d5 4 4 # -Erik 5 5 # 6 # (c) 2006, 2007 Thorsten Glaser <tg@freewrt.org> 6 7 # (c) 2002 Erik Andersen <andersen@codepoet.org> 8 9 shopt -s extglob 7 10 8 11 # Set directories from arguments, or use defaults. … … 22 25 wd=$(pwd) 23 26 cd $patchdir 27 rm -f $targetdir/.patch.tmp 24 28 for i in $(eval echo ${patchpattern}); do 25 29 test -e "$i" || continue 26 30 i=$patchdir/$i 27 31 cd $wd 28 case "$i"in32 case $i in 29 33 *.gz) 30 34 type="gzip"; uncomp="gunzip -dc"; ;; … … 43 47 echo "" 44 48 echo "Applying ${i} using ${type}: " 45 ${uncomp} ${i} | patch -p1 -E -d ${targetdir} 49 ${uncomp} ${i} | tee $targetdir/.patch.tmp | patch -p1 -E -d ${targetdir} 50 fgrep '@@ -0,0 ' $targetdir/.patch.tmp >/dev/null 2>&1 && \ 51 touch $targetdir/.patched-newfiles 52 rm -f $targetdir/.patch.tmp 46 53 if [ $? != 0 ] ; then 47 54 echo "Patch failed! Please fix $i!" -
scripts/restore-defaultconf.sh
rde3cb1f5 rb9492d5 3 3 # restore patterns given in $@ 4 4 # in .config using defaults found 5 # in .defconfig.5 # in Config.default. 6 6 7 7 restore() { # (pattern) 8 8 sed -i "s/^.*$1.*$//g" .config || return 1 9 grep $1 .defconfig>> .config9 grep $1 Config.default >> .config 10 10 return $? 11 11 } -
scripts/scan-pkgs.sh
rde3cb1f5 rb9492d5 1 1 #!/usr/bin/env bash 2 # $FreeWRT: src/share/misc/licence.template,v 1. 8 2006/06/16 23:03:39tg Rel $2 # $FreeWRT: src/share/misc/licence.template,v 1.20 2006/12/11 21:04:56 tg Rel $ 3 3 #- 4 4 # Copyright (c) 2006 5 5 # Thorsten Glaser <tg@mirbsd.de> 6 6 # 7 # Licensee is hereby permitted to deal in this work without restric- 8 # tion, including unlimited rights to use, publicly perform, modify, 9 # merge, distribute, sell, give away or sublicence, provided all co- 10 # pyright notices above, these terms and the disclaimer are retained 11 # in all redistributions or reproduced in accompanying documentation 12 # or other materials provided with binary redistributions. 7 # Provided that these terms and disclaimer and all copyright notices 8 # are retained or reproduced in an accompanying document, permission 9 # is granted to deal in this work without restriction, including un- 10 # limited rights to use, publicly perform, distribute, sell, modify, 11 # merge, give away, or sublicence. 13 12 # 14 # A ll advertising materials mentioning features or use of this soft-15 # ware mustdisplay the following acknowledgement:13 # Advertising materials mentioning features or use of this work must 14 # display the following acknowledgement: 16 15 # This product includes material provided by Thorsten Glaser. 17 16 # This acknowledgement does not need to be reprinted if this work is 18 17 # linked into a bigger work whose licence does not allow such clause 19 18 # and the author of this work is given due credit in the bigger work 20 # or its documentation. 19 # or its accompanying documents, where such information is generally 20 # kept, provided that said credits are retained. 21 21 # 22 # Licensor offers the work "AS IS" and WITHOUT WARRANTY of any kind,23 # express, or implied, to the maximum extent permitted by applicable24 # law, without malicious intent or gross negligence; in no event may25 # licensor, an author or contributor be held liable for any indirect26 # or other damage, or direct damage except proven a consequence of a27 # direct error of said person and intended use of this work, loss or28 # other issues arising in any way out of its use, even if advised of29 # the possibility of such damage or existence of a nontrivial bug.22 # This work is provided "AS IS" and WITHOUT WARRANTY of any kind, to 23 # the utmost extent permitted by applicable law, neither express nor 24 # implied; without malicious intent or gross negligence. In no event 25 # may a licensor, author or contributor be held liable for indirect, 26 # direct, other damage, loss, or other issues arising in any way out 27 # of dealing in the work, even if advised of the possibility of such 28 # damage or existence of a defect, except proven that it results out 29 # of said person's immediate fault when using the work as intended. 30 30 #- 31 31 # Scan host-tool prerequisites of certain packages before building. -
scripts/scan-tools.sh
rde3cb1f5 rb9492d5 272 272 fi 273 273 274 if ! which ed >/dev/null 2>&1; then 275 echo Why does your distribution not package the standard 276 echo text editor, ed? Please install it to continue. 277 out=1 278 elif [[ "$(which ed 2>/dev/null)" != /bin/ed ]]; then 279 echo Your operating system installs ed, the standard text 280 echo editor, not as /bin/ed. While you can build FreeWRT 281 echo with this, ask your vendor to fix it, point to the 282 echo FHS if needed. 283 fi 284 274 285 275 286 cd $topdir -
scripts/uname.fake
rde3cb1f5 rb9492d5 1 1 #!/bin/sh 2 # $FreeWRT : src/share/misc/licence.template,v 1.7 2006/04/09 22:08:49 tg Rel$2 # $FreeWRT$ 3 3 #- 4 # Copyright (c) 2006 5 # Thorsten Glaser <tg@mirbsd.de> 6 # 7 # Licensee is hereby permitted to deal in this work without restric- 8 # tion, including unlimited rights to use, publicly perform, modify, 9 # merge, distribute, sell, give away or sublicence, provided all co- 10 # pyright notices above, these terms and the disclaimer are retained 11 # in all redistributions or reproduced in accompanying documentation 12 # or other materials provided with binary redistributions. 13 # 14 # All advertising materials mentioning features or use of this soft- 15 # ware must display the following acknowledgement: 16 # This product includes material provided by Thorsten Glaser. 17 # This acknowledgement does not need to be reprinted if this work is 18 # linked into a bigger work whose licence does not allow such clause 19 # and the author of this work is given due credit in the bigger work 20 # or its documentation. Specifically, re-using this code in any work 21 # covered by the GNU General Public License version 1 or Library Ge- 22 # neral Public License (any version) is permitted. 23 # 24 # Licensor offers the work "AS IS" and WITHOUT WARRANTY of any kind, 25 # express, or implied, to the maximum extent permitted by applicable 26 # law, without malicious intent or gross negligence; in no event may 27 # licensor, an author or contributor be held liable for any indirect 28 # or other damage, or direct damage except proven a consequence of a 29 # direct error of said person and intended use of this work, loss or 30 # other issues arising in any way out of its use, even if advised of 31 # the possibility of such damage or existence of a nontrivial bug. 4 # This file is part of the FreeWRT project. FreeWRT is copyrighted 5 # material, please see the LICENCE file in the top-level directory 6 # or at http://www.freewrt.org/licence for details. 32 7 #- 33 8 # Fake we're running under a different operating system (@@ToOS@@) -
scripts/update-patches
rde3cb1f5 rb9492d5 13 13 # Marc Espie for the OpenBSD project. All rights reserved. 14 14 # 15 # Licensee is hereby permitted to deal in this work without restric- 16 # tion, including unlimited rights to use, publicly perform, modify, 17 # merge, distribute, sell, give away or sublicence, provided all co- 18 # pyright notices above, these terms and the disclaimer are retained 19 # in all redistributions or reproduced in accompanying documentation 20 # or other materials provided with binary redistributions. 15 # Provided that these terms and disclaimer and all copyright notices 16 # are retained or reproduced in an accompanying document, permission 17 # is granted to deal in this work without restriction, including un- 18 # limited rights to use, publicly perform, distribute, sell, modify, 19 # merge, give away, or sublicence. 21 20 # 22 # Licensor offers the work "AS IS" and WITHOUT WARRANTY of any kind,23 # express, or implied, to the maximum extent permitted by applicable24 # law, without malicious intent or gross negligence; in no event may25 # licensor, an author or contributor be held liable for any indirect26 # or other damage, or direct damage except proven a consequence of a27 # direct error of said person and intended use of this work, loss or28 # other issues arising in any way out of its use, even if advised of29 # the possibility of such damage or existence of a nontrivial bug.21 # This work is provided "AS IS" and WITHOUT WARRANTY of any kind, to 22 # the utmost extent permitted by applicable law, neither express nor 23 # implied; without malicious intent or gross negligence. In no event 24 # may a licensor, author or contributor be held liable for indirect, 25 # direct, other damage, loss, or other issues arising in any way out 26 # of dealing in the work, even if advised of the possibility of such 27 # damage or existence of a defect, except proven that it results out 28 # of said person's immediate fault when using the work as intended. 30 29 31 30 shopt -s extglob … … 62 61 D_BASE=${WRKDIR1} 63 62 D_SUB=${SUBDIST} 64 D_CMP=$D_SUB 63 # D_CMP=$D_SUB 64 D_CMP='[^/]*' 65 65 else 66 66 # WRKSRC == WRKDIR -
scripts/which.mac
rde3cb1f5 rb9492d5 1 1 #!/usr/bin/env bash 2 # $FreeWRT : src/share/misc/licence.template,v 1.8 2006/06/16 23:03:39 tg Rel$2 # $FreeWRT$ 3 3 #- 4 # Copyright (c) 2006 5 # Thorsten Glaser <tg@mirbsd.de> 6 # 7 # Licensee is hereby permitted to deal in this work without restric- 8 # tion, including unlimited rights to use, publicly perform, modify, 9 # merge, distribute, sell, give away or sublicence, provided all co- 10 # pyright notices above, these terms and the disclaimer are retained 11 # in all redistributions or reproduced in accompanying documentation 12 # or other materials provided with binary redistributions. 13 # 14 # All advertising materials mentioning features or use of this soft- 15 # ware must display the following acknowledgement: 16 # This product includes material provided by Thorsten Glaser. 17 # This acknowledgement does not need to be reprinted if this work is 18 # linked into a bigger work whose licence does not allow such clause 19 # and the author of this work is given due credit in the bigger work 20 # or its documentation. Specifically, re-using this code in any work 21 # covered by the GNU General Public License version 1 or Library Ge- 22 # neral Public License (any version) is permitted. 23 # 24 # Licensor offers the work "AS IS" and WITHOUT WARRANTY of any kind, 25 # express, or implied, to the maximum extent permitted by applicable 26 # law, without malicious intent or gross negligence; in no event may 27 # licensor, an author or contributor be held liable for any indirect 28 # or other damage, or direct damage except proven a consequence of a 29 # direct error of said person and intended use of this work, loss or 30 # other issues arising in any way out of its use, even if advised of 31 # the possibility of such damage or existence of a nontrivial bug. 4 # This file is part of the FreeWRT project. FreeWRT is copyrighted 5 # material, please see the LICENCE file in the top-level directory 6 # or at http://www.freewrt.org/licence for details. 32 7 33 8 X=$(/usr/bin/which "$@")
Note:
See TracChangeset
for help on using the changeset viewer.
