mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2025-03-09 00:17:31 +00:00
parent
13f00fc82b
commit
b3e73ae6c1
8 changed files with 0 additions and 389 deletions
|
@ -1,21 +0,0 @@
|
|||
#!/bin/sh
|
||||
# BROKEN FOR NOW, I don't have enough time to finish it...
|
||||
#
|
||||
# This script deletes packages from the aur PKGBUILD folder we have in git,
|
||||
# redownloads all packages from a list, and extracts them to git again.
|
||||
#
|
||||
# This is to keep our [aur] repo up-to-date.
|
||||
#
|
||||
GITDIR=/build/alarm
|
||||
AURTARBALLURL=http://aur.archlinux.org/packages/
|
||||
|
||||
# Only the following packages will be deleted and re-downloaded
|
||||
PKGLIST=yaourt open-iscsi
|
||||
|
||||
cd $GITDIR/aur
|
||||
|
||||
rm -rf $PKGLIST
|
||||
|
||||
#wget $AURTARBALLURL/$PKGLIST/$PKGLIST.tar.gz
|
||||
|
||||
#tar xzf $PKGLIST.tar.gz
|
|
@ -1,54 +0,0 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# Arch Linux ARM Chroot Builder
|
||||
#
|
||||
# Licensed under the GPLv2.
|
||||
#
|
||||
# This script builds an Arch Linux ARM chroot.
|
||||
# It does not include a kernel or other "low-level" components.
|
||||
# First, it downloads and installs packages to the workingdir,
|
||||
# then configures some basics, sets the root password to "root",
|
||||
# and then creates a rootts.tar.gz and/or a UBI image, ready to flash.
|
||||
#
|
||||
# Usage: ./chroot-builder workingdir
|
||||
#
|
||||
# NOTE: This script is interactive.
|
||||
# Agree to installing packages and answer "y" to cleaning the Pacman database.
|
||||
#
|
||||
# ==== Variables to set ====
|
||||
INSTALLEDPKGS="base file heimdal openssl"
|
||||
RELEASEVER=2011.08
|
||||
MAKETARGZ=1
|
||||
# ==== The Process ====
|
||||
mkdir -p $1
|
||||
echo -e "\033[1mInstalling packages...\033[0m"
|
||||
mkdir -p $1/var/lib/pacman
|
||||
pacman -Syyf --noconfirm --noprogressbar -r $1 $INSTALLEDPKGS
|
||||
|
||||
echo -e "\033[1mSetting the password to 'root' and cleaning up:\033[0m"
|
||||
echo -e "root\nroot\n" | chroot $1/ /usr/bin/passwd root
|
||||
rm $1/dev/{console,null,zero}
|
||||
chroot $1/ mknod -m 600 /dev/console c 5 1
|
||||
chroot $1/ mknod -m 666 /dev/null c 1 3
|
||||
chroot $1/ mknod -m 666 /dev/zero c 1 5
|
||||
rm $1/etc/locale.gen
|
||||
echo "en_US.UTF-8 UTF-8" >> $1/etc/locale.gen
|
||||
echo "en_US ISO-8859-1" >> $1/etc/locale.gen
|
||||
echo "de_DE ISO-8859-1" >> $1/etc/locale.gen
|
||||
echo "de_DE@euro ISO-8859-15" >> $1/etc/locale.gen
|
||||
chroot $1/ /usr/sbin/locale-gen
|
||||
chroot $1/ yes | /usr/bin/pacman -Scc
|
||||
echo $RELEASEVER > $1/etc/alarm-version
|
||||
|
||||
# Here is the rootfs.tar.gz part if you set MAKETARGZ to 1
|
||||
if [ $MAKETARGZ = 1 ]; then
|
||||
echo -e "\033[1mCreating a rootfs.tar.gz...\033[0m"
|
||||
cd $1
|
||||
tar czf ../ArchLinux-ARM-$RELEASEVER-chroot.tar.gz ./*
|
||||
cd ../
|
||||
else
|
||||
echo -e "\033[1mNot creating a rootfs.tar.gz...\033[0m"
|
||||
fi
|
||||
|
||||
echo -e "\033[1mCleaning up...\033[0m"
|
||||
rm -rf $1
|
|
@ -1,53 +0,0 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# Arch Linux ARM Image Builder
|
||||
#
|
||||
# Licensed under the GPLv2.
|
||||
#
|
||||
# This script builds an Arch Linux ARM distribution/image.
|
||||
# First, it downloads and installs packages to the workingdir,
|
||||
# then configures some basics, sets the root password to "root",
|
||||
# and then creates a rootts.tar.gz and/or a UBI image, ready to flash.
|
||||
#
|
||||
# Usage: ./distro-builder workingdir
|
||||
#
|
||||
# NOTE: This script is interactive.
|
||||
# Agree to installing packages and answer "y" to cleaning the Pacman database.
|
||||
#
|
||||
# ==== Variables to set ====
|
||||
INSTALLEDPKGS="base kernel26 kernel26-headers file heimdal ntfs-3g openssh openssl"
|
||||
RELEASEVER=2011.06
|
||||
MAKETARGZ=1
|
||||
# ==== The Process ====
|
||||
mkdir -p $1
|
||||
echo -e "\033[1mInstalling packages...\033[0m"
|
||||
mkdir -p $1/var/lib/pacman
|
||||
pacman -Syyf --noconfirm --noprogressbar -r $1 $INSTALLEDPKGS
|
||||
|
||||
echo -e "\033[1mSetting the password to 'root' and cleaning up:\033[0m"
|
||||
echo -e "root\nroot\n" | chroot $1/ /usr/bin/passwd root
|
||||
rm $1/dev/{console,null,zero}
|
||||
chroot $1/ mknod -m 600 /dev/console c 5 1
|
||||
chroot $1/ mknod -m 666 /dev/null c 1 3
|
||||
chroot $1/ mknod -m 666 /dev/zero c 1 5
|
||||
rm $1/etc/locale.gen
|
||||
echo "en_US.UTF-8 UTF-8" >> $1/etc/locale.gen
|
||||
echo "en_US ISO-8859-1" >> $1/etc/locale.gen
|
||||
echo "de_DE ISO-8859-1" >> $1/etc/locale.gen
|
||||
echo "de_DE@euro ISO-8859-15" >> $1/etc/locale.gen
|
||||
chroot $1/ /usr/sbin/locale-gen
|
||||
chroot $1/ yes | /usr/bin/pacman -Scc
|
||||
echo $RELEASEVER > $1/etc/alarm-version
|
||||
|
||||
# Here is the rootfs.tar.gz part if you set MAKETARGZ to 1
|
||||
if [ $MAKETARGZ = 1 ]; then
|
||||
echo -e "\033[1mCreating a rootfs.tar.gz...\033[0m"
|
||||
cd $1
|
||||
tar czf ../PlugApps-Linux-$RELEASEVER-rootfs.tar.gz ./*
|
||||
cd ../
|
||||
else
|
||||
echo -e "\033[1mNot creating a rootfs.tar.gz...\033[0m"
|
||||
fi
|
||||
|
||||
echo -e "\033[1mCleaning up...\033[0m"
|
||||
rm -rf $1
|
|
@ -1,18 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
lastfile=""
|
||||
if [[ ! $* ]]; then
|
||||
echo "usage: $0 <directory>"
|
||||
exit 1
|
||||
fi
|
||||
if [[ ! -e "$1/old/" ]]; then
|
||||
mkdir "$1/old/"
|
||||
fi
|
||||
for file in $(ls -r $1); do
|
||||
stripped=${file%%-[0-9].*}
|
||||
if [[ "$stripped" == "$lastfile" ]]; then
|
||||
echo "moved duplicate $1/$file"
|
||||
mv "$1/$file" "$1/old/"
|
||||
fi
|
||||
lastfile=$stripped
|
||||
done
|
|
@ -1,56 +0,0 @@
|
|||
#!/usr/bin/perl -w
|
||||
use strict;
|
||||
|
||||
use File::Find;
|
||||
use POSIX;
|
||||
|
||||
|
||||
|
||||
my @dirs = qw(arm armv6h armv7h);
|
||||
my @files = ();
|
||||
my @unfails = ();
|
||||
my %packages;
|
||||
|
||||
|
||||
|
||||
foreach my $arch (@dirs){
|
||||
find(\&pushFile, "/var/www/archlinuxarm/html/$arch");
|
||||
}
|
||||
|
||||
|
||||
foreach (@files){
|
||||
my $filename = $_;
|
||||
my @parts = split('/', $_);
|
||||
my $package = $parts[-1];
|
||||
#break the package name down to it's base part...this is probably missing a few, but it's quick and dirty for now.
|
||||
$package =~ s/-\d.*-\d{1,2}-(any|arm|armv6h|armv7h)\.pkg\.tar\.xz//;
|
||||
my @temparray = ($parts[5], $package, $filename);
|
||||
$packages{(((stat($filename))[9]))} = \@temparray;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
my $counter = 0;
|
||||
|
||||
foreach my $key (sort keys %packages){
|
||||
$counter++;
|
||||
if ($counter > 10){
|
||||
last;
|
||||
}
|
||||
|
||||
if (${$packages{$key}}[0] eq "arm"){
|
||||
print "!unfail 5 ". ${$packages{$key}}[1];
|
||||
}
|
||||
elsif (${$packages{$key}}[0] eq "armv6h"){
|
||||
print "!unfail 6 ". ${$packages{$key}}[1];
|
||||
}
|
||||
elsif (${$packages{$key}}[0] eq "armv7h"){
|
||||
print "!unfail 7 ". ${$packages{$key}}[1];
|
||||
}
|
||||
}
|
||||
|
||||
sub pushFile()
|
||||
{
|
||||
push @files, $File::Find::name if(/\.pkg\.tar\.xz/i);
|
||||
}
|
|
@ -1,110 +0,0 @@
|
|||
#!/usr/bin/perl -w
|
||||
use strict;
|
||||
|
||||
use File::Find;
|
||||
use POSIX;
|
||||
|
||||
|
||||
|
||||
|
||||
my @dirs = qw(arm armv6h armv7h);
|
||||
my @files = ();
|
||||
my @unfails = ();
|
||||
my (%arm, %armv6h, %armv7h);
|
||||
|
||||
|
||||
print "This will output a listing of files that have been abandoned by" .
|
||||
" plugbuild for some reason or another. \nIt can be pasted " .
|
||||
"into a bash script/xargs, and then outputs unfails for plugbuild just to make sure\n\n\n";
|
||||
|
||||
foreach my $arch (@dirs){
|
||||
find(\&pushFile, "/var/www/archlinuxarm/html/$arch");
|
||||
}
|
||||
|
||||
foreach (@files){
|
||||
my @parts = split('/', $_);
|
||||
my $package = $parts[-1];
|
||||
#break the package name down to it's base part...this is probably missing a few, but it's quick and dirty for now.
|
||||
$package =~ s/-\d.*-\d{1,2}-(any|arm|armv6h|armv7h)\.pkg\.tar\.xz//;
|
||||
if ($package =~ m/.*(dkms|dpi|blank).*/) {
|
||||
print "\#Skipping " . $_ . "\n";
|
||||
next;
|
||||
}
|
||||
|
||||
if ($parts[5] eq "arm"){
|
||||
if (exists $arm{$package}) {
|
||||
push(@unfails, '!unfail 5 ' . $package);
|
||||
#stat[9] is the epoch of the last modified date
|
||||
if ((stat ($_))[9] < (stat ($arm{$package}))[9]) {
|
||||
print "rm \"" . $_ . "\"\n";
|
||||
print "\#rm \"" . $arm{$package} . "\"\n";
|
||||
|
||||
}
|
||||
else {
|
||||
print "rm \"" . $arm{$package} . "\"\n";
|
||||
print "#rm \"" . $_ . "\"\n";
|
||||
$arm{$package} = $_;
|
||||
}
|
||||
|
||||
}
|
||||
else {
|
||||
$arm{$package} = $_;
|
||||
}
|
||||
|
||||
}
|
||||
elsif ($parts[5] eq "armv6h"){
|
||||
if (exists $armv6h{$package}) {
|
||||
push(@unfails, '!unfail 6 ' . $package);
|
||||
if ((stat ($_))[9] < (stat ($armv6h{$package}))[9]) {
|
||||
print "rm \"" . $_ . "\"\n";
|
||||
print "\#rm \"" . $armv6h{$package} . "\"\n";
|
||||
|
||||
}
|
||||
else {
|
||||
print "rm \"" . $armv6h{$package} . "\"\n";
|
||||
print "#rm \"" . $_ . "\"\n";
|
||||
$armv6h{$package} = $_;
|
||||
}
|
||||
|
||||
}
|
||||
else {
|
||||
$armv6h{$package} = $_;
|
||||
}
|
||||
|
||||
}
|
||||
elsif ($parts[5] eq "armv7h"){
|
||||
if (exists $armv7h{$package}) {
|
||||
push(@unfails, '!unfail 7 ' . $package);
|
||||
if ((stat ($_))[9] < (stat ($armv7h{$package}))[9]) {
|
||||
print "rm \"" . $_ . "\"\n";
|
||||
print "\#rm \"" . $armv7h{$package} . "\"\n";
|
||||
|
||||
}
|
||||
else {
|
||||
print "rm \"" . $armv7h{$package} . "\"\n";
|
||||
print "#rm \"" . $_ . "\"\n";
|
||||
$armv7h{$package} = $_;
|
||||
}
|
||||
|
||||
}
|
||||
else {
|
||||
$armv7h{$package} = $_;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
print "\n\nPaste this into the plugbuild window to make sure that any packages deleted by accident/wrong version get rebuilt.\n\n";
|
||||
foreach (@unfails){
|
||||
print $_ . "\n";
|
||||
}
|
||||
|
||||
|
||||
|
||||
sub pushFile()
|
||||
{
|
||||
push @files, $File::Find::name if(/\.pkg\.tar\.xz/i);
|
||||
}
|
|
@ -1,37 +0,0 @@
|
|||
#!/bin/bash
|
||||
# rfs-pacman
|
||||
# simplified rootfs manipulation with pacman.
|
||||
##
|
||||
|
||||
# current directory
|
||||
PWD=`pwd`
|
||||
|
||||
# does this directory have etc/pacman.conf?
|
||||
if [ -f $PWD/etc/pacman.conf ]; then
|
||||
|
||||
SHORT=`echo $PWD | sed 's/.*\///'`
|
||||
ARCH=`grep 'Architecture =' etc/pacman.conf | sed 's/Architecture = //'`
|
||||
echo "Calling pacman:"
|
||||
echo " -root: $PWD"
|
||||
echo " -arch: $ARCH"
|
||||
|
||||
SEDPWD=`echo $PWD | sed 's/\\//\\\\\//g'`
|
||||
sed "s/\/etc\/pacman.d/$SEDPWD\/etc\/pacman.d/" \
|
||||
$PWD/etc/pacman.conf > etc/pacman.conf.rfs
|
||||
|
||||
pacman \
|
||||
-r $PWD \
|
||||
-b $PWD/var/lib/pacman \
|
||||
--arch $ARCH \
|
||||
--cachedir $PWD/var/cache/pacman/pkg \
|
||||
--config $PWD/etc/pacman.conf.rfs \
|
||||
--logfile $PWD/../$SHORT.pacman.log \
|
||||
$@
|
||||
|
||||
rm $PWD/etc/pacman.conf.rfs
|
||||
|
||||
else
|
||||
echo "'$PWD' doesn't appear to be a rootfs."
|
||||
fi
|
||||
|
||||
|
|
@ -1,40 +0,0 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# PlugApps Plug Flasher
|
||||
#
|
||||
# The following script will take a rootfs file and flash it
|
||||
# on a TonidoPlug's NAND. Stick this on a PlugApps USB drive
|
||||
# along with a rootfs.tar.gz (set it below), SSH in, and run this.
|
||||
#
|
||||
# It's based on the official TonidoPlug reflasher: http://www.tonido.com/support/TonidoPlug_Flash_LinuxOS
|
||||
#
|
||||
# Set this to where you put the rootfs on the USB drive! e.g. make a folder
|
||||
# named "flash" on your drive and put the rootfs in there.
|
||||
#
|
||||
ROOTFS=/flash/PlugApps-Linux-2011.02-beta1-rootfs.tar.gz
|
||||
#
|
||||
echo "This script will completely erase your TonidoPlug's firmware"
|
||||
echo "and will replace it with PlugApps. You will then be able to"
|
||||
echo "use PlugApps from the internal storage instead of from USB."
|
||||
echo ""
|
||||
echo "This will take up to 15 minutes."
|
||||
echo ""
|
||||
echo "If this is not what you want, press CTRL-X now."
|
||||
echo "Otherwise, press ENTER to start reflashing."
|
||||
#
|
||||
echo "Accessing internal storage..."
|
||||
ubiattach /dev/ubi_ctrl -m 2
|
||||
mount -t ubifs ubi0:rootfs /mnt/
|
||||
echo "Wiping internal filesystem contents..."
|
||||
rm -rf /mnt/*
|
||||
echo "Flashing PlugApps..."
|
||||
tar -C /mnt/ -xzf $ROOTFS >& /dev/null
|
||||
echo "Flashing kernel..."
|
||||
flash_eraseall -j /dev/mtd1
|
||||
nandwrite -pm /dev/mtd1 /mnt/boot/uImage
|
||||
echo "Unmounting..."
|
||||
umount /mnt/
|
||||
ubidetach /dev/ubi_ctrl -m 2
|
||||
#
|
||||
echo "All done, you now have PlugApps on your TonidoPlug!"
|
||||
echo "Remove all USB drives attached to the plug and reboot."
|
Loading…
Reference in a new issue