Created
November 17, 2013 18:32
-
-
Save s-wool/7516488 to your computer and use it in GitHub Desktop.
apt-cygの64bit対応とxzファイルの対応
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- apt-cyg.orig 2010-04-28 03:55:43.000000000 +0900 | |
+++ apt-cyg 2013-11-18 03:31:25.034070400 +0900 | |
@@ -95,14 +95,14 @@ function getsetup() | |
then | |
touch setup.ini | |
mv setup.ini setup.ini-save | |
- wget -N $mirror/setup.bz2 | |
+ wget -N $mirror/x86_64/setup.bz2 | |
if test -e setup.bz2 && test $? -eq 0 | |
then | |
bunzip2 setup.bz2 | |
mv setup setup.ini | |
echo Updated setup.ini | |
else | |
- wget -N $mirror/setup.ini | |
+ wget -N $mirror/x86_64/setup.ini | |
if test -e setup.ini && test $? -eq 0 | |
then | |
echo Updated setup.ini | |
@@ -350,7 +350,11 @@ case "$command" in | |
fi | |
echo "Unpacking..." | |
- cat $file | bunzip2 | tar > "/etc/setup/$pkg.lst" xvf - -C / | |
+ case "$file" in | |
+ *.tar.bz2) cat $file | bunzip2 | tar > "/etc/setup/$pkg.lst" xvf - -C / ;; | |
+ *.tar.xz) cat $file | xz -dv | tar > "/etc/setup/$pkg.lst" xvf - -C / ;; | |
+ *) echo Unknown extension, exting : $file; exit 1 ;; | |
+ esac | |
gzip -f "/etc/setup/$pkg.lst" | |
cd ../.. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment