Compare commits
21 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| f9a3310a0a | |||
| 5d2d7b14c9 | |||
| 4d06a97213 | |||
| 10363febf1 | |||
| 85957d4373 | |||
| ddfdf83463 | |||
| 51473b2403 | |||
| ca15a97fcd | |||
| 9f39e8ed29 | |||
| b6c30b6b6c | |||
| 830f0c9cc9 | |||
| fc5fac0667 | |||
| 15f85a19a4 | |||
| b71931b0b5 | |||
| ba7ad82e8b | |||
| d5d4563399 | |||
| 374906b15b | |||
| 998484d315 | |||
| 307f1e836f | |||
| 51fad1aced | |||
| 1d8692b8e6 |
-11
@@ -23,14 +23,3 @@
|
|||||||
/screenlog*
|
/screenlog*
|
||||||
/logs
|
/logs
|
||||||
*.swp
|
*.swp
|
||||||
*.lck
|
|
||||||
/extrasrc
|
|
||||||
|
|
||||||
# You should really generate local copies of these, as they're pretty private.
|
|
||||||
extra/pre-build.d/etc/openvpn/client.conf
|
|
||||||
overlay/etc/ssh/*
|
|
||||||
overlay/home/bdisk
|
|
||||||
overlay/etc/systemd/system/multi-user.target.wants/openvpn@client.service
|
|
||||||
src/ipxe_local/ssl/keys
|
|
||||||
src/ipxe_local/ssl/crts
|
|
||||||
src/ipxe_local/ssl/txt
|
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
[submodule "ipxe"]
|
|
||||||
branch = master
|
|
||||||
[submodule "src/ipxe"]
|
|
||||||
path = src/ipxe
|
|
||||||
url = git://git.ipxe.org/ipxe.git
|
|
||||||
@@ -0,0 +1,144 @@
|
|||||||
|
######################################################################################################################################
|
||||||
|
##### BDisk #####
|
||||||
|
##### #####
|
||||||
|
##### Written by Brent Saner #####
|
||||||
|
##### <bts@square-r00t.net> #####
|
||||||
|
##### Built upon my (Brent's) 'BDisk' ISO-building framework (http://bdisk.square-r00t.net) #####
|
||||||
|
######################################################################################################################################
|
||||||
|
|
||||||
|
## Why Arch? ##
|
||||||
|
Because it's a largely easy-to-use, well-documented (https://wiki.archlinux.org/) distro. It's no-frills and incredibly
|
||||||
|
flexible/customizable, and can be made rather slim. It's also very friendly to run as a chroot inside any other distro.
|
||||||
|
|
||||||
|
All commands below should be issued in the root working directory of this git repository. (For me, this is
|
||||||
|
/opt/dev/work/BDisk but this may be entirely different for you, depending on where you cloned the repository to.)
|
||||||
|
|
||||||
|
!!!!!! WARNING !!!!!!!
|
||||||
|
I do NOT recommend running this on a machine that is using wireless, as it will download a LOT of data.
|
||||||
|
If you ignore this warning, be prepared to explain to anyone you share your wifi with why Facebook takes 20 seconds to load,
|
||||||
|
because they WILL ask.
|
||||||
|
|
||||||
|
It should be fine over ethernet, since hardware switches are much faster and efficient than a single duplex wireless radio.
|
||||||
|
|
||||||
|
Future versions, once this project has a dumping ground, will fetch highly compressed snapshotted chroot filesystems instead
|
||||||
|
of dynamically building the entire install chroots (both x86_64 and i686) instead (with the option of building fresh locally,
|
||||||
|
disabled by default).
|
||||||
|
Till then, sorry for the inconvenience.
|
||||||
|
!!!!!!!!!!!!!!!!!!!!!!
|
||||||
|
|
||||||
|
## Prerequisites ##
|
||||||
|
-At least ~20Gb disk space free (remember, you need room for not only four chroots (one developing and one staging for i686/x86_64),
|
||||||
|
but also disk space for working, the finished ISO(s), etc.)
|
||||||
|
|
||||||
|
-The following packages installed on the build host:
|
||||||
|
(NOTE: future versions will have dependencies checked automatically and installed if necessary,
|
||||||
|
depending on distro your host build machine is. the OS detection and package installation component of that isn't
|
||||||
|
done yet though. 2014.10.31)
|
||||||
|
(NOTE2: Make sure all the packages you specify are valid package names. A mistyped package name will cause the chroot creation to
|
||||||
|
break and everything else will break as a result.)
|
||||||
|
|
||||||
|
curl
|
||||||
|
dosfstools
|
||||||
|
libisoburn ("libisofs" on CentOS)
|
||||||
|
lynx
|
||||||
|
rsync
|
||||||
|
sed
|
||||||
|
squashfs-tools
|
||||||
|
xorriso (in RPMForge repo for CentOS 7)
|
||||||
|
xz
|
||||||
|
|
||||||
|
and *probably* a few others. the scripts run with set -e for the most part, so if something's missed, you'll know.
|
||||||
|
oh, you will know.
|
||||||
|
|
||||||
|
|
||||||
|
## (Re)Building ##
|
||||||
|
$ sudo bin/build.sh
|
||||||
|
|
||||||
|
Yeah. It's that easy. The finished product is in iso/.
|
||||||
|
|
||||||
|
Build output should look something like this:
|
||||||
|
|
||||||
|
|
||||||
|
[root@dawid BDisk]# time nice -n "-19" bin/build.sh
|
||||||
|
You have not configured a build.conf OR you are not running from the project's root directory (the git repository's working directory).
|
||||||
|
If you are indeed in the correct directory, you may copy the sample at extra/build.conf.sample,
|
||||||
|
edit it for appropriate values, and copy to <PROJECT ROOT>/build.conf
|
||||||
|
For now, though, I am copying over the default.
|
||||||
|
Checking directory structure and creating lockfile at /opt/dev/work/BDisk/lockfile.lck...
|
||||||
|
/opt/dev/work/BDisk/root.i686 does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/root.x86_64 does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/build32 does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/build64 does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/iso does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/temp/bdisk does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/temp/FPOS does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/src does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/tftpboot does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/http/FPOS does not exist - creating.
|
||||||
|
/opt/dev/work/BDisk/logs does not exist - creating.
|
||||||
|
No existing chroot environment found. Creating...
|
||||||
|
Now importing settings/variables.
|
||||||
|
Checking/fetching snapshots...
|
||||||
|
Extracting snapshots. This will take a while...
|
||||||
|
Configuring snapshots...
|
||||||
|
Initializing chroots...
|
||||||
|
Prepping /opt/dev/work/BDisk/root.i686. This will take a while...
|
||||||
|
...Key initializing...Done.
|
||||||
|
...Importing keys...Done.
|
||||||
|
...Installing base packages...Done.
|
||||||
|
...Upgrading any outdated packages...Done. Finishing/cleaning up...
|
||||||
|
Prepping /opt/dev/work/BDisk/root.x86_64. This will take a while...
|
||||||
|
...Key initializing...Done.
|
||||||
|
...Importing keys...Done.
|
||||||
|
...Installing base packages...Done.
|
||||||
|
...Upgrading any outdated packages...Done. Finishing/cleaning up...
|
||||||
|
Installing common packages...
|
||||||
|
...Packages installing to /opt/dev/work/BDisk/root.i686...Compiling kernel sources...Regular packages......Creating bdisk user...Done.
|
||||||
|
Done.
|
||||||
|
...Packages installing to /opt/dev/work/BDisk/root.x86_64...Compiling kernel sources...Regular packages......Creating bdisk user...Done.
|
||||||
|
Done.
|
||||||
|
Installing packages for 32-bit...
|
||||||
|
Done.
|
||||||
|
Installing packages for 64-bit...
|
||||||
|
Done.
|
||||||
|
Syncing overlay...
|
||||||
|
Done.
|
||||||
|
Chroot setup complete.
|
||||||
|
Checking for appropriate kernel version and mksquashfs version...
|
||||||
|
Data is not sync'd to buildroot; syncing...
|
||||||
|
Syncing important files to /opt/dev/work/BDisk/build64 for building the squashed filesystem (this may take some time)...
|
||||||
|
Compressing the package DB...
|
||||||
|
cp: ‘/opt/dev/work/BDisk/build64/usr/share/zoneinfo/EST5EDT’ and ‘/opt/dev/work/BDisk/build64/etc/localtime’ are the same file
|
||||||
|
cp: ‘/opt/dev/work/BDisk/root.x86_64/usr/share/zoneinfo/EST5EDT’ and ‘/opt/dev/work/BDisk/root.x86_64/etc/localtime’ are the same file
|
||||||
|
Cleaning up unnecessary cruft in /opt/dev/work/BDisk/build64...
|
||||||
|
[64-bit] Now generating the squashed image (if we need to) and hashes. This may take some time.
|
||||||
|
[64-bit] Squashing filesystem. This can take a while depending on the size of your chroot(s).
|
||||||
|
[64-bit] Copying files for PXE, and ISO building, please be patient.
|
||||||
|
Data is not sync'd to buildroot; syncing...
|
||||||
|
Syncing important files to /opt/dev/work/BDisk/build32 for building the squashed filesystem (this may take some time)...
|
||||||
|
Compressing the package DB...
|
||||||
|
cp: ‘/opt/dev/work/BDisk/build32/usr/share/zoneinfo/EST5EDT’ and ‘/opt/dev/work/BDisk/build32/etc/localtime’ are the same file
|
||||||
|
cp: ‘/opt/dev/work/BDisk/root.i686/usr/share/zoneinfo/EST5EDT’ and ‘/opt/dev/work/BDisk/root.i686/etc/localtime’ are the same file
|
||||||
|
Cleaning up unnecessary cruft in /opt/dev/work/BDisk/build32...
|
||||||
|
[32-bit] Now generating the squashed image (if we need to) and hashes. This may take some time.
|
||||||
|
[32-bit] Squashing filesystem. This can take a while depending on the size of your chroot(s).
|
||||||
|
[32-bit] Copying files for PXE, and ISO building, please be patient.
|
||||||
|
Building the actual .iso image. This may take a while.
|
||||||
|
Setting up EFI stuff...
|
||||||
|
Checking/fetching UEFI shells...
|
||||||
|
Generating the EFI embedded FAT filesystem...
|
||||||
|
EFI configuration complete...
|
||||||
|
ISO generated; size is 1.3G.
|
||||||
|
You can find it at /opt/dev/work/BDisk/iso/bdisk-v1.04-a8666bd-any.iso
|
||||||
|
Cleaning up some stuff leftover from the build...
|
||||||
|
Finished successfully!
|
||||||
|
|
||||||
|
real 250m48.104s
|
||||||
|
user 163m6.046s
|
||||||
|
sys 8m26.573s
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
If you want more verbosity, check out the logs/ directory.
|
||||||
@@ -1 +1,39 @@
|
|||||||
- maybe use ZConfig? https://pypi.python.org/pypi/ZConfig
|
## General ##
|
||||||
|
|
||||||
|
-include WinMTR, build Mac OS X MTR for dist/tools on CD
|
||||||
|
-include pre-compiled DoxBox for opening LUKS parts on Windows (https://github.com/t-d-k/doxbox)
|
||||||
|
|
||||||
|
|
||||||
|
## NETWORKING ##
|
||||||
|
|
||||||
|
-shorewall/some other firewall?
|
||||||
|
-WISH: locked-down VPN?
|
||||||
|
-autodetection/configuration of network. DHCP is currently running by default, but does it need to support IPv6? if so, how would the user configure their network?
|
||||||
|
-WISH: support iPXE? would save on ISO file size (letting us create MUCH bigger squash systems), but the downside is we lose EFI support and it requires a working network configuration- which defeats the purpose of a diagnostic disc.
|
||||||
|
|
||||||
|
|
||||||
|
## Building ##
|
||||||
|
|
||||||
|
-WISH: Better logging[0]
|
||||||
|
-use manual chrooting functions ONLY if distro not detected as arch. if /usr/bin/systemd-nspawn exists, use that instead
|
||||||
|
--does arch-chroot work across all distros? see https://wiki.archlinux.org/index.php/Install_bundled_32-bit_system_in_Arch64 and https://wiki.archlinux.org/index.php/Chroot
|
||||||
|
--i think this might be unnecessary. testing across other major distros is necessary, but i think i can just use the chroot'd arch-chroot
|
||||||
|
-tweak build.conf (and build.conf.sample) to source the pwd and set as BASEDIR ***if*** the project resources are present in pwd, otherwise throw warning
|
||||||
|
--this is half-done;PWD is currently used by default.
|
||||||
|
-does gummiboot? loader? wtfever it's called support splash backgrounds? can i implement that differently somehow?
|
||||||
|
-Host-specific chroot customizations (i.e. -J in <chroot>/etc/makepkg.conf
|
||||||
|
-strip out/remove unnecessary and orphan packages (e.g. gcc, make, automake, etc.)
|
||||||
|
|
||||||
|
__________________________________________________________
|
||||||
|
FOOTNOTES:
|
||||||
|
|
||||||
|
|
||||||
|
[0] I'd really like to implement the following in build.conf; like:
|
||||||
|
http://forums.fedoraforum.org/showthread.php?t=275743
|
||||||
|
# The following is the setting for "verbosity". A more accurate way of saying it is how output should be handled.
|
||||||
|
# Note that for it to be properly parsed, it MUST be in the form of a linear array (e.g. VAR=(1 2 3) ).
|
||||||
|
# '| tee -a ${BASEDIR}/logs/${FUNCNAME}.$(date +%s)' means "display output for STDOUT and STDERR, and also log STDOUT to logs/<function name>.EPOCH_TIME"
|
||||||
|
# '2>&1 /dev/null' means "hide STDOUT and STDERR, no logging"
|
||||||
|
# '>> ${BASEDIR}/logs/${FUNCNAME}.$(date +%s) 2>&1' means "log both STDOUT and STDERR to logs/<function name>.EPOCH_TIME, no output"
|
||||||
|
# '>> ${BASEDIR}/logs/${FUNCNAME}.$(date +%s)' means "log STDOUT to logs/<function name>.EPOCH_TIME, display (but don't log) STDERR)"
|
||||||
|
# '' means "no logging; display both STDOUT and STDERR"
|
||||||
|
|||||||
@@ -1,61 +0,0 @@
|
|||||||
#!/usr/bin/env python3
|
|
||||||
|
|
||||||
import os
|
|
||||||
import re
|
|
||||||
import hashlib
|
|
||||||
import gnupg
|
|
||||||
from urllib.request import urlopen
|
|
||||||
|
|
||||||
def download_tarball(arch, dlpath):
|
|
||||||
# arch - should be i686 or x86_64
|
|
||||||
# returns path/filename e.g. /some/path/to/file.tar.gz
|
|
||||||
# we use .gnupg since we'll need it later.
|
|
||||||
try:
|
|
||||||
os.makedirs(dlpath + '/.gnupg')
|
|
||||||
except OSError as exception:
|
|
||||||
if exception.errno != errno.EEXIST:
|
|
||||||
raise
|
|
||||||
#mirror = 'http://mirrors.kernel.org/archlinux'
|
|
||||||
mirror = 'https://mirror.us.leaseweb.net/archlinux'
|
|
||||||
rlsdir = mirror + '/iso/latest'
|
|
||||||
sha_in = urlopen(rlsdir + '/sha1sums.txt')
|
|
||||||
sha1sums = sha_in.read()
|
|
||||||
sha_in.close()
|
|
||||||
sha1_list = sha1sums.decode("utf-8")
|
|
||||||
sha_list = list(filter(None, sha1_list.split('\n')))
|
|
||||||
sha_dict = {x.split()[1]: x.split()[0] for x in sha_list}
|
|
||||||
pattern = re.compile('^archlinux-bootstrap-[0-9]{4}\.[0-9]{2}\.[0-9]{2}-' + arch + '\.tar\.gz$')
|
|
||||||
tarball = [filename.group(0) for l in list(sha_dict.keys()) for filename in [pattern.search(l)] if filename][0]
|
|
||||||
sha1 = sha_dict[tarball]
|
|
||||||
# all that lousy work just to get a sha1 sum. okay. so.
|
|
||||||
if os.path.isfile(dlpath + '/latest.' + arch + '.tar.gz'):
|
|
||||||
pass
|
|
||||||
else:
|
|
||||||
# fetch the tarball...
|
|
||||||
print("Fetching the tarball for {0} architecture, please wait...".format(arch))
|
|
||||||
tarball_dl = urlopen(rlsdir + tarball)
|
|
||||||
with open(dlpath + '/latest.' + arch + '.tar.gz', 'wb') as f:
|
|
||||||
f.write(tarball_dl)
|
|
||||||
tarball_dl.close()
|
|
||||||
tarball_hash = hashlib.sha1(open(dlpath + '/latest.' + arch + '.tar.gz', 'rb').read()).hexdigest()
|
|
||||||
if tarball_hash != sha1:
|
|
||||||
exit("There was a failure fetching the tarball and the wrong version exists on the filesystem.\nPlease try again later.")
|
|
||||||
else:
|
|
||||||
# okay, so the sha1 matches. let's verify the signature.
|
|
||||||
# we don't want to futz with the users normal gpg.
|
|
||||||
gpg = gnupg.GPG(gnupghome=dlpath + '/.gnupg')
|
|
||||||
input_data = gpg.gen_key_input(name_email='tempuser@nodomain.tld',passphrase='placeholder_passphrase')
|
|
||||||
key = gpg.gen_key(input_data)
|
|
||||||
keyid = '7F2D434B9741E8AC'
|
|
||||||
gpg_sig = tarball + '.sig'
|
|
||||||
sig_dl = urlopen(rlsdir + gpg_sig)
|
|
||||||
with open(dlpath + '/latest.' + arch + '.tar.gz.sig', 'wb') as f:
|
|
||||||
f.write(sig_dl)
|
|
||||||
sig_dl.close()
|
|
||||||
sig = dlpath + '/latest.' + arch + '.tar.gz.sig'
|
|
||||||
gpg.verify_file(dlpath + '/latest.' + arch + '.tar.gz', sig_file = sig)
|
|
||||||
|
|
||||||
|
|
||||||
return(sha1sum)
|
|
||||||
|
|
||||||
print(download_tarball('x86_64'))
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
#!/usr/bin/env python3
|
|
||||||
|
|
||||||
import os
|
|
||||||
import sys
|
|
||||||
import platform
|
|
||||||
|
|
||||||
def getOS():
|
|
||||||
# Returns one of: SuSE, debian, fedora, redhat, centos, mandrake,
|
|
||||||
# mandriva, rocks, slackware, yellowdog, gentoo, UnitedLinux,
|
|
||||||
# turbolinux, arch, mageia
|
|
||||||
distro = list(platform.linux_distribution())[0].lower()
|
|
||||||
return(distro)
|
|
||||||
|
|
||||||
def getBits():
|
|
||||||
bits = list(platform.architecture())[0]
|
|
||||||
return(bits)
|
|
||||||
Executable
+197
@@ -0,0 +1,197 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# A lot of snippets, inspiration, and some config directives are from https://projects.archlinux.org/archiso.git/ / the ArchLinux ISO layout.
|
||||||
|
# Many thanks and praise are deserved.
|
||||||
|
|
||||||
|
|
||||||
|
#DEBUG
|
||||||
|
#set -x
|
||||||
|
|
||||||
|
## Import settings
|
||||||
|
if [ -f "build.conf" ];
|
||||||
|
then
|
||||||
|
echo "Now importing settings/variables."
|
||||||
|
set -e
|
||||||
|
source extra/build.conf.sample
|
||||||
|
source build.conf
|
||||||
|
set +e
|
||||||
|
else
|
||||||
|
echo "You have not configured a build.conf OR you are not running from the project's root directory (the git repository's working directory).
|
||||||
|
If you are indeed in the correct directory, you may copy the sample at extra/build.conf.sample,
|
||||||
|
edit it for appropriate values, and copy to <PROJECT ROOT>/build.conf"
|
||||||
|
echo 'For now, though, I am using the defaults. If the build fails complaining about a'
|
||||||
|
echo 'missing http user, you need to specify a custom/distro-pertinent one.'
|
||||||
|
cp extra/build.conf.sample build.conf
|
||||||
|
set -e
|
||||||
|
source extra/build.conf.sample
|
||||||
|
set +e
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
## PREPARATION ##
|
||||||
|
|
||||||
|
# safemode browsing enabled. lolz
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# do some basic error checking
|
||||||
|
ARCH=$(uname -m)
|
||||||
|
|
||||||
|
if [[ ${EUID} -ne 0 ]];
|
||||||
|
then
|
||||||
|
#echo "This script must be run as root" 1>&2
|
||||||
|
echo "This script must be run as root."
|
||||||
|
exit 1
|
||||||
|
elif [ -f ${LOCKFILE} ];
|
||||||
|
then
|
||||||
|
echo "Script already running, stale lockfile present, or an error occurred during last run."
|
||||||
|
echo "Please clear ${LOCKFILE} by hand before attempting another build."
|
||||||
|
echo -n "Timestamp of lockfile is: "
|
||||||
|
ls -l ${LOCKFILE} | awk '{print $6" "$7" "$8}'
|
||||||
|
exit 1
|
||||||
|
elif [[ "$(uname -s)" != "Linux" ]];
|
||||||
|
then
|
||||||
|
echo "ERROR: This script is only supported on GNU/Linux."
|
||||||
|
exit 1
|
||||||
|
elif [[ "${ARCH}" != 'x86_64' ]];
|
||||||
|
then
|
||||||
|
echo "Your hardware architecture, ${ARCH}, is not supported. Only x86_64 is supported."
|
||||||
|
echo "Dying now."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Checking directory structure and creating lockfile at ${LOCKFILE}..."
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
|
||||||
|
# make sure the paths exist and then check for an existing chroot session
|
||||||
|
for i in ${ROOTDIR} ${CHROOTDIR32} ${CHROOTDIR64} ${BUILDDIR}32 ${BUILDDIR}64 ${ISODIR} ${MOUNTPT} ${TEMPDIR}/{${UXNAME},${DISTNAME}} ${ARCHBOOT} ${SRCDIR} ${TFTPDIR} ${HTTPDIR}/${DISTNAME} ${BASEDIR}/logs;
|
||||||
|
do
|
||||||
|
if [ ! -d ${i} ];
|
||||||
|
then
|
||||||
|
echo "${i} does not exist - creating."
|
||||||
|
mkdir -p ${i}
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
if [ ! -f "./BUILDNO" ];
|
||||||
|
then
|
||||||
|
echo '0' > ./BUILDNO
|
||||||
|
fi
|
||||||
|
|
||||||
|
CHROOTDIR_GLOB="${CHROOTDIR}"
|
||||||
|
BUILDDIR_GLOB="${BUILDDIR}"
|
||||||
|
|
||||||
|
# Set the version.
|
||||||
|
VERSION="$(git describe --abbrev=0 --tags)-$(git rev-parse --short --verify HEAD)"
|
||||||
|
BUILD="$(cat BUILDNO)"
|
||||||
|
BUILD="$(expr ${BUILD} + 1)"
|
||||||
|
echo ${BUILD} > ./BUILDNO
|
||||||
|
BUILDTIME="$(date)"
|
||||||
|
BUILD_MACHINE="$(hostname -f)"
|
||||||
|
#BUILD_USERNAME="${SUDO_USER}"
|
||||||
|
#BUILD_USERNAME="$(who am i | awk '{print $1}')"
|
||||||
|
set +e ; logname > /dev/null 2>&1
|
||||||
|
if [[ "${?}" == "0" ]];
|
||||||
|
then
|
||||||
|
BUILD_USERNAME="$(logname)"
|
||||||
|
else
|
||||||
|
BUILD_USERNAME="$(whoami)"
|
||||||
|
fi
|
||||||
|
set -e
|
||||||
|
USERNAME_REAL="$(grep ${BUILD_USERNAME} /etc/passwd | cut -f5 -d':')"
|
||||||
|
|
||||||
|
cat > VERSION_INFO.txt << EOF
|
||||||
|
Version: ${VERSION}
|
||||||
|
Build: ${BUILD}
|
||||||
|
Time: ${BUILDTIME}
|
||||||
|
Machine: ${BUILD_MACHINE}
|
||||||
|
User: ${BUILD_USERNAME} (${USERNAME_REAL})
|
||||||
|
EOF
|
||||||
|
|
||||||
|
## FUNCTIONS ##
|
||||||
|
|
||||||
|
source lib/00-im_batman.func.sh
|
||||||
|
source lib/01-holla_atcha_boi.func.sh
|
||||||
|
source lib/02-release_me.func.sh
|
||||||
|
source lib/03-facehugger.func.sh
|
||||||
|
source lib/04-chroot_wrapper.func.sh
|
||||||
|
source lib/05-jenny_craig.func.sh
|
||||||
|
source lib/06-centos_is_stupid.func.sh
|
||||||
|
source lib/07-will_it_blend.func.sh
|
||||||
|
source lib/08-stuffy.func.sh
|
||||||
|
source lib/09-yo_dj.func.sh
|
||||||
|
source lib/10-mentos.func.sh
|
||||||
|
|
||||||
|
## The Business-End(TM) ##
|
||||||
|
|
||||||
|
CHROOTDIR="${CHROOTDIR_GLOB}"
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
holla_atcha_boi
|
||||||
|
|
||||||
|
rm -rf ${TEMPDIR}/*
|
||||||
|
release_me 64 > /dev/null 2>&1
|
||||||
|
release_me 32 > /dev/null 2>&1
|
||||||
|
|
||||||
|
# do we need to perform any updates?
|
||||||
|
if [[ -f "${CHROOTDIR}root.x86_64/root/chroot" || -f "${CHROOTDIR}root.i686/root/chroot" ]];
|
||||||
|
then
|
||||||
|
chroot_wrapper 64
|
||||||
|
chroot_wrapper 32
|
||||||
|
centos_is_stupid
|
||||||
|
will_it_blend 64
|
||||||
|
will_it_blend 32
|
||||||
|
yo_dj
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ ${1} == "update" ]];
|
||||||
|
then
|
||||||
|
mentos
|
||||||
|
centos_is_stupid
|
||||||
|
will_it_blend 32
|
||||||
|
will_it_blend 64
|
||||||
|
yo_dj
|
||||||
|
fi
|
||||||
|
|
||||||
|
# or do we want to just chroot in?
|
||||||
|
if [[ ${1} == "chroot" ]];
|
||||||
|
then
|
||||||
|
chroot_wrapper 64
|
||||||
|
chroot_wrapper 32
|
||||||
|
rm -f ${LOCKFILE}
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# or are we just building?
|
||||||
|
if [[ ${1} == "build" ]] || [ -z ${1} ] || [[ ${1} == "all" ]];
|
||||||
|
then
|
||||||
|
if [[ "${MULTIARCH}" == "y" ]];
|
||||||
|
then
|
||||||
|
centos_is_stupid
|
||||||
|
will_it_blend 64
|
||||||
|
will_it_blend 32
|
||||||
|
yo_dj any
|
||||||
|
else
|
||||||
|
centos_is_stupid
|
||||||
|
will_it_blend 64
|
||||||
|
yo_dj 64
|
||||||
|
centos_is_stupid
|
||||||
|
will_it_blend 32
|
||||||
|
yo_dj 32
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
# clean up, clean up, everybody, everywhere
|
||||||
|
echo "Cleaning up some stuff leftover from the build..."
|
||||||
|
#rm -rf ${TEMPDIR}/*
|
||||||
|
#rm -rf ${SRCDIR}/*
|
||||||
|
cd ${ROOTDIR}
|
||||||
|
|
||||||
|
if [[ "${GIT}" == "yes" ]];
|
||||||
|
then
|
||||||
|
echo "Committing changes to git..."
|
||||||
|
git add --all .
|
||||||
|
git commit -m "post-build at $(date)"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# yay! we're done!
|
||||||
|
rm -f ${LOCKFILE}
|
||||||
|
echo "Finished successfully!"
|
||||||
Executable
+84
@@ -0,0 +1,84 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
## Import settings
|
||||||
|
if [ -f "build.conf" ];
|
||||||
|
then
|
||||||
|
echo "Now importing settings/variables."
|
||||||
|
set -e
|
||||||
|
source extra/build.conf.sample
|
||||||
|
source build.conf
|
||||||
|
set +e
|
||||||
|
else
|
||||||
|
echo "You have not configured a build.conf OR you are not running from the project's root directory (the git repository's working directory).
|
||||||
|
echo "If you are indeed in the correct directory, you may copy the sample at ../extra/build.conf.sample,
|
||||||
|
echo "edit it for appropriate values, and copy to <PROJECT ROOT>/build.conf"
|
||||||
|
echo
|
||||||
|
echo 'This error is fatal. Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ ${EUID} -ne 0 ]];
|
||||||
|
then
|
||||||
|
#echo "This script must be run as root" 1>&2
|
||||||
|
echo "This script must be run as root."
|
||||||
|
echo
|
||||||
|
exit 1
|
||||||
|
elif [ -f ${LOCKFILE} ];
|
||||||
|
then
|
||||||
|
echo "Script already running, stale lockfile present, or an error occurred during last run."
|
||||||
|
echo "Please clear ${LOCKFILE} by hand before attempting another build."
|
||||||
|
echo -n "Timestamp of lockfile is: "
|
||||||
|
ls -l ${LOCKFILE} | awk '{print $6" "$7" "$8}'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Creating lockfile at ${LOCKFILE}..."
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
|
||||||
|
if [[ "${1}" == "all" ]];
|
||||||
|
then
|
||||||
|
DIRS="${CHROOTDIR}root.i686 ${CHROOTDIR}root.x86_64 ${BUILDDIR}32 ${BUILDDIR}64 ${ISODIR} ${TEMPDIR} ${ARCHBOOT} ${SRCDIR} ${TFTPDIR} ${HTTPDIR} ${BASEDIR}/logs"
|
||||||
|
FILES="latest.32.tar.gz latest.64.tar.gz"
|
||||||
|
elif [[ "${1}" == "chroot" ]];
|
||||||
|
then
|
||||||
|
DIRS="${CHROOTDIR}root.i686 ${CHROOTDIR}root.x86_64 ${BUILDDIR}32 ${BUILDDIR}64 ${ISODIR} ${TEMPDIR} ${ARCHBOOT} ${SRCDIR} ${TFTPDIR} ${HTTPDIR}"
|
||||||
|
FILES=""
|
||||||
|
elif [[ "${1}" == "squash" ]];
|
||||||
|
then
|
||||||
|
DIRS="${BUILDDIR}32 ${BUILDDIR}64 ${ISODIR} ${TEMPDIR} ${ARCHBOOT} ${SRCDIR} ${TFTPDIR} ${HTTPDIR}"
|
||||||
|
FILES=""
|
||||||
|
else
|
||||||
|
DIRS="${ISODIR} ${TEMPDIR} ${ARCHBOOT} ${SRCDIR} ${TFTPDIR} ${HTTPDIR}"
|
||||||
|
FILES=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "I will be deleting the contents of: ${DIRS}"
|
||||||
|
echo "I will be deleting the files: ${FILES}"
|
||||||
|
read -p 'Do you wish to continue? [Y/n] ' CONFIRM
|
||||||
|
|
||||||
|
if [ -z "${CONFIRM}" ];
|
||||||
|
then
|
||||||
|
CONFIRM="y"
|
||||||
|
fi
|
||||||
|
|
||||||
|
CONFIRM=${CONFIRM:0:1}
|
||||||
|
CONFIRM=$(echo ${CONFIRM} | tr [[:upper:]] [[:lower:]])
|
||||||
|
|
||||||
|
if [[ "${CONFIRM}" != "y" ]];
|
||||||
|
then
|
||||||
|
echo 'Exiting.'
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
for i in "${DIRS}";
|
||||||
|
do
|
||||||
|
rm -rf ${i}/*
|
||||||
|
done
|
||||||
|
|
||||||
|
for i in "${FILES}";
|
||||||
|
do
|
||||||
|
rm -f ${i}
|
||||||
|
done
|
||||||
|
|
||||||
|
rm -f ${LOCKFILE}
|
||||||
Executable
+6
@@ -0,0 +1,6 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
curl -s -o /tmp/mirrorlist.tmp "https://www.archlinux.org/mirrorlist/?country=US&protocol=http&protocol=https&ip_version=4&use_mirror_status=on"
|
||||||
|
sed -i -e 's/^#Server/Server/' /tmp/mirrorlist.tmp
|
||||||
|
rankmirrors -n 6 /tmp/mirrorlist.tmp > extra/mirrorlist
|
||||||
|
sed -i -e '/^##/d' extra/mirrorlist
|
||||||
-674
@@ -1,674 +0,0 @@
|
|||||||
GNU GENERAL PUBLIC LICENSE
|
|
||||||
Version 3, 29 June 2007
|
|
||||||
|
|
||||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
|
||||||
Everyone is permitted to copy and distribute verbatim copies
|
|
||||||
of this license document, but changing it is not allowed.
|
|
||||||
|
|
||||||
Preamble
|
|
||||||
|
|
||||||
The GNU General Public License is a free, copyleft license for
|
|
||||||
software and other kinds of works.
|
|
||||||
|
|
||||||
The licenses for most software and other practical works are designed
|
|
||||||
to take away your freedom to share and change the works. By contrast,
|
|
||||||
the GNU General Public License is intended to guarantee your freedom to
|
|
||||||
share and change all versions of a program--to make sure it remains free
|
|
||||||
software for all its users. We, the Free Software Foundation, use the
|
|
||||||
GNU General Public License for most of our software; it applies also to
|
|
||||||
any other work released this way by its authors. You can apply it to
|
|
||||||
your programs, too.
|
|
||||||
|
|
||||||
When we speak of free software, we are referring to freedom, not
|
|
||||||
price. Our General Public Licenses are designed to make sure that you
|
|
||||||
have the freedom to distribute copies of free software (and charge for
|
|
||||||
them if you wish), that you receive source code or can get it if you
|
|
||||||
want it, that you can change the software or use pieces of it in new
|
|
||||||
free programs, and that you know you can do these things.
|
|
||||||
|
|
||||||
To protect your rights, we need to prevent others from denying you
|
|
||||||
these rights or asking you to surrender the rights. Therefore, you have
|
|
||||||
certain responsibilities if you distribute copies of the software, or if
|
|
||||||
you modify it: responsibilities to respect the freedom of others.
|
|
||||||
|
|
||||||
For example, if you distribute copies of such a program, whether
|
|
||||||
gratis or for a fee, you must pass on to the recipients the same
|
|
||||||
freedoms that you received. You must make sure that they, too, receive
|
|
||||||
or can get the source code. And you must show them these terms so they
|
|
||||||
know their rights.
|
|
||||||
|
|
||||||
Developers that use the GNU GPL protect your rights with two steps:
|
|
||||||
(1) assert copyright on the software, and (2) offer you this License
|
|
||||||
giving you legal permission to copy, distribute and/or modify it.
|
|
||||||
|
|
||||||
For the developers' and authors' protection, the GPL clearly explains
|
|
||||||
that there is no warranty for this free software. For both users' and
|
|
||||||
authors' sake, the GPL requires that modified versions be marked as
|
|
||||||
changed, so that their problems will not be attributed erroneously to
|
|
||||||
authors of previous versions.
|
|
||||||
|
|
||||||
Some devices are designed to deny users access to install or run
|
|
||||||
modified versions of the software inside them, although the manufacturer
|
|
||||||
can do so. This is fundamentally incompatible with the aim of
|
|
||||||
protecting users' freedom to change the software. The systematic
|
|
||||||
pattern of such abuse occurs in the area of products for individuals to
|
|
||||||
use, which is precisely where it is most unacceptable. Therefore, we
|
|
||||||
have designed this version of the GPL to prohibit the practice for those
|
|
||||||
products. If such problems arise substantially in other domains, we
|
|
||||||
stand ready to extend this provision to those domains in future versions
|
|
||||||
of the GPL, as needed to protect the freedom of users.
|
|
||||||
|
|
||||||
Finally, every program is threatened constantly by software patents.
|
|
||||||
States should not allow patents to restrict development and use of
|
|
||||||
software on general-purpose computers, but in those that do, we wish to
|
|
||||||
avoid the special danger that patents applied to a free program could
|
|
||||||
make it effectively proprietary. To prevent this, the GPL assures that
|
|
||||||
patents cannot be used to render the program non-free.
|
|
||||||
|
|
||||||
The precise terms and conditions for copying, distribution and
|
|
||||||
modification follow.
|
|
||||||
|
|
||||||
TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
0. Definitions.
|
|
||||||
|
|
||||||
"This License" refers to version 3 of the GNU General Public License.
|
|
||||||
|
|
||||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
|
||||||
works, such as semiconductor masks.
|
|
||||||
|
|
||||||
"The Program" refers to any copyrightable work licensed under this
|
|
||||||
License. Each licensee is addressed as "you". "Licensees" and
|
|
||||||
"recipients" may be individuals or organizations.
|
|
||||||
|
|
||||||
To "modify" a work means to copy from or adapt all or part of the work
|
|
||||||
in a fashion requiring copyright permission, other than the making of an
|
|
||||||
exact copy. The resulting work is called a "modified version" of the
|
|
||||||
earlier work or a work "based on" the earlier work.
|
|
||||||
|
|
||||||
A "covered work" means either the unmodified Program or a work based
|
|
||||||
on the Program.
|
|
||||||
|
|
||||||
To "propagate" a work means to do anything with it that, without
|
|
||||||
permission, would make you directly or secondarily liable for
|
|
||||||
infringement under applicable copyright law, except executing it on a
|
|
||||||
computer or modifying a private copy. Propagation includes copying,
|
|
||||||
distribution (with or without modification), making available to the
|
|
||||||
public, and in some countries other activities as well.
|
|
||||||
|
|
||||||
To "convey" a work means any kind of propagation that enables other
|
|
||||||
parties to make or receive copies. Mere interaction with a user through
|
|
||||||
a computer network, with no transfer of a copy, is not conveying.
|
|
||||||
|
|
||||||
An interactive user interface displays "Appropriate Legal Notices"
|
|
||||||
to the extent that it includes a convenient and prominently visible
|
|
||||||
feature that (1) displays an appropriate copyright notice, and (2)
|
|
||||||
tells the user that there is no warranty for the work (except to the
|
|
||||||
extent that warranties are provided), that licensees may convey the
|
|
||||||
work under this License, and how to view a copy of this License. If
|
|
||||||
the interface presents a list of user commands or options, such as a
|
|
||||||
menu, a prominent item in the list meets this criterion.
|
|
||||||
|
|
||||||
1. Source Code.
|
|
||||||
|
|
||||||
The "source code" for a work means the preferred form of the work
|
|
||||||
for making modifications to it. "Object code" means any non-source
|
|
||||||
form of a work.
|
|
||||||
|
|
||||||
A "Standard Interface" means an interface that either is an official
|
|
||||||
standard defined by a recognized standards body, or, in the case of
|
|
||||||
interfaces specified for a particular programming language, one that
|
|
||||||
is widely used among developers working in that language.
|
|
||||||
|
|
||||||
The "System Libraries" of an executable work include anything, other
|
|
||||||
than the work as a whole, that (a) is included in the normal form of
|
|
||||||
packaging a Major Component, but which is not part of that Major
|
|
||||||
Component, and (b) serves only to enable use of the work with that
|
|
||||||
Major Component, or to implement a Standard Interface for which an
|
|
||||||
implementation is available to the public in source code form. A
|
|
||||||
"Major Component", in this context, means a major essential component
|
|
||||||
(kernel, window system, and so on) of the specific operating system
|
|
||||||
(if any) on which the executable work runs, or a compiler used to
|
|
||||||
produce the work, or an object code interpreter used to run it.
|
|
||||||
|
|
||||||
The "Corresponding Source" for a work in object code form means all
|
|
||||||
the source code needed to generate, install, and (for an executable
|
|
||||||
work) run the object code and to modify the work, including scripts to
|
|
||||||
control those activities. However, it does not include the work's
|
|
||||||
System Libraries, or general-purpose tools or generally available free
|
|
||||||
programs which are used unmodified in performing those activities but
|
|
||||||
which are not part of the work. For example, Corresponding Source
|
|
||||||
includes interface definition files associated with source files for
|
|
||||||
the work, and the source code for shared libraries and dynamically
|
|
||||||
linked subprograms that the work is specifically designed to require,
|
|
||||||
such as by intimate data communication or control flow between those
|
|
||||||
subprograms and other parts of the work.
|
|
||||||
|
|
||||||
The Corresponding Source need not include anything that users
|
|
||||||
can regenerate automatically from other parts of the Corresponding
|
|
||||||
Source.
|
|
||||||
|
|
||||||
The Corresponding Source for a work in source code form is that
|
|
||||||
same work.
|
|
||||||
|
|
||||||
2. Basic Permissions.
|
|
||||||
|
|
||||||
All rights granted under this License are granted for the term of
|
|
||||||
copyright on the Program, and are irrevocable provided the stated
|
|
||||||
conditions are met. This License explicitly affirms your unlimited
|
|
||||||
permission to run the unmodified Program. The output from running a
|
|
||||||
covered work is covered by this License only if the output, given its
|
|
||||||
content, constitutes a covered work. This License acknowledges your
|
|
||||||
rights of fair use or other equivalent, as provided by copyright law.
|
|
||||||
|
|
||||||
You may make, run and propagate covered works that you do not
|
|
||||||
convey, without conditions so long as your license otherwise remains
|
|
||||||
in force. You may convey covered works to others for the sole purpose
|
|
||||||
of having them make modifications exclusively for you, or provide you
|
|
||||||
with facilities for running those works, provided that you comply with
|
|
||||||
the terms of this License in conveying all material for which you do
|
|
||||||
not control copyright. Those thus making or running the covered works
|
|
||||||
for you must do so exclusively on your behalf, under your direction
|
|
||||||
and control, on terms that prohibit them from making any copies of
|
|
||||||
your copyrighted material outside their relationship with you.
|
|
||||||
|
|
||||||
Conveying under any other circumstances is permitted solely under
|
|
||||||
the conditions stated below. Sublicensing is not allowed; section 10
|
|
||||||
makes it unnecessary.
|
|
||||||
|
|
||||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
|
||||||
|
|
||||||
No covered work shall be deemed part of an effective technological
|
|
||||||
measure under any applicable law fulfilling obligations under article
|
|
||||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
|
||||||
similar laws prohibiting or restricting circumvention of such
|
|
||||||
measures.
|
|
||||||
|
|
||||||
When you convey a covered work, you waive any legal power to forbid
|
|
||||||
circumvention of technological measures to the extent such circumvention
|
|
||||||
is effected by exercising rights under this License with respect to
|
|
||||||
the covered work, and you disclaim any intention to limit operation or
|
|
||||||
modification of the work as a means of enforcing, against the work's
|
|
||||||
users, your or third parties' legal rights to forbid circumvention of
|
|
||||||
technological measures.
|
|
||||||
|
|
||||||
4. Conveying Verbatim Copies.
|
|
||||||
|
|
||||||
You may convey verbatim copies of the Program's source code as you
|
|
||||||
receive it, in any medium, provided that you conspicuously and
|
|
||||||
appropriately publish on each copy an appropriate copyright notice;
|
|
||||||
keep intact all notices stating that this License and any
|
|
||||||
non-permissive terms added in accord with section 7 apply to the code;
|
|
||||||
keep intact all notices of the absence of any warranty; and give all
|
|
||||||
recipients a copy of this License along with the Program.
|
|
||||||
|
|
||||||
You may charge any price or no price for each copy that you convey,
|
|
||||||
and you may offer support or warranty protection for a fee.
|
|
||||||
|
|
||||||
5. Conveying Modified Source Versions.
|
|
||||||
|
|
||||||
You may convey a work based on the Program, or the modifications to
|
|
||||||
produce it from the Program, in the form of source code under the
|
|
||||||
terms of section 4, provided that you also meet all of these conditions:
|
|
||||||
|
|
||||||
a) The work must carry prominent notices stating that you modified
|
|
||||||
it, and giving a relevant date.
|
|
||||||
|
|
||||||
b) The work must carry prominent notices stating that it is
|
|
||||||
released under this License and any conditions added under section
|
|
||||||
7. This requirement modifies the requirement in section 4 to
|
|
||||||
"keep intact all notices".
|
|
||||||
|
|
||||||
c) You must license the entire work, as a whole, under this
|
|
||||||
License to anyone who comes into possession of a copy. This
|
|
||||||
License will therefore apply, along with any applicable section 7
|
|
||||||
additional terms, to the whole of the work, and all its parts,
|
|
||||||
regardless of how they are packaged. This License gives no
|
|
||||||
permission to license the work in any other way, but it does not
|
|
||||||
invalidate such permission if you have separately received it.
|
|
||||||
|
|
||||||
d) If the work has interactive user interfaces, each must display
|
|
||||||
Appropriate Legal Notices; however, if the Program has interactive
|
|
||||||
interfaces that do not display Appropriate Legal Notices, your
|
|
||||||
work need not make them do so.
|
|
||||||
|
|
||||||
A compilation of a covered work with other separate and independent
|
|
||||||
works, which are not by their nature extensions of the covered work,
|
|
||||||
and which are not combined with it such as to form a larger program,
|
|
||||||
in or on a volume of a storage or distribution medium, is called an
|
|
||||||
"aggregate" if the compilation and its resulting copyright are not
|
|
||||||
used to limit the access or legal rights of the compilation's users
|
|
||||||
beyond what the individual works permit. Inclusion of a covered work
|
|
||||||
in an aggregate does not cause this License to apply to the other
|
|
||||||
parts of the aggregate.
|
|
||||||
|
|
||||||
6. Conveying Non-Source Forms.
|
|
||||||
|
|
||||||
You may convey a covered work in object code form under the terms
|
|
||||||
of sections 4 and 5, provided that you also convey the
|
|
||||||
machine-readable Corresponding Source under the terms of this License,
|
|
||||||
in one of these ways:
|
|
||||||
|
|
||||||
a) Convey the object code in, or embodied in, a physical product
|
|
||||||
(including a physical distribution medium), accompanied by the
|
|
||||||
Corresponding Source fixed on a durable physical medium
|
|
||||||
customarily used for software interchange.
|
|
||||||
|
|
||||||
b) Convey the object code in, or embodied in, a physical product
|
|
||||||
(including a physical distribution medium), accompanied by a
|
|
||||||
written offer, valid for at least three years and valid for as
|
|
||||||
long as you offer spare parts or customer support for that product
|
|
||||||
model, to give anyone who possesses the object code either (1) a
|
|
||||||
copy of the Corresponding Source for all the software in the
|
|
||||||
product that is covered by this License, on a durable physical
|
|
||||||
medium customarily used for software interchange, for a price no
|
|
||||||
more than your reasonable cost of physically performing this
|
|
||||||
conveying of source, or (2) access to copy the
|
|
||||||
Corresponding Source from a network server at no charge.
|
|
||||||
|
|
||||||
c) Convey individual copies of the object code with a copy of the
|
|
||||||
written offer to provide the Corresponding Source. This
|
|
||||||
alternative is allowed only occasionally and noncommercially, and
|
|
||||||
only if you received the object code with such an offer, in accord
|
|
||||||
with subsection 6b.
|
|
||||||
|
|
||||||
d) Convey the object code by offering access from a designated
|
|
||||||
place (gratis or for a charge), and offer equivalent access to the
|
|
||||||
Corresponding Source in the same way through the same place at no
|
|
||||||
further charge. You need not require recipients to copy the
|
|
||||||
Corresponding Source along with the object code. If the place to
|
|
||||||
copy the object code is a network server, the Corresponding Source
|
|
||||||
may be on a different server (operated by you or a third party)
|
|
||||||
that supports equivalent copying facilities, provided you maintain
|
|
||||||
clear directions next to the object code saying where to find the
|
|
||||||
Corresponding Source. Regardless of what server hosts the
|
|
||||||
Corresponding Source, you remain obligated to ensure that it is
|
|
||||||
available for as long as needed to satisfy these requirements.
|
|
||||||
|
|
||||||
e) Convey the object code using peer-to-peer transmission, provided
|
|
||||||
you inform other peers where the object code and Corresponding
|
|
||||||
Source of the work are being offered to the general public at no
|
|
||||||
charge under subsection 6d.
|
|
||||||
|
|
||||||
A separable portion of the object code, whose source code is excluded
|
|
||||||
from the Corresponding Source as a System Library, need not be
|
|
||||||
included in conveying the object code work.
|
|
||||||
|
|
||||||
A "User Product" is either (1) a "consumer product", which means any
|
|
||||||
tangible personal property which is normally used for personal, family,
|
|
||||||
or household purposes, or (2) anything designed or sold for incorporation
|
|
||||||
into a dwelling. In determining whether a product is a consumer product,
|
|
||||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
|
||||||
product received by a particular user, "normally used" refers to a
|
|
||||||
typical or common use of that class of product, regardless of the status
|
|
||||||
of the particular user or of the way in which the particular user
|
|
||||||
actually uses, or expects or is expected to use, the product. A product
|
|
||||||
is a consumer product regardless of whether the product has substantial
|
|
||||||
commercial, industrial or non-consumer uses, unless such uses represent
|
|
||||||
the only significant mode of use of the product.
|
|
||||||
|
|
||||||
"Installation Information" for a User Product means any methods,
|
|
||||||
procedures, authorization keys, or other information required to install
|
|
||||||
and execute modified versions of a covered work in that User Product from
|
|
||||||
a modified version of its Corresponding Source. The information must
|
|
||||||
suffice to ensure that the continued functioning of the modified object
|
|
||||||
code is in no case prevented or interfered with solely because
|
|
||||||
modification has been made.
|
|
||||||
|
|
||||||
If you convey an object code work under this section in, or with, or
|
|
||||||
specifically for use in, a User Product, and the conveying occurs as
|
|
||||||
part of a transaction in which the right of possession and use of the
|
|
||||||
User Product is transferred to the recipient in perpetuity or for a
|
|
||||||
fixed term (regardless of how the transaction is characterized), the
|
|
||||||
Corresponding Source conveyed under this section must be accompanied
|
|
||||||
by the Installation Information. But this requirement does not apply
|
|
||||||
if neither you nor any third party retains the ability to install
|
|
||||||
modified object code on the User Product (for example, the work has
|
|
||||||
been installed in ROM).
|
|
||||||
|
|
||||||
The requirement to provide Installation Information does not include a
|
|
||||||
requirement to continue to provide support service, warranty, or updates
|
|
||||||
for a work that has been modified or installed by the recipient, or for
|
|
||||||
the User Product in which it has been modified or installed. Access to a
|
|
||||||
network may be denied when the modification itself materially and
|
|
||||||
adversely affects the operation of the network or violates the rules and
|
|
||||||
protocols for communication across the network.
|
|
||||||
|
|
||||||
Corresponding Source conveyed, and Installation Information provided,
|
|
||||||
in accord with this section must be in a format that is publicly
|
|
||||||
documented (and with an implementation available to the public in
|
|
||||||
source code form), and must require no special password or key for
|
|
||||||
unpacking, reading or copying.
|
|
||||||
|
|
||||||
7. Additional Terms.
|
|
||||||
|
|
||||||
"Additional permissions" are terms that supplement the terms of this
|
|
||||||
License by making exceptions from one or more of its conditions.
|
|
||||||
Additional permissions that are applicable to the entire Program shall
|
|
||||||
be treated as though they were included in this License, to the extent
|
|
||||||
that they are valid under applicable law. If additional permissions
|
|
||||||
apply only to part of the Program, that part may be used separately
|
|
||||||
under those permissions, but the entire Program remains governed by
|
|
||||||
this License without regard to the additional permissions.
|
|
||||||
|
|
||||||
When you convey a copy of a covered work, you may at your option
|
|
||||||
remove any additional permissions from that copy, or from any part of
|
|
||||||
it. (Additional permissions may be written to require their own
|
|
||||||
removal in certain cases when you modify the work.) You may place
|
|
||||||
additional permissions on material, added by you to a covered work,
|
|
||||||
for which you have or can give appropriate copyright permission.
|
|
||||||
|
|
||||||
Notwithstanding any other provision of this License, for material you
|
|
||||||
add to a covered work, you may (if authorized by the copyright holders of
|
|
||||||
that material) supplement the terms of this License with terms:
|
|
||||||
|
|
||||||
a) Disclaiming warranty or limiting liability differently from the
|
|
||||||
terms of sections 15 and 16 of this License; or
|
|
||||||
|
|
||||||
b) Requiring preservation of specified reasonable legal notices or
|
|
||||||
author attributions in that material or in the Appropriate Legal
|
|
||||||
Notices displayed by works containing it; or
|
|
||||||
|
|
||||||
c) Prohibiting misrepresentation of the origin of that material, or
|
|
||||||
requiring that modified versions of such material be marked in
|
|
||||||
reasonable ways as different from the original version; or
|
|
||||||
|
|
||||||
d) Limiting the use for publicity purposes of names of licensors or
|
|
||||||
authors of the material; or
|
|
||||||
|
|
||||||
e) Declining to grant rights under trademark law for use of some
|
|
||||||
trade names, trademarks, or service marks; or
|
|
||||||
|
|
||||||
f) Requiring indemnification of licensors and authors of that
|
|
||||||
material by anyone who conveys the material (or modified versions of
|
|
||||||
it) with contractual assumptions of liability to the recipient, for
|
|
||||||
any liability that these contractual assumptions directly impose on
|
|
||||||
those licensors and authors.
|
|
||||||
|
|
||||||
All other non-permissive additional terms are considered "further
|
|
||||||
restrictions" within the meaning of section 10. If the Program as you
|
|
||||||
received it, or any part of it, contains a notice stating that it is
|
|
||||||
governed by this License along with a term that is a further
|
|
||||||
restriction, you may remove that term. If a license document contains
|
|
||||||
a further restriction but permits relicensing or conveying under this
|
|
||||||
License, you may add to a covered work material governed by the terms
|
|
||||||
of that license document, provided that the further restriction does
|
|
||||||
not survive such relicensing or conveying.
|
|
||||||
|
|
||||||
If you add terms to a covered work in accord with this section, you
|
|
||||||
must place, in the relevant source files, a statement of the
|
|
||||||
additional terms that apply to those files, or a notice indicating
|
|
||||||
where to find the applicable terms.
|
|
||||||
|
|
||||||
Additional terms, permissive or non-permissive, may be stated in the
|
|
||||||
form of a separately written license, or stated as exceptions;
|
|
||||||
the above requirements apply either way.
|
|
||||||
|
|
||||||
8. Termination.
|
|
||||||
|
|
||||||
You may not propagate or modify a covered work except as expressly
|
|
||||||
provided under this License. Any attempt otherwise to propagate or
|
|
||||||
modify it is void, and will automatically terminate your rights under
|
|
||||||
this License (including any patent licenses granted under the third
|
|
||||||
paragraph of section 11).
|
|
||||||
|
|
||||||
However, if you cease all violation of this License, then your
|
|
||||||
license from a particular copyright holder is reinstated (a)
|
|
||||||
provisionally, unless and until the copyright holder explicitly and
|
|
||||||
finally terminates your license, and (b) permanently, if the copyright
|
|
||||||
holder fails to notify you of the violation by some reasonable means
|
|
||||||
prior to 60 days after the cessation.
|
|
||||||
|
|
||||||
Moreover, your license from a particular copyright holder is
|
|
||||||
reinstated permanently if the copyright holder notifies you of the
|
|
||||||
violation by some reasonable means, this is the first time you have
|
|
||||||
received notice of violation of this License (for any work) from that
|
|
||||||
copyright holder, and you cure the violation prior to 30 days after
|
|
||||||
your receipt of the notice.
|
|
||||||
|
|
||||||
Termination of your rights under this section does not terminate the
|
|
||||||
licenses of parties who have received copies or rights from you under
|
|
||||||
this License. If your rights have been terminated and not permanently
|
|
||||||
reinstated, you do not qualify to receive new licenses for the same
|
|
||||||
material under section 10.
|
|
||||||
|
|
||||||
9. Acceptance Not Required for Having Copies.
|
|
||||||
|
|
||||||
You are not required to accept this License in order to receive or
|
|
||||||
run a copy of the Program. Ancillary propagation of a covered work
|
|
||||||
occurring solely as a consequence of using peer-to-peer transmission
|
|
||||||
to receive a copy likewise does not require acceptance. However,
|
|
||||||
nothing other than this License grants you permission to propagate or
|
|
||||||
modify any covered work. These actions infringe copyright if you do
|
|
||||||
not accept this License. Therefore, by modifying or propagating a
|
|
||||||
covered work, you indicate your acceptance of this License to do so.
|
|
||||||
|
|
||||||
10. Automatic Licensing of Downstream Recipients.
|
|
||||||
|
|
||||||
Each time you convey a covered work, the recipient automatically
|
|
||||||
receives a license from the original licensors, to run, modify and
|
|
||||||
propagate that work, subject to this License. You are not responsible
|
|
||||||
for enforcing compliance by third parties with this License.
|
|
||||||
|
|
||||||
An "entity transaction" is a transaction transferring control of an
|
|
||||||
organization, or substantially all assets of one, or subdividing an
|
|
||||||
organization, or merging organizations. If propagation of a covered
|
|
||||||
work results from an entity transaction, each party to that
|
|
||||||
transaction who receives a copy of the work also receives whatever
|
|
||||||
licenses to the work the party's predecessor in interest had or could
|
|
||||||
give under the previous paragraph, plus a right to possession of the
|
|
||||||
Corresponding Source of the work from the predecessor in interest, if
|
|
||||||
the predecessor has it or can get it with reasonable efforts.
|
|
||||||
|
|
||||||
You may not impose any further restrictions on the exercise of the
|
|
||||||
rights granted or affirmed under this License. For example, you may
|
|
||||||
not impose a license fee, royalty, or other charge for exercise of
|
|
||||||
rights granted under this License, and you may not initiate litigation
|
|
||||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
|
||||||
any patent claim is infringed by making, using, selling, offering for
|
|
||||||
sale, or importing the Program or any portion of it.
|
|
||||||
|
|
||||||
11. Patents.
|
|
||||||
|
|
||||||
A "contributor" is a copyright holder who authorizes use under this
|
|
||||||
License of the Program or a work on which the Program is based. The
|
|
||||||
work thus licensed is called the contributor's "contributor version".
|
|
||||||
|
|
||||||
A contributor's "essential patent claims" are all patent claims
|
|
||||||
owned or controlled by the contributor, whether already acquired or
|
|
||||||
hereafter acquired, that would be infringed by some manner, permitted
|
|
||||||
by this License, of making, using, or selling its contributor version,
|
|
||||||
but do not include claims that would be infringed only as a
|
|
||||||
consequence of further modification of the contributor version. For
|
|
||||||
purposes of this definition, "control" includes the right to grant
|
|
||||||
patent sublicenses in a manner consistent with the requirements of
|
|
||||||
this License.
|
|
||||||
|
|
||||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
|
||||||
patent license under the contributor's essential patent claims, to
|
|
||||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
|
||||||
propagate the contents of its contributor version.
|
|
||||||
|
|
||||||
In the following three paragraphs, a "patent license" is any express
|
|
||||||
agreement or commitment, however denominated, not to enforce a patent
|
|
||||||
(such as an express permission to practice a patent or covenant not to
|
|
||||||
sue for patent infringement). To "grant" such a patent license to a
|
|
||||||
party means to make such an agreement or commitment not to enforce a
|
|
||||||
patent against the party.
|
|
||||||
|
|
||||||
If you convey a covered work, knowingly relying on a patent license,
|
|
||||||
and the Corresponding Source of the work is not available for anyone
|
|
||||||
to copy, free of charge and under the terms of this License, through a
|
|
||||||
publicly available network server or other readily accessible means,
|
|
||||||
then you must either (1) cause the Corresponding Source to be so
|
|
||||||
available, or (2) arrange to deprive yourself of the benefit of the
|
|
||||||
patent license for this particular work, or (3) arrange, in a manner
|
|
||||||
consistent with the requirements of this License, to extend the patent
|
|
||||||
license to downstream recipients. "Knowingly relying" means you have
|
|
||||||
actual knowledge that, but for the patent license, your conveying the
|
|
||||||
covered work in a country, or your recipient's use of the covered work
|
|
||||||
in a country, would infringe one or more identifiable patents in that
|
|
||||||
country that you have reason to believe are valid.
|
|
||||||
|
|
||||||
If, pursuant to or in connection with a single transaction or
|
|
||||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
|
||||||
covered work, and grant a patent license to some of the parties
|
|
||||||
receiving the covered work authorizing them to use, propagate, modify
|
|
||||||
or convey a specific copy of the covered work, then the patent license
|
|
||||||
you grant is automatically extended to all recipients of the covered
|
|
||||||
work and works based on it.
|
|
||||||
|
|
||||||
A patent license is "discriminatory" if it does not include within
|
|
||||||
the scope of its coverage, prohibits the exercise of, or is
|
|
||||||
conditioned on the non-exercise of one or more of the rights that are
|
|
||||||
specifically granted under this License. You may not convey a covered
|
|
||||||
work if you are a party to an arrangement with a third party that is
|
|
||||||
in the business of distributing software, under which you make payment
|
|
||||||
to the third party based on the extent of your activity of conveying
|
|
||||||
the work, and under which the third party grants, to any of the
|
|
||||||
parties who would receive the covered work from you, a discriminatory
|
|
||||||
patent license (a) in connection with copies of the covered work
|
|
||||||
conveyed by you (or copies made from those copies), or (b) primarily
|
|
||||||
for and in connection with specific products or compilations that
|
|
||||||
contain the covered work, unless you entered into that arrangement,
|
|
||||||
or that patent license was granted, prior to 28 March 2007.
|
|
||||||
|
|
||||||
Nothing in this License shall be construed as excluding or limiting
|
|
||||||
any implied license or other defenses to infringement that may
|
|
||||||
otherwise be available to you under applicable patent law.
|
|
||||||
|
|
||||||
12. No Surrender of Others' Freedom.
|
|
||||||
|
|
||||||
If conditions are imposed on you (whether by court order, agreement or
|
|
||||||
otherwise) that contradict the conditions of this License, they do not
|
|
||||||
excuse you from the conditions of this License. If you cannot convey a
|
|
||||||
covered work so as to satisfy simultaneously your obligations under this
|
|
||||||
License and any other pertinent obligations, then as a consequence you may
|
|
||||||
not convey it at all. For example, if you agree to terms that obligate you
|
|
||||||
to collect a royalty for further conveying from those to whom you convey
|
|
||||||
the Program, the only way you could satisfy both those terms and this
|
|
||||||
License would be to refrain entirely from conveying the Program.
|
|
||||||
|
|
||||||
13. Use with the GNU Affero General Public License.
|
|
||||||
|
|
||||||
Notwithstanding any other provision of this License, you have
|
|
||||||
permission to link or combine any covered work with a work licensed
|
|
||||||
under version 3 of the GNU Affero General Public License into a single
|
|
||||||
combined work, and to convey the resulting work. The terms of this
|
|
||||||
License will continue to apply to the part which is the covered work,
|
|
||||||
but the special requirements of the GNU Affero General Public License,
|
|
||||||
section 13, concerning interaction through a network will apply to the
|
|
||||||
combination as such.
|
|
||||||
|
|
||||||
14. Revised Versions of this License.
|
|
||||||
|
|
||||||
The Free Software Foundation may publish revised and/or new versions of
|
|
||||||
the GNU General Public License from time to time. Such new versions will
|
|
||||||
be similar in spirit to the present version, but may differ in detail to
|
|
||||||
address new problems or concerns.
|
|
||||||
|
|
||||||
Each version is given a distinguishing version number. If the
|
|
||||||
Program specifies that a certain numbered version of the GNU General
|
|
||||||
Public License "or any later version" applies to it, you have the
|
|
||||||
option of following the terms and conditions either of that numbered
|
|
||||||
version or of any later version published by the Free Software
|
|
||||||
Foundation. If the Program does not specify a version number of the
|
|
||||||
GNU General Public License, you may choose any version ever published
|
|
||||||
by the Free Software Foundation.
|
|
||||||
|
|
||||||
If the Program specifies that a proxy can decide which future
|
|
||||||
versions of the GNU General Public License can be used, that proxy's
|
|
||||||
public statement of acceptance of a version permanently authorizes you
|
|
||||||
to choose that version for the Program.
|
|
||||||
|
|
||||||
Later license versions may give you additional or different
|
|
||||||
permissions. However, no additional obligations are imposed on any
|
|
||||||
author or copyright holder as a result of your choosing to follow a
|
|
||||||
later version.
|
|
||||||
|
|
||||||
15. Disclaimer of Warranty.
|
|
||||||
|
|
||||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
|
||||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
|
||||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
|
||||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
|
||||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
|
||||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
|
||||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
|
||||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
|
||||||
|
|
||||||
16. Limitation of Liability.
|
|
||||||
|
|
||||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
|
||||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
|
||||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
|
||||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
|
||||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
|
||||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
|
||||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
|
||||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
|
||||||
SUCH DAMAGES.
|
|
||||||
|
|
||||||
17. Interpretation of Sections 15 and 16.
|
|
||||||
|
|
||||||
If the disclaimer of warranty and limitation of liability provided
|
|
||||||
above cannot be given local legal effect according to their terms,
|
|
||||||
reviewing courts shall apply local law that most closely approximates
|
|
||||||
an absolute waiver of all civil liability in connection with the
|
|
||||||
Program, unless a warranty or assumption of liability accompanies a
|
|
||||||
copy of the Program in return for a fee.
|
|
||||||
|
|
||||||
END OF TERMS AND CONDITIONS
|
|
||||||
|
|
||||||
How to Apply These Terms to Your New Programs
|
|
||||||
|
|
||||||
If you develop a new program, and you want it to be of the greatest
|
|
||||||
possible use to the public, the best way to achieve this is to make it
|
|
||||||
free software which everyone can redistribute and change under these terms.
|
|
||||||
|
|
||||||
To do so, attach the following notices to the program. It is safest
|
|
||||||
to attach them to the start of each source file to most effectively
|
|
||||||
state the exclusion of warranty; and each file should have at least
|
|
||||||
the "copyright" line and a pointer to where the full notice is found.
|
|
||||||
|
|
||||||
<one line to give the program's name and a brief idea of what it does.>
|
|
||||||
Copyright (C) <year> <name of author>
|
|
||||||
|
|
||||||
This program is free software: you can redistribute it and/or modify
|
|
||||||
it under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
This program is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
Also add information on how to contact you by electronic and paper mail.
|
|
||||||
|
|
||||||
If the program does terminal interaction, make it output a short
|
|
||||||
notice like this when it starts in an interactive mode:
|
|
||||||
|
|
||||||
<program> Copyright (C) <year> <name of author>
|
|
||||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
|
||||||
This is free software, and you are welcome to redistribute it
|
|
||||||
under certain conditions; type `show c' for details.
|
|
||||||
|
|
||||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
|
||||||
parts of the General Public License. Of course, your program's commands
|
|
||||||
might be different; for a GUI interface, you would use an "about box".
|
|
||||||
|
|
||||||
You should also get your employer (if you work as a programmer) or school,
|
|
||||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
|
||||||
For more information on this, and how to apply and follow the GNU GPL, see
|
|
||||||
<http://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
The GNU General Public License does not permit incorporating your program
|
|
||||||
into proprietary programs. If your program is a subroutine library, you
|
|
||||||
may consider it more useful to permit linking proprietary applications with
|
|
||||||
the library. If this is what you want to do, use the GNU Lesser General
|
|
||||||
Public License instead of this License. But first, please read
|
|
||||||
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
BDisk Frequently Asked(/Unasked) Questions
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
0.) Why does it take so long to build?
|
|
||||||
1.) Why is the generated ISO file so big?
|
|
||||||
2.) How do I find the version/release/etc. number of an ISO?
|
|
||||||
|
|
||||||
|
|
||||||
=========================================================
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
0.) WHY DOES IT TAKE SO LONG TO BUILD?
|
|
||||||
A: This typically occurs when you're building from within a LiveCD/LiveUSB situation, in a VM/container/etc., or on a headless server.
|
|
||||||
If this is the case, you may run into what appears to be "stalling", especially while keys are generating for the chroots.
|
|
||||||
Thankfully, there is an easy fix. You can install the "haveged"(http://www.issihosts.com/haveged/) software and run it. This will
|
|
||||||
show an immediate and non-negligible improvement for the above contexts. If you have extra power to throw at it (or are using a dedicated build box)
|
|
||||||
as well, I recommend enabling I_AM_A_RACECAR in your build.conf. BDisk will then be more aggressive with its resource consumption.
|
|
||||||
|
|
||||||
|
|
||||||
1.) WHY IS THE GENERATED ISO FILE SO BIG?
|
|
||||||
A: You may have enabled a LOT of packages in extra/packages.(32|64|both). Or you're using the default set of packages, which tries to include a LOT
|
|
||||||
of different (and in some cases, redundant) packages for widespread utilization and usage. In addition, keep in mind that BDisk builds a single ISO
|
|
||||||
that can be used on both i686 architectures AND full x86_64 architectures ("AMD64" as you may sometimes see it referenced). Because it doesn't cheat
|
|
||||||
and just use a 64-bit kernel with a 32-bit userland, it needs two different squash images on each ISO- one for 32-bit userland and one for 64-bit
|
|
||||||
userland.
|
|
||||||
|
|
||||||
2.) HOW DO I FIND THE VERSION/RELEASE/ETC. NUMBER OF AN ISO?
|
|
||||||
A: This can be found in a multitude of places. The full-size ISO file (iso/<distname>-<git tag>-<git rev number>-(32|64|any).iso) should have the
|
|
||||||
version right in the file name. If you want more detailed information (or perhaps you renamed the file), you can mount the ISO as loopback in GNU/Linux,
|
|
||||||
*BSD, or Mac OS X and check /path/to/mounted/iso/VERSION_INTO.txt. Lastly, within the runtime itself (especially handy if booting via iPXE), you can
|
|
||||||
check /root/VERSION_INFO.txt within the running live environment.
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
COPYING
|
|
||||||
-170
@@ -1,170 +0,0 @@
|
|||||||
######################################################################################################################################
|
|
||||||
##### BDisk #####
|
|
||||||
##### #####
|
|
||||||
##### Written by Brent Saner #####
|
|
||||||
##### <bts@square-r00t.net> #####
|
|
||||||
##### Built upon my (Brent's) 'BDisk' ISO-building framework (http://bdisk.square-r00t.net) #####
|
|
||||||
######################################################################################################################################
|
|
||||||
|
|
||||||
!!!!!! WARNING !!!!!!!
|
|
||||||
I do NOT recommend running this on a machine that is using wireless, as it will download a LOT of data.
|
|
||||||
If you ignore this warning, be prepared to explain to anyone you share your wifi with why Facebook takes 20 seconds to load,
|
|
||||||
because they WILL ask.
|
|
||||||
|
|
||||||
It should be fine over ethernet, since hardware switches are much faster and efficient than a single duplex wireless radio.
|
|
||||||
|
|
||||||
Future versions, once this project has a dumping ground, will fetch highly compressed snapshotted chroot filesystems instead
|
|
||||||
of dynamically building the entire install chroots (both x86_64 and i686) instead (with the option of building fresh locally,
|
|
||||||
disabled by default).
|
|
||||||
Till then, sorry for the inconvenience.
|
|
||||||
!!!!!!!!!!!!!!!!!!!!!!
|
|
||||||
|
|
||||||
|
|
||||||
## Why Arch? ##
|
|
||||||
Because it's a largely easy-to-use, well-documented (https://wiki.archlinux.org/) distro. It's no-frills and incredibly
|
|
||||||
flexible/customizable, and can be made rather slim. It's also very friendly to run as a chroot inside any other distro.
|
|
||||||
|
|
||||||
All commands below should be issued in the root working directory of this git repository. (For me, this is
|
|
||||||
/opt/dev/work/BDisk but this may be entirely different for you, depending on where you cloned the repository to.)
|
|
||||||
|
|
||||||
## Features ##
|
|
||||||
-Builds a hybrid ISO
|
|
||||||
A hybrid ISO allows one to simply dd if=/path/to/file.iso of=/dev/<USB STICK> instead of using e.g. UNetBootin while also
|
|
||||||
working with traditional optical media.
|
|
||||||
-Builds a dual-architecture ISO
|
|
||||||
BDisk allows you to create both a 32-bit and 64-bit ISO, either separately or part of the same ISO, and customize each
|
|
||||||
based on architecture.
|
|
||||||
-Supports both BIOS and UEFI booting in one ISO
|
|
||||||
It can be difficult finding a live distribution that offers full UEFI support, which is frustrating if you're trying to
|
|
||||||
install e.g. UEFI-enabled Gentoo, for instance. Not only does this ISO framework build support for both in the same ISO,
|
|
||||||
but it also includes some UEFI shells as well.
|
|
||||||
-Arch install scripts
|
|
||||||
This live distro, assuming default packages are kept, should be 100% compatible with the Arch install guide
|
|
||||||
(https://wiki.archlinux.org/index.php/installation_guide).
|
|
||||||
-Allows for non-interactive runs, is git-friendly, logs all output while keeping the runtime output relatively sane, and allows
|
|
||||||
the inclusion of arbitrary files in the finished filesystem.
|
|
||||||
-TFP/HTTP/PXE support
|
|
||||||
It will automatically copy over some files to tftpboot/ and http/, greatly saving some time in PXE booting. It also
|
|
||||||
supports, by default, booting PXE with HTTP fetching for the squashed filesystems. Say goodbye to NFS. You can even
|
|
||||||
automatically rsync over after the build, if you wish, to your webserver (see sub-point)
|
|
||||||
-Additionally, it supports iPXE if enabled in the configuration file. Please see examples/HTTP for an example of how to
|
|
||||||
lay this out and what sort of directory hierarchy is needed.
|
|
||||||
-Automatic versioning based on git tags
|
|
||||||
|
|
||||||
## Prerequisites ##
|
|
||||||
-At least ~20Gb disk space free (remember, you need room for not only four chroots (one developing and one staging for i686/x86_64),
|
|
||||||
but also disk space for working, the finished ISO(s), etc.)
|
|
||||||
|
|
||||||
-The following packages installed on the build host:
|
|
||||||
(NOTE: future versions will have dependencies checked automatically and installed if necessary,
|
|
||||||
depending on distro your host build machine is. the OS detection and package installation component of that isn't
|
|
||||||
done yet though. 2014.10.31)
|
|
||||||
(NOTE2: Make sure all the packages you specify are valid package names. A mistyped package name will cause the chroot creation to
|
|
||||||
break and everything else will break as a result.)
|
|
||||||
|
|
||||||
curl
|
|
||||||
dosfstools
|
|
||||||
libisoburn ("libisofs" on CentOS)
|
|
||||||
lynx
|
|
||||||
rsync
|
|
||||||
sed
|
|
||||||
squashfs-tools
|
|
||||||
xorriso (in RPMForge repo for CentOS 7)
|
|
||||||
xz
|
|
||||||
|
|
||||||
and *probably* a few others. The scripts run with set -e for the most part, so if something's missed, you'll know.
|
|
||||||
Oh, you will know.
|
|
||||||
|
|
||||||
|
|
||||||
## Configuration ##
|
|
||||||
See extra/build.conf.sample. Copy to <PROJECT ROOT>/build.conf if you wish to modify any of the values, otherwise the defaults
|
|
||||||
will be used. I recommend enabling I_AM_A_RACECAR if you have the hardware for it, as it can speed things up greatly.
|
|
||||||
The file should be well-commented.
|
|
||||||
|
|
||||||
Also note the following files/paths:
|
|
||||||
|
|
||||||
-bin:
|
|
||||||
The building/cleaning scripts.
|
|
||||||
--/build.sh:
|
|
||||||
Supports several modes:
|
|
||||||
bin/build.sh update Updates existing chroots (does an apacman -Syyu --devel, copies over fresh files from
|
|
||||||
overlays, etc.)
|
|
||||||
bin/build.sh chroot Chroots you into the runtime for any interactive tasks you may wish to run.
|
|
||||||
bin/build.sh build (DEFAULT) Builds the chroots, ISO, etc.
|
|
||||||
bin/build.sh all Same as bin/build.sh build
|
|
||||||
bin/build.sh Same as bin/build.sh build
|
|
||||||
--/clean.sh:
|
|
||||||
Supports several modes:
|
|
||||||
bin/clean.sh all Clears everything out to a near-pristine working state. For convenience, it DOES NOT clear
|
|
||||||
out build.conf.
|
|
||||||
bin/clean.sh chroot Clears out only the working spaces, old ISOs, and the chroot directories. Hnady if you want to "start
|
|
||||||
fresh" but still want to keep logs from earlier runs.
|
|
||||||
bin/clean.sh squash Clears out only the working spaces and old ISOs. Useful if you're on a slow connection and would
|
|
||||||
rather update the chroots instead of downloading filesystem snapshots again.
|
|
||||||
bin/clean.sh Only clears workspaces and old ISOs.
|
|
||||||
--/mirror.lst.sh:
|
|
||||||
Builds a fresh mirror list. Note that it is US based.
|
|
||||||
|
|
||||||
-examples:
|
|
||||||
Included recommendation for how to lay things out, etc.
|
|
||||||
--/HTTP:
|
|
||||||
Recommended layout for webserver layout if using iPXE.
|
|
||||||
-extra:
|
|
||||||
Supporting files for the base building system (mirrorlist, etc.).
|
|
||||||
--/${UXNAME}.png:
|
|
||||||
A 640x480 8-bit RGBA colour PNG which will be used as the background for the bootsplash (if booting via BIOS and not UEFI)
|
|
||||||
--/bootstrap/apacman-*.tar.xz:
|
|
||||||
An AUR-enabled package manager. Necessary for AUR support.
|
|
||||||
--/build.conf.sample:
|
|
||||||
Sample/default config file. If you wish to override any settings, copy to <PROJECT ROOT>/build.conf and make your changes there.
|
|
||||||
First run of the script will do this for you automatically.
|
|
||||||
--/mirrorlist:
|
|
||||||
A set of default mirrorlists to be used for the chroots during building and runtime. Feel free to replace with your own
|
|
||||||
mirrorlist (current list is speed-optimized for east coast US).
|
|
||||||
--/packages.32:
|
|
||||||
A list of packages to install in the base system (32-bit runtime only).
|
|
||||||
--/packages.64:
|
|
||||||
A list of packages to install in the base system (64-bit runtime only).
|
|
||||||
--/packages.both:
|
|
||||||
A list of packages to install in the base system (these should be installed and are supported on both 64- AND 32-bit)
|
|
||||||
--/pre-build.d:
|
|
||||||
Contains files injected into the system. Both 64-bit and 32-bit environments. Note: be sure to place them in hierarchical order
|
|
||||||
(e.g. if you wish to have a file at /usr/foo/bar, you will need to place it in <PROJECT ROOT>/extra/pre-build.d/usr/foo/bar)
|
|
||||||
--/pre-build.d/32:
|
|
||||||
Same as above, but only for 32-bit environments.
|
|
||||||
--/pre-build.d/64:
|
|
||||||
You get the picture.
|
|
||||||
-http:
|
|
||||||
Files to be hosted for PXE booting the environment go here. Set this as your root/DocumentRoot in nginx/Apache (or, ideally,
|
|
||||||
copy over to a separate webserver). This directory is wiped out during any bin/clean.sh operation.
|
|
||||||
-lib:
|
|
||||||
The "guts" of BDisk.
|
|
||||||
-logs:
|
|
||||||
Here you can find full output of the runs. They are prefixed with run's PID number, and named after the function they occur in.
|
|
||||||
-overlay:
|
|
||||||
These files are applied AFTER the initial setup of the chroots. Same hierarchy rules as extra/pre-build.d.
|
|
||||||
-README:
|
|
||||||
This file.
|
|
||||||
-src:
|
|
||||||
Supporting source code/source code from other projects.
|
|
||||||
--ipxe/:
|
|
||||||
For iPXE support.
|
|
||||||
--ipxe_local/:
|
|
||||||
Various patches and supporting configs to tweak the iPXE build.
|
|
||||||
-tftpboot:
|
|
||||||
Files to be served via TFTP for PXE booting. This directory is wiped out during any bin/clean.sh operation.
|
|
||||||
-TODO:
|
|
||||||
This is just what I'm using to track stuff I want to add.
|
|
||||||
|
|
||||||
|
|
||||||
You may notice other files come and go; they're mostly there for extra goodies/used to determine other things.
|
|
||||||
|
|
||||||
## (Re)Building ##
|
|
||||||
Building must be done as root, and on an Arch x86_64 system (future versions will allow for non-Arch distros).
|
|
||||||
|
|
||||||
# bin/build.sh
|
|
||||||
|
|
||||||
Yeah. It's that easy. The finished product is in iso/.
|
|
||||||
|
|
||||||
|
|
||||||
If you want more verbosity, check out the logs/ directory.
|
|
||||||
@@ -1,68 +0,0 @@
|
|||||||
## General ##
|
|
||||||
|
|
||||||
-include benchmarking
|
|
||||||
-- http://sourceforge.net/projects/unixbench/
|
|
||||||
-- https://code.google.com/p/byte-unixbench/
|
|
||||||
-- https://github.com/akopytov/sysbench
|
|
||||||
-- (http://blog.due.io/2014/linode-digitalocean-and-vultr-comparison/ etc.)
|
|
||||||
-package in AUR
|
|
||||||
-base rewrite in python. pyalpm may come in handy here.
|
|
||||||
|
|
||||||
|
|
||||||
## NETWORKING ##
|
|
||||||
|
|
||||||
-shorewall/some other firewall?
|
|
||||||
-WISH: locked-down VPN?
|
|
||||||
-autodetection/configuration of network. DHCP is currently running by default, but does it need to support IPv6? if so, how would the user configure their network?
|
|
||||||
-SECURE SSH: https://stribika.github.io/2015/01/04/secure-secure-shell.html
|
|
||||||
-DISABLE NETWORKMANAGER AND "fi.w1.wpa_supplicant1"??? keeps spawning wpa_supplicant (and thusly killing networking proper)
|
|
||||||
-for netboot, custom user agent (should be defined by build.conf)
|
|
||||||
--iPXE's curl
|
|
||||||
--initrd's curl
|
|
||||||
|
|
||||||
|
|
||||||
## Building ##
|
|
||||||
|
|
||||||
-GUMMIBOOT IS GONE FROM THE REPOS. I could repackage it, but better to just see what the hell archiso's doing.
|
|
||||||
-WISH: Better logging[0]
|
|
||||||
-WISH: signing for secureboot releases (PreLoader and gummiboot handle this okay, but require manual intervention
|
|
||||||
-use manual chrooting functions ONLY if distro not detected as arch. if /usr/bin/systemd-nspawn exists, use that instead
|
|
||||||
--does arch-chroot work across all distros? see https://wiki.archlinux.org/index.php/Install_bundled_32-bit_system_in_Arch64 and https://wiki.archlinux.org/index.php/Chroot
|
|
||||||
--i think this might be unnecessary. testing across other major distros is necessary, but i think i can just use the chroot'd arch-chroot
|
|
||||||
-tweak build.conf (and build.conf.sample) to source the pwd and set as BASEDIR ***if*** the project resources are present in pwd, otherwise throw warning
|
|
||||||
--this is half-done;PWD is currently used by default.
|
|
||||||
-does gummiboot? loader? wtfever it's called support splash backgrounds? can i implement that differently somehow?
|
|
||||||
--yes, see e.g. https://www.reddit.com/r/archlinux/comments/3bwgf0/where_put_the_splasharchbmp_to_splash_screen_boot/
|
|
||||||
-strip out/remove unnecessary and orphan packages (e.g. gcc, make, automake, etc.)
|
|
||||||
-incorporate iPXE tweaks:
|
|
||||||
--http://ipxe.org/crypto
|
|
||||||
--http://ipxe.org/cmd/imgtrust
|
|
||||||
--http://ipxe.org/cmd/imgverify
|
|
||||||
--enable use of custom CA/self-signed certs for HTTPS etc. DONE, partially. need to incorporate codesign certs/keys. routines, conf variables
|
|
||||||
-enable mirror= kernel commandline.
|
|
||||||
--if mirror_(NAME) is present, use that as repo name.
|
|
||||||
--if it starts with /, treat as mirrorlist (Include); otherwise use Server =
|
|
||||||
--if it has mirror_SIG-X, set signature options e.g. _SIG-N would be "SigLevel = Never"
|
|
||||||
-iPXE background support. sed -rf "${BASEDIR}/src/ipxe_local/script.sed" ${SRCDIR}/ipxe/src/config/general.h ; sed -rf "${BASEDIR}/src/ipxe_local/script2.sed" ${SRCDIR}/ipxe/src/config/console.h
|
|
||||||
--note that iPXE VESAFB console is not (yet) supported in EFI, so this is on hold.
|
|
||||||
|
|
||||||
## Split into Separate Tools CD ##
|
|
||||||
|
|
||||||
-include WinMTR, build Mac OS X MTR for dist/tools on CD
|
|
||||||
-include pre-compiled LibreCrypt for opening LUKS parts on Windows (https://github.com/t-d-k/LibreCrypt)
|
|
||||||
--curl -s https://raw.githubusercontent.com/t-d-k/LibreCrypt/master/README.md | egrep 'InstallLibreCrypt_v[A-Za-z0-9\.]*.exe' | cut -f2 -d'"'
|
|
||||||
|
|
||||||
|
|
||||||
__________________________________________________________
|
|
||||||
FOOTNOTES:
|
|
||||||
|
|
||||||
|
|
||||||
[0] I'd really like to implement the following in build.conf; like:
|
|
||||||
http://forums.fedoraforum.org/showthread.php?t=275743
|
|
||||||
# The following is the setting for "verbosity". A more accurate way of saying it is how output should be handled.
|
|
||||||
# Note that for it to be properly parsed, it MUST be in the form of a linear array (e.g. VAR=(1 2 3) ).
|
|
||||||
# '| tee -a ${BASEDIR}/logs/${FUNCNAME}.$(date +%s)' means "display output for STDOUT and STDERR, and also log STDOUT to logs/<function name>.EPOCH_TIME"
|
|
||||||
# '2>&1 /dev/null' means "hide STDOUT and STDERR, no logging"
|
|
||||||
# '>> ${BASEDIR}/logs/${FUNCNAME}.$(date +%s) 2>&1' means "log both STDOUT and STDERR to logs/<function name>.EPOCH_TIME, no output"
|
|
||||||
# '>> ${BASEDIR}/logs/${FUNCNAME}.$(date +%s)' means "log STDOUT to logs/<function name>.EPOCH_TIME, display (but don't log) STDERR)"
|
|
||||||
# '' means "no logging; display both STDOUT and STDERR"
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
<?php
|
|
||||||
print '#!ipxe
|
|
||||||
|
|
||||||
cpuid --ext 29 && set bit_type 64 || set bit_type 32
|
|
||||||
initrd example.${bit_type}.img
|
|
||||||
kernel example.${bit_type}.kern initrd=example.${bit_type}.img ip=:::::eth0:dhcp archiso_http_srv=http://domain.tld/path/to/squashes/ archisobasedir=EXAMPLE archisolabel=EXAMPLE checksum=y
|
|
||||||
boot
|
|
||||||
'
|
|
||||||
?>
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
NOT A REAL INITRD IMAGE. REPLACE WITH ACTUAL INITRD.
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
NOT A REAL KERNEL FILE. REPLACE WITH ACTUAL KERNEL
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
NOT A REAL INITRD IMAGE. REPLACE WITH ACTUAL INITRD.
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
NOT A REAL KERNEL FILE. REPLACE WITH ACTUAL KERNEL
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
c18bde6e20c195bfb0a018b5c13dc420 airootfs.sfs
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
NOT A REAL SQUASHED FILESYSTEM FILE. REPLACE WITH ACTUAL SQUASHED FILESYSTEM
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
ada655a13f53702b3fe13cae001ab14f741e10c2bb83869048d4c18e74111c12 airootfs.sfs
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
c18bde6e20c195bfb0a018b5c13dc420 airootfs.sfs
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
NOT A REAL SQUASHED FILESYSTEM FILE. REPLACE WITH ACTUAL SQUASHED FILESYSTEM
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
ada655a13f53702b3fe13cae001ab14f741e10c2bb83869048d4c18e74111c12 airootfs.sfs
|
|
||||||
Binary file not shown.
+17
-80
@@ -30,7 +30,7 @@ BASEDIR="$(pwd)"
|
|||||||
ISODIR="${BASEDIR}/iso"
|
ISODIR="${BASEDIR}/iso"
|
||||||
|
|
||||||
# Where source code is kept.
|
# Where source code is kept.
|
||||||
SRCDIR="${BASEDIR}/extrasrc"
|
SRCDIR="${BASEDIR}/src"
|
||||||
|
|
||||||
# Where we mount for chroots etc.
|
# Where we mount for chroots etc.
|
||||||
MOUNTPT="/mnt/${UXNAME}"
|
MOUNTPT="/mnt/${UXNAME}"
|
||||||
@@ -57,50 +57,7 @@ TFTPGRP="root"
|
|||||||
# (and thus doesn't fit on a normal CD. Still fits on DVDs and USBs though!)
|
# (and thus doesn't fit on a normal CD. Still fits on DVDs and USBs though!)
|
||||||
MULTIARCH="yes"
|
MULTIARCH="yes"
|
||||||
|
|
||||||
# If you would like to build an iPXE-enabled *mini* ISO *in addition to* the ful ISO,
|
# set to "yes" to enable pushing new changes to a git repo/committing to a local repo
|
||||||
# set this to "yes". Otherwise, just build the full ISO.
|
|
||||||
BUILDMINI="no"
|
|
||||||
|
|
||||||
# What URI should iPXE's EMBED script use?
|
|
||||||
# Only used if BUILDMINI is set to yes.
|
|
||||||
# DO NOT USE A ',' (comma); instead, replace it with:
|
|
||||||
# %%COMMA%%
|
|
||||||
# If you require HTTP BASIC Authentication or HTTP Digest Authentication (untested), you can
|
|
||||||
# format it via the following:
|
|
||||||
# https://user:password@domain.tld/page.php
|
|
||||||
# This currently does not work for HTTPS with self-signed certificates.
|
|
||||||
IPXE_URI="https://bdisk.square-r00t.net"
|
|
||||||
|
|
||||||
# Path to the (root) CA certificate file (in PEM/X509 format) iPXE should use.
|
|
||||||
# If one is not specified, one will be generated.
|
|
||||||
# Only used if BUILDMINI is set to yes.
|
|
||||||
# Please properly escape any spaces or other funky characters.
|
|
||||||
# Note that you can use your own CA to sign existing certs. See http://ipxe.org/crypto for
|
|
||||||
# more info. This is handy if you run a third-party/"Trusted" root-CA-signed certificate
|
|
||||||
# for the HTTPS target.
|
|
||||||
# Requires IPXE_SSL_CAKEY if specified.
|
|
||||||
IPXE_SSL_CA=""
|
|
||||||
|
|
||||||
# Path to the (root) CA key file (in PEM/X509 format) iPXE should use.
|
|
||||||
# If one is not specified, one will be generated.
|
|
||||||
# Only used if BUILDMINI is set to yes.
|
|
||||||
# Please properly escape any spaces or other funky characters.
|
|
||||||
# Requires IPXE_SSL_CA if specified.
|
|
||||||
IPXE_SSL_CAKEY=""
|
|
||||||
|
|
||||||
# Path to the CLIENT certificate (in PEM/X509). If one is not specified, one will be generated.
|
|
||||||
# Only used if BUILDMINI is set to yes.
|
|
||||||
# Please properly escape any spaces or other funky characters.
|
|
||||||
# Requires IPXE_SSL_KEY if specified.
|
|
||||||
IPXE_SSL_CRT=""
|
|
||||||
|
|
||||||
# Path to the CLIENT key (in PEM/X509). If one is not specified, one will be generated.
|
|
||||||
# Only used if BUILDMINI is set to yes.
|
|
||||||
# Please properly escape any spaces or other funky characters.
|
|
||||||
# Requires IPXE_SSL_CRT if specified.
|
|
||||||
IPXE_SSL_KEY=""
|
|
||||||
|
|
||||||
# Set to "yes" to enable pushing new changes to a git repo/committing to a local repo
|
|
||||||
GIT="no"
|
GIT="no"
|
||||||
|
|
||||||
# If this is set, use rsync to copy the http and iso files. This is the rsync destination host.
|
# If this is set, use rsync to copy the http and iso files. This is the rsync destination host.
|
||||||
@@ -114,12 +71,10 @@ RSYNC_DEST="${BASEDIR}"
|
|||||||
# Note that the code appends, rather than replaces, logs- hence the timestamp in EPOCH time format.
|
# Note that the code appends, rather than replaces, logs- hence the timestamp in EPOCH time format.
|
||||||
LOGFILE="${BASEDIR}/logs/$(date +%s)"
|
LOGFILE="${BASEDIR}/logs/$(date +%s)"
|
||||||
|
|
||||||
# What should the regular username be? (Can be automatically logged in on boot; see below)
|
# What should the regular username be? (Automatically logged in on boot)
|
||||||
REGUSR="${UXNAME}"
|
REGUSR="${UXNAME}"
|
||||||
|
|
||||||
# Should the REGUSR have a password? IF THIS IS NOT SET, PASSWORD LOGIN WILL BE DISABLED!
|
# Should the REGUSR have a password? IF THIS IS NOT SET, THE PASSWORD WILL BE BLANK!
|
||||||
# If you wish to have a blank password, use the string '{[BLANK]}'.
|
|
||||||
# You MUST USE SINGLE-QUOTES, OR ESCAPE SHELL-EXPANDED CHARACTERS (e.g. $,*,etc.)
|
|
||||||
# Do NOT use a plaintext password here. You will need to generate a salted and hashed string
|
# Do NOT use a plaintext password here. You will need to generate a salted and hashed string
|
||||||
# in a shadow-compatible format.
|
# in a shadow-compatible format.
|
||||||
# Debian can do this with the mkpasswd utility (it's in Arch's AUR as debian-whois-mkpasswd):
|
# Debian can do this with the mkpasswd utility (it's in Arch's AUR as debian-whois-mkpasswd):
|
||||||
@@ -133,21 +88,11 @@ REGUSR="${UXNAME}"
|
|||||||
# /sbin/grub-crypt --sha-512
|
# /sbin/grub-crypt --sha-512
|
||||||
# The end-product should look something like this:
|
# The end-product should look something like this:
|
||||||
# $6$aBcDeFgHiJ$Yh342vFH7MOjPNu9InFymD1Dd42i5cFsr1cTWdpKGNIkbRGR/ZKQDRPJ1ZeeGb7y894Tfh3iWZIJKu3phlsqQ1
|
# $6$aBcDeFgHiJ$Yh342vFH7MOjPNu9InFymD1Dd42i5cFsr1cTWdpKGNIkbRGR/ZKQDRPJ1ZeeGb7y894Tfh3iWZIJKu3phlsqQ1
|
||||||
#
|
REGUSR_PASS=""
|
||||||
# Note that if you want an automatic login, this is *not* where it would be set.
|
|
||||||
# It should instead be controlled via overlay/etc/systemd/system/getty@ttyN.service.d/autologin.conf
|
|
||||||
# In the following format:
|
|
||||||
# [Service]
|
|
||||||
# Type=idle
|
|
||||||
# ExecStart=
|
|
||||||
# ExecStart=-/usr/bin/agetty --autologin <USERNAME> --noclear %I 38400 linux
|
|
||||||
# (where N is the TTY number). Alternatively, if booting to a GUI, it can be set as according
|
|
||||||
# to that GUI (e.g. for LXDE, overlay/etc/lxdm/lxdm.conf, "autologin=<USERNAME>")
|
|
||||||
REGUSR_PASS=''
|
|
||||||
|
|
||||||
# Same exact thing as REGUSR_PASS, but for the root password (i.e. if no password hash is
|
# Same exact thing as REGUSR_PASS, but for the root password (i.e. if no password hash is
|
||||||
# specified, password login will be disabled, etc.).
|
# specified, password login will be disabled).
|
||||||
ROOT_PASS=''
|
ROOT_PASS=""
|
||||||
|
|
||||||
# Do we have enough horsepower on the build system to jack up the resources we throw at building?
|
# Do we have enough horsepower on the build system to jack up the resources we throw at building?
|
||||||
# Enabling this will give absolute CPU preference to building the kernels and do make-time
|
# Enabling this will give absolute CPU preference to building the kernels and do make-time
|
||||||
@@ -158,33 +103,31 @@ I_AM_A_RACECAR="no"
|
|||||||
|
|
||||||
# ________________________________________________________________________________________________
|
# ________________________________________________________________________________________________
|
||||||
## RECOMMENDED DEFALTS ##
|
## RECOMMENDED DEFALTS ##
|
||||||
# The following should not be changed unless you are ABSOLUTELY, 100% SURE and COMPLETELY POSITIVE
|
# The following shoult not be changed unless you are ABSOLUTELY, 100% SURE and COMPLETELY POSITIVE
|
||||||
# about what you are doing!!!
|
# about what you are doing!!!
|
||||||
|
|
||||||
# This can be used to override automatic distro-detection.
|
# Legacy support.
|
||||||
# If you DO set this, be sure that you have a matching profile in
|
ROOTDIR="${BASEDIR}"
|
||||||
# ${BASEDIR}/lib/prereqs/<Distro>/meta !!
|
|
||||||
HOST_DIST=""
|
|
||||||
|
|
||||||
# This used to be defined statically, but is now dynamically appended. Please don't alter this
|
# This used to be defined statically (e.g. CHROOTDIR="${ROOTDIR}/chroot"),
|
||||||
# unless you renamed the chroot directory paths.
|
# but is now dynamically appended. Please don't alter this unless you renamed the chroot directory paths.
|
||||||
CHROOTDIR="${BASEDIR}/"
|
CHROOTDIR="${BASEDIR}/"
|
||||||
CHROOTDIR32="${CHROOTDIR}root.i686"
|
CHROOTDIR32="${CHROOTDIR}root.i686"
|
||||||
CHROOTDIR64="${CHROOTDIR}root.x86_64"
|
CHROOTDIR64="${CHROOTDIR}root.x86_64"
|
||||||
|
|
||||||
# This is a directory we use for staging. It definitely should not be checked into git.
|
# This is a directory we use for staging. It definitely should not be checked into git.
|
||||||
# It used to be defined statically (e.g. BUILDDIR="${BASEDIR}/build"),
|
# It used to be defined statically (e.g. BUILDDIR="${ROOTDIR}/build"),
|
||||||
# but is now dynamically appended. Please don't alter this unless you renamed the chroot directory paths.
|
# but is now dynamically appended. Please don't alter this unless you renamed the chroot directory paths.
|
||||||
BUILDDIR="${BASEDIR}/build"
|
BUILDDIR="${BASEDIR}/build"
|
||||||
|
|
||||||
# More staging.
|
# More staging.
|
||||||
TEMPDIR="${BASEDIR}/temp"
|
TEMPDIR="${ROOTDIR}/temp"
|
||||||
|
|
||||||
# This is where we stage the boot files.
|
# This is where we stage the boot files.
|
||||||
ARCHBOOT="${TEMPDIR}/${DISTNAME}"
|
ARCHBOOT="${TEMPDIR}/${DISTNAME}"
|
||||||
|
|
||||||
# Lockfile for checking for concurrent/failed builds
|
# Lockfile for checking for concurrent/failed builds
|
||||||
LOCKFILE="${BASEDIR}/lockfile.lck"
|
LOCKFILE="${ROOTDIR}/lockfile.lck"
|
||||||
|
|
||||||
|
|
||||||
## VARIABLE PROCESSING ##
|
## VARIABLE PROCESSING ##
|
||||||
@@ -196,6 +139,7 @@ if [ -z "${MULTIARCH}" ];
|
|||||||
then
|
then
|
||||||
MULTIARCH="y"
|
MULTIARCH="y"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
MULTIARCH=${MULTIARCH:0:1}
|
MULTIARCH=${MULTIARCH:0:1}
|
||||||
MULTIARCH=$(echo ${MULTIARCH} | tr [[:upper:]] [[:lower:]])
|
MULTIARCH=$(echo ${MULTIARCH} | tr [[:upper:]] [[:lower:]])
|
||||||
|
|
||||||
@@ -204,13 +148,6 @@ if [ -z "${I_AM_A_RACECAR}" ];
|
|||||||
then
|
then
|
||||||
I_AM_A_RACECAR="n"
|
I_AM_A_RACECAR="n"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
I_AM_A_RACECAR=${I_AM_A_RACECAR:0:1}
|
I_AM_A_RACECAR=${I_AM_A_RACECAR:0:1}
|
||||||
I_AM_A_RACECAR=$(echo ${I_AM_A_RACECAR} | tr [[:upper:]] [[:lower:]])
|
I_AM_A_RACECAR=$(echo ${I_AM_A_RACECAR} | tr [[:upper:]] [[:lower:]])
|
||||||
|
|
||||||
# BUILD MINI?
|
|
||||||
if [ -z "${BUILDMINI}" ];
|
|
||||||
then
|
|
||||||
BUILDMINI="n"
|
|
||||||
fi
|
|
||||||
BUILDMINI=${BUILDMINI:0:1}
|
|
||||||
BUILDMINI=$(echo ${BUILDMINI} | tr [[:upper:]] [[:lower:]])
|
|
||||||
|
|||||||
Vendored
-3
@@ -1,3 +0,0 @@
|
|||||||
taken with graces to http://www.contrib.andrew.cmu.edu/~somlo/OSXKVM/
|
|
||||||
|
|
||||||
Needs to be compiled on linux with gcc, and only runs on genuine Apple hardware (as it polls the SMC chip for the given value)
|
|
||||||
-193
@@ -1,193 +0,0 @@
|
|||||||
/*
|
|
||||||
* prints out 4-character name of the SMC key at given index position;
|
|
||||||
*
|
|
||||||
* by Gabriel L. Somlo <somlo@cmu.edu>, Summer 2014
|
|
||||||
*
|
|
||||||
* Compile with: gcc -O2 -o SmcDumpKey SmcDumpKey.c -Wall
|
|
||||||
*
|
|
||||||
* You probably want to "modprobe -r applesmc" before running this...
|
|
||||||
*
|
|
||||||
* Code bits and pieces shamelessly ripped from the linux kernel driver
|
|
||||||
* (drivers/hwmon/applesmc.c by N. Boichat and H. Rydberg)
|
|
||||||
*
|
|
||||||
* This program is free software; you can redistribute it and/or modify it
|
|
||||||
* under the terms of the GNU General Public License v2 as published by the
|
|
||||||
* Free Software Foundation.
|
|
||||||
*
|
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
|
||||||
* more details.
|
|
||||||
*
|
|
||||||
* You should have received a copy of the GNU General Public License along with
|
|
||||||
* this program; if not, write to the Free Software Foundation, Inc.,
|
|
||||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <stdint.h>
|
|
||||||
#include <limits.h>
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <string.h>
|
|
||||||
#include <ctype.h>
|
|
||||||
#include <sys/io.h>
|
|
||||||
#include <linux/byteorder/little_endian.h>
|
|
||||||
|
|
||||||
|
|
||||||
#define APPLESMC_START 0x300
|
|
||||||
#define APPLESMC_RANGE 0x20
|
|
||||||
|
|
||||||
#define APPLESMC_DATA_PORT (APPLESMC_START + 0x00)
|
|
||||||
#define APPLESMC_CMD_PORT (APPLESMC_START + 0x04)
|
|
||||||
|
|
||||||
#define APPLESMC_READ_CMD 0x10
|
|
||||||
#define APPLESMC_GET_KEY_BY_INDEX_CMD 0x12
|
|
||||||
#define APPLESMC_GET_KEY_TYPE_CMD 0x13
|
|
||||||
|
|
||||||
|
|
||||||
/* wait up to 128 ms for a status change. */
|
|
||||||
#define APPLESMC_MIN_WAIT 0x0010
|
|
||||||
#define APPLESMC_RETRY_WAIT 0x0100
|
|
||||||
#define APPLESMC_MAX_WAIT 0x20000
|
|
||||||
|
|
||||||
|
|
||||||
#define APPLESMC_KEY_NAME_LEN 4
|
|
||||||
#define APPLESMC_KEY_TYPE_LEN 4
|
|
||||||
|
|
||||||
typedef struct key_type {
|
|
||||||
uint8_t data_len;
|
|
||||||
uint8_t data_type[APPLESMC_KEY_TYPE_LEN];
|
|
||||||
uint8_t flags;
|
|
||||||
} __attribute__((packed)) key_type;
|
|
||||||
|
|
||||||
|
|
||||||
/* wait_read - Wait for a byte to appear on SMC port. */
|
|
||||||
static int
|
|
||||||
wait_read(void)
|
|
||||||
{
|
|
||||||
uint8_t status;
|
|
||||||
int us;
|
|
||||||
|
|
||||||
for (us = APPLESMC_MIN_WAIT; us < APPLESMC_MAX_WAIT; us <<= 1) {
|
|
||||||
usleep(us);
|
|
||||||
status = inb(APPLESMC_CMD_PORT);
|
|
||||||
/* read: wait for smc to settle */
|
|
||||||
if (status & 0x01)
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
fprintf(stderr, "wait_read() fail: 0x%02x\n", status);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*send_byte - Write to SMC port, retrying when necessary. */
|
|
||||||
static int
|
|
||||||
send_byte(uint8_t cmd, unsigned short port)
|
|
||||||
{
|
|
||||||
uint8_t status;
|
|
||||||
int us;
|
|
||||||
|
|
||||||
outb(cmd, port);
|
|
||||||
for (us = APPLESMC_MIN_WAIT; us < APPLESMC_MAX_WAIT; us <<= 1) {
|
|
||||||
usleep(us);
|
|
||||||
status = inb(APPLESMC_CMD_PORT);
|
|
||||||
/* write: wait for smc to settle */
|
|
||||||
if (status & 0x02)
|
|
||||||
continue;
|
|
||||||
/* ready: cmd accepted, return */
|
|
||||||
if (status & 0x04)
|
|
||||||
return 0;
|
|
||||||
/* timeout: give up */
|
|
||||||
if (us << 1 == APPLESMC_MAX_WAIT)
|
|
||||||
break;
|
|
||||||
/* busy: long wait and resend */
|
|
||||||
usleep(APPLESMC_RETRY_WAIT);
|
|
||||||
outb(cmd, port);
|
|
||||||
}
|
|
||||||
|
|
||||||
fprintf(stderr,
|
|
||||||
"send_byte(0x%02x, 0x%04x) fail: 0x%02x\n", cmd, port, status);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
send_argument(const uint8_t *key)
|
|
||||||
{
|
|
||||||
int i;
|
|
||||||
|
|
||||||
for (i = 0; i < APPLESMC_KEY_NAME_LEN; i++)
|
|
||||||
if (send_byte(key[i], APPLESMC_DATA_PORT))
|
|
||||||
return -1;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
|
||||||
read_smc(uint8_t cmd, const uint8_t *key, uint8_t *buf, uint8_t len)
|
|
||||||
{
|
|
||||||
int i;
|
|
||||||
|
|
||||||
if (send_byte(cmd, APPLESMC_CMD_PORT) || send_argument(key)) {
|
|
||||||
fprintf(stderr, "%.4s: read arg fail\n", key);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (send_byte(len, APPLESMC_DATA_PORT)) {
|
|
||||||
fprintf(stderr, "%.4s: read len fail\n", key);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (i = 0; i < len; i++) {
|
|
||||||
if (wait_read()) {
|
|
||||||
fprintf(stderr, "%.4s: read data[%d] fail\n", key, i);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
buf[i] = inb(APPLESMC_DATA_PORT);
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
int
|
|
||||||
main(int argc, char **argv)
|
|
||||||
{
|
|
||||||
key_type kt;
|
|
||||||
uint8_t data_buf[UCHAR_MAX];
|
|
||||||
uint8_t i;
|
|
||||||
|
|
||||||
if (argc != 2 || strlen(argv[1]) != APPLESMC_KEY_NAME_LEN) {
|
|
||||||
fprintf(stderr, "\nUsage: %s <4-char-key-name>\n\n", argv[0]);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (ioperm(APPLESMC_START, APPLESMC_RANGE, 1) != 0) {
|
|
||||||
perror("ioperm failed");
|
|
||||||
return -2;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (read_smc(APPLESMC_GET_KEY_TYPE_CMD,
|
|
||||||
(uint8_t *)argv[1], (uint8_t *)&kt, sizeof(kt)) != 0) {
|
|
||||||
fprintf(stderr, "\nread_smc get_key_type error\n\n");
|
|
||||||
return -3;
|
|
||||||
}
|
|
||||||
printf(" type=\"");
|
|
||||||
for (i = 0; i < APPLESMC_KEY_TYPE_LEN; i++)
|
|
||||||
printf(isprint(kt.data_type[i]) ? "%c" : "\\x%02x",
|
|
||||||
(uint8_t)kt.data_type[i]);
|
|
||||||
printf("\" length=%d flags=%x\n", kt.data_len, kt.flags);
|
|
||||||
|
|
||||||
if (read_smc(APPLESMC_READ_CMD,
|
|
||||||
(uint8_t *)argv[1], data_buf, kt.data_len) != 0) {
|
|
||||||
fprintf(stderr, "\nread_smc get_key_data error\n\n");
|
|
||||||
return -4;
|
|
||||||
}
|
|
||||||
printf(" data=\"");
|
|
||||||
for (i = 0; i < kt.data_len; i++)
|
|
||||||
printf(isprint(data_buf[i]) ? "%c" : "\\x%02x",
|
|
||||||
(uint8_t)data_buf[i]);
|
|
||||||
printf("\"\n");
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
+6
-6
@@ -1,7 +1,7 @@
|
|||||||
# Server list generated by rankmirrors on 2015-02-26
|
# Server list generated by rankmirrors on 2014-11-10
|
||||||
Server = http://mirrors.advancedhosters.com/archlinux/$repo/os/$arch
|
Server = http://mirror.rit.edu/archlinux/$repo/os/$arch
|
||||||
Server = http://mirror.umd.edu/archlinux/$repo/os/$arch
|
Server = http://mirror.cc.columbia.edu/pub/linux/archlinux/$repo/os/$arch
|
||||||
Server = http://mirror.vtti.vt.edu/archlinux/$repo/os/$arch
|
Server = http://mirrors.acm.wpi.edu/archlinux/$repo/os/$arch
|
||||||
Server = http://mirror.jmu.edu/pub/archlinux/$repo/os/$arch
|
Server = http://mirror.jmu.edu/pub/archlinux/$repo/os/$arch
|
||||||
Server = http://mirror.es.its.nyu.edu/archlinux/$repo/os/$arch
|
Server = http://mirror.cs.pitt.edu/archlinux/$repo/os/$arch
|
||||||
Server = http://mirrors.rutgers.edu/archlinux/$repo/os/$arch
|
Server = http://mirror.vtti.vt.edu/archlinux/$repo/os/$arch
|
||||||
|
|||||||
+49
-33
@@ -2,30 +2,27 @@
|
|||||||
# We need to install all X drivers.
|
# We need to install all X drivers.
|
||||||
abs
|
abs
|
||||||
acpi
|
acpi
|
||||||
#acpidump
|
acpidump
|
||||||
#afflib
|
afflib
|
||||||
aircrack-ng
|
aircrack-ng
|
||||||
apr
|
apr
|
||||||
apr-util
|
apr-util
|
||||||
|
arch-install-scripts
|
||||||
|
archiso
|
||||||
arj
|
arj
|
||||||
asciidoc
|
asciidoc
|
||||||
atop
|
atop
|
||||||
autopsy
|
autopsy
|
||||||
autossh
|
autossh
|
||||||
backuppc
|
|
||||||
#bacula ## TODO: grab all the bacula packages in here
|
|
||||||
beep
|
beep
|
||||||
bin86
|
bin86
|
||||||
bind-tools
|
|
||||||
binutils
|
binutils
|
||||||
bluez-utils
|
bluez-utils
|
||||||
bonnie++
|
bonnie++
|
||||||
boxbackup-client
|
|
||||||
boxbackup-server
|
|
||||||
bozocrack-git
|
bozocrack-git
|
||||||
bridge-utils
|
bridge-utils
|
||||||
burp-backup-git
|
|
||||||
btrfs-progs
|
btrfs-progs
|
||||||
|
bzip2
|
||||||
cabextract
|
cabextract
|
||||||
cdrtools
|
cdrtools
|
||||||
cdw
|
cdw
|
||||||
@@ -35,17 +32,17 @@ chntpw
|
|||||||
cifs-utils
|
cifs-utils
|
||||||
ckermit
|
ckermit
|
||||||
clamav
|
clamav
|
||||||
clonezilla
|
|
||||||
cmospwd
|
cmospwd
|
||||||
colordiff
|
colordiff
|
||||||
|
coreutils
|
||||||
cowpatty
|
cowpatty
|
||||||
cpio
|
cpio
|
||||||
cpuburn
|
cpuburn
|
||||||
cpupower
|
cpupower
|
||||||
crackpkcs12
|
crackpkcs12
|
||||||
|
cronie
|
||||||
#cryptcat
|
#cryptcat
|
||||||
cryptsetup
|
cryptsetup
|
||||||
csync2
|
|
||||||
customizepkg-scripting
|
customizepkg-scripting
|
||||||
dar
|
dar
|
||||||
dcfldd
|
dcfldd
|
||||||
@@ -54,14 +51,18 @@ dd_rescue
|
|||||||
dd_rhelp
|
dd_rhelp
|
||||||
debianutils
|
debianutils
|
||||||
debootstrap
|
debootstrap
|
||||||
|
dhclient
|
||||||
|
dhcp
|
||||||
|
dhcpcd
|
||||||
dialog
|
dialog
|
||||||
diffutils
|
diffutils
|
||||||
djohn
|
djohn
|
||||||
dmidecode
|
dmidecode
|
||||||
dnssec-anchors
|
dnssec-anchors
|
||||||
dnstracer
|
dnstracer
|
||||||
#dnsutils #replaced by bind-tools, https://www.archlinux.org/packages/extra/x86_64/bind-tools/
|
dnsutils
|
||||||
dos2unix
|
dos2unix
|
||||||
|
dosfstools
|
||||||
dropbear
|
dropbear
|
||||||
dstat
|
dstat
|
||||||
dump
|
dump
|
||||||
@@ -71,6 +72,8 @@ dvd+rw-tools
|
|||||||
e2fsprogs
|
e2fsprogs
|
||||||
ecryptfs-utils
|
ecryptfs-utils
|
||||||
ed
|
ed
|
||||||
|
efibootmgr
|
||||||
|
efivar
|
||||||
elfutils
|
elfutils
|
||||||
#elilo-efi
|
#elilo-efi
|
||||||
elinks
|
elinks
|
||||||
@@ -106,12 +109,12 @@ gpm
|
|||||||
gptfdisk
|
gptfdisk
|
||||||
gst-libav
|
gst-libav
|
||||||
gst-plugins-ugly
|
gst-plugins-ugly
|
||||||
|
gummiboot
|
||||||
hashcat
|
hashcat
|
||||||
hddtemp
|
hddtemp
|
||||||
hdparm
|
hdparm
|
||||||
hexcurse
|
hexcurse
|
||||||
hexedit
|
hexedit
|
||||||
hfsprogs
|
|
||||||
hfsutils
|
hfsutils
|
||||||
htop
|
htop
|
||||||
httping
|
httping
|
||||||
@@ -126,9 +129,10 @@ iotop
|
|||||||
iozone
|
iozone
|
||||||
ipcalc
|
ipcalc
|
||||||
iperf
|
iperf
|
||||||
iperf3
|
iproute2
|
||||||
ipsec-tools
|
ipsec-tools
|
||||||
iptraf-ng
|
iptraf-ng
|
||||||
|
iputils
|
||||||
irssi
|
irssi
|
||||||
iso-codes
|
iso-codes
|
||||||
isomaster
|
isomaster
|
||||||
@@ -138,8 +142,10 @@ jfsutils
|
|||||||
john
|
john
|
||||||
keyutils
|
keyutils
|
||||||
kismet-allplugins
|
kismet-allplugins
|
||||||
|
libisoburn
|
||||||
lftp
|
lftp
|
||||||
links
|
links
|
||||||
|
localepurge
|
||||||
#logkeys
|
#logkeys
|
||||||
logkeys-keymaps
|
logkeys-keymaps
|
||||||
lm_sensors
|
lm_sensors
|
||||||
@@ -150,7 +156,10 @@ lsof
|
|||||||
lsscsi
|
lsscsi
|
||||||
lxde
|
lxde
|
||||||
lynx
|
lynx
|
||||||
#lzip
|
lz4
|
||||||
|
lzip
|
||||||
|
lzo
|
||||||
|
lzop
|
||||||
macchanger
|
macchanger
|
||||||
magicrescue
|
magicrescue
|
||||||
mbr
|
mbr
|
||||||
@@ -159,13 +168,14 @@ mcelog
|
|||||||
md5deep
|
md5deep
|
||||||
mdadm
|
mdadm
|
||||||
mdcrack
|
mdcrack
|
||||||
# superseded by storcli
|
megaraid-cli
|
||||||
#megaraid-cli
|
|
||||||
memtester
|
memtester
|
||||||
mfoc
|
mfoc
|
||||||
minicom
|
minicom
|
||||||
mondo
|
mkinitcpio-nfs-utils
|
||||||
|
ms-sys
|
||||||
mtd-utils
|
mtd-utils
|
||||||
|
mtools
|
||||||
mtr
|
mtr
|
||||||
mtree
|
mtree
|
||||||
#mtx
|
#mtx
|
||||||
@@ -176,27 +186,27 @@ ncftp
|
|||||||
ncompress
|
ncompress
|
||||||
ncrack
|
ncrack
|
||||||
net-snmp
|
net-snmp
|
||||||
|
net-tools
|
||||||
|
netctl
|
||||||
netselect
|
netselect
|
||||||
nettle
|
nettle
|
||||||
networkmanager-pptp
|
networkmanager
|
||||||
nginx-devel
|
nginx-devel
|
||||||
ngrep
|
ngrep
|
||||||
nmap
|
nmap-nogui
|
||||||
nmon
|
nmon
|
||||||
ntfs-3g
|
ntfs-3g
|
||||||
ntfsfixboot
|
ntfsfixboot
|
||||||
#nwipe #broken since they moved to github(?)
|
nwipe
|
||||||
nwipe-git
|
|
||||||
obnam
|
|
||||||
open-iscsi
|
open-iscsi
|
||||||
openipmi
|
openipmi
|
||||||
|
openssh
|
||||||
|
openvpn
|
||||||
ophcrack
|
ophcrack
|
||||||
os-prober
|
os-prober
|
||||||
p7zip
|
p7zip
|
||||||
pack
|
pack
|
||||||
par2cmdline
|
par2cmdline
|
||||||
partclone
|
|
||||||
partclone-utils
|
|
||||||
parted
|
parted
|
||||||
partimage
|
partimage
|
||||||
pax-utils
|
pax-utils
|
||||||
@@ -219,16 +229,17 @@ procinfo-ng
|
|||||||
procps-ng
|
procps-ng
|
||||||
progsreiserfs
|
progsreiserfs
|
||||||
psmisc
|
psmisc
|
||||||
|
pv
|
||||||
pwgen
|
pwgen
|
||||||
pixz
|
pxz
|
||||||
pyrit-svn
|
pyrit
|
||||||
python2-gnuplot
|
python2-gnuplot
|
||||||
python2-pyx
|
python2-pyx
|
||||||
rarcrack
|
rarcrack
|
||||||
rcracki_mt
|
rcracki_mt
|
||||||
rdiff-backup
|
rdiff-backup
|
||||||
read-edid
|
read-edid
|
||||||
reaver-wps-fork-t6x-git
|
reaver
|
||||||
rename
|
rename
|
||||||
rfkill
|
rfkill
|
||||||
rp-pppoe
|
rp-pppoe
|
||||||
@@ -236,6 +247,7 @@ rpcbind
|
|||||||
rpmextract
|
rpmextract
|
||||||
rp-pppoe
|
rp-pppoe
|
||||||
rsnapshot
|
rsnapshot
|
||||||
|
rsync
|
||||||
rygel
|
rygel
|
||||||
safecopy
|
safecopy
|
||||||
samba
|
samba
|
||||||
@@ -245,21 +257,27 @@ scrounge-ntfs
|
|||||||
scrub
|
scrub
|
||||||
scsiadd
|
scsiadd
|
||||||
sdparm
|
sdparm
|
||||||
|
sed
|
||||||
setserial
|
setserial
|
||||||
sg3_utils
|
sg3_utils
|
||||||
sharutils
|
sharutils
|
||||||
|
shorewall
|
||||||
sipcalc
|
sipcalc
|
||||||
sipcrack
|
sipcrack
|
||||||
smartmontools
|
smartmontools
|
||||||
smbclient
|
smbclient
|
||||||
s-nail
|
s-nail
|
||||||
socat
|
socat
|
||||||
#star ## do people even USE tape packups anymore?
|
squashfs3-tools
|
||||||
storcli
|
squashfs-tools
|
||||||
|
#star
|
||||||
strace
|
strace
|
||||||
stress
|
stress
|
||||||
sucrack
|
sucrack
|
||||||
|
sudo
|
||||||
symlinks
|
symlinks
|
||||||
|
sysfsutils
|
||||||
|
syslinux
|
||||||
sysstat
|
sysstat
|
||||||
tcpdump
|
tcpdump
|
||||||
tcpslice
|
tcpslice
|
||||||
@@ -270,6 +288,7 @@ thin-provisioning-tools
|
|||||||
thttpd
|
thttpd
|
||||||
tmon
|
tmon
|
||||||
tmux
|
tmux
|
||||||
|
traceroute
|
||||||
tre
|
tre
|
||||||
truecrack-svn
|
truecrack-svn
|
||||||
truecrypt
|
truecrypt
|
||||||
@@ -277,7 +296,6 @@ tor
|
|||||||
udftools
|
udftools
|
||||||
#udpcast
|
#udpcast
|
||||||
unace
|
unace
|
||||||
unison
|
|
||||||
unrar
|
unrar
|
||||||
unshield
|
unshield
|
||||||
unzip
|
unzip
|
||||||
@@ -298,7 +316,7 @@ vpnc
|
|||||||
weplab
|
weplab
|
||||||
whdd
|
whdd
|
||||||
whois
|
whois
|
||||||
wifite-mod-pixiewps-git
|
wifite
|
||||||
wipe
|
wipe
|
||||||
wireshark-cli
|
wireshark-cli
|
||||||
wpscrack
|
wpscrack
|
||||||
@@ -310,8 +328,6 @@ xfsprogs
|
|||||||
xmlto
|
xmlto
|
||||||
xorg
|
xorg
|
||||||
xorg-drivers
|
xorg-drivers
|
||||||
xorg-xinit
|
|
||||||
xterm
|
|
||||||
zerofree
|
zerofree
|
||||||
zip
|
zip
|
||||||
zsh
|
zsh
|
||||||
|
|||||||
@@ -37,8 +37,7 @@ VerbosePkgLists
|
|||||||
|
|
||||||
# By default, pacman accepts packages signed by keys that its local keyring
|
# By default, pacman accepts packages signed by keys that its local keyring
|
||||||
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
||||||
#SigLevel = Required DatabaseOptional #RE-ENABLE ME WHEN A NEW SNAPSHOT IS RELEASED WITH FIXED GPG
|
SigLevel = Required DatabaseOptional
|
||||||
SigLevel = Never
|
|
||||||
LocalFileSigLevel = Optional
|
LocalFileSigLevel = Optional
|
||||||
#RemoteFileSigLevel = Required
|
#RemoteFileSigLevel = Required
|
||||||
|
|
||||||
@@ -90,6 +89,6 @@ Include = /etc/pacman.d/mirrorlist
|
|||||||
#SigLevel = Optional TrustAll
|
#SigLevel = Optional TrustAll
|
||||||
#Server = file:///home/custompkgs
|
#Server = file:///home/custompkgs
|
||||||
|
|
||||||
#[archlinuxfr]
|
[archlinuxfr]
|
||||||
#SigLevel = Never
|
SigLevel = Never
|
||||||
#Server = http://repo.archlinux.fr/$arch
|
Server = http://repo.archlinux.fr/$arch
|
||||||
|
|||||||
@@ -37,8 +37,7 @@ VerbosePkgLists
|
|||||||
|
|
||||||
# By default, pacman accepts packages signed by keys that its local keyring
|
# By default, pacman accepts packages signed by keys that its local keyring
|
||||||
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
# trusts (see pacman-key and its man page), as well as unsigned packages.
|
||||||
#SigLevel = Required DatabaseOptional #RE-ENABLE ME WHEN A NEW SNAPSHOT IS RELEASED WITH FIXED GPG
|
SigLevel = Required DatabaseOptional
|
||||||
SigLevel = Never
|
|
||||||
LocalFileSigLevel = Optional
|
LocalFileSigLevel = Optional
|
||||||
#RemoteFileSigLevel = Required
|
#RemoteFileSigLevel = Required
|
||||||
|
|
||||||
@@ -99,6 +98,6 @@ Include = /etc/pacman.d/mirrorlist
|
|||||||
#SigLevel = Optional TrustAll
|
#SigLevel = Optional TrustAll
|
||||||
#Server = file:///home/custompkgs
|
#Server = file:///home/custompkgs
|
||||||
|
|
||||||
#[archlinuxfr]
|
[archlinuxfr]
|
||||||
#SigLevel = Never
|
SigLevel = Never
|
||||||
#Server = http://repo.archlinux.fr/$arch
|
Server = http://repo.archlinux.fr/$arch
|
||||||
|
|||||||
@@ -1,57 +0,0 @@
|
|||||||
#
|
|
||||||
# /etc/apacman.conf
|
|
||||||
#
|
|
||||||
# See the apacman.conf(5) manpage for options
|
|
||||||
|
|
||||||
#
|
|
||||||
# GENERAL OPTIONS
|
|
||||||
#
|
|
||||||
|
|
||||||
#auronly=1
|
|
||||||
#buildonly=1
|
|
||||||
#cachevcs=1
|
|
||||||
#ignorearch=1
|
|
||||||
#needed=1
|
|
||||||
noconfirm=1
|
|
||||||
noedit=1
|
|
||||||
#noaur=1
|
|
||||||
#noconfirm=1
|
|
||||||
#noedit=1
|
|
||||||
#nofail=1
|
|
||||||
#preview=1
|
|
||||||
#purgebuild=1
|
|
||||||
#quiet=1
|
|
||||||
#skipcache=1
|
|
||||||
skipinteg=1
|
|
||||||
#skiptest=1
|
|
||||||
#warn=1
|
|
||||||
#tmpdir=/var/tmp/apacman
|
|
||||||
#TMPDIR=/var/tmp/apacman
|
|
||||||
|
|
||||||
#
|
|
||||||
# CONFIGURATION
|
|
||||||
#
|
|
||||||
|
|
||||||
#tmpdir="/tmp/apacmantmp-$UID"
|
|
||||||
#makepkgconf="/etc/makepkg.conf"
|
|
||||||
#usermakepkgconf="$HOME/.makepkg.conf"
|
|
||||||
#pacmanconf="/etc/pacman.conf"
|
|
||||||
#downdir="/var/cache/pacman/pkg"
|
|
||||||
#savedir="/var/cache/apacman/pkg"
|
|
||||||
#editor="nano -w"
|
|
||||||
editor="vim"
|
|
||||||
#RPCURL="https://aur.archlinux.org/rpc.php?type"
|
|
||||||
#PKGURL="https://aur.archlinux.org"
|
|
||||||
#ABSURL="rsync.archlinux.org"
|
|
||||||
|
|
||||||
#
|
|
||||||
# COLORIZATION
|
|
||||||
#
|
|
||||||
|
|
||||||
COLOR1='\e[1;39m'
|
|
||||||
COLOR2='\e[1;32m'
|
|
||||||
COLOR3='\e[1;35m'
|
|
||||||
COLOR4='\e[1;36m'
|
|
||||||
COLOR5='\e[1;34m'
|
|
||||||
COLOR6='\e[1;33m'
|
|
||||||
COLOR7='\e[1;31m'
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
sed -i -e 's/build(/package(/g' ${1}
|
|
||||||
Executable
+89
@@ -0,0 +1,89 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# change some versions around
|
||||||
|
sed -i -e 's/^\(pkgbase=linux[[:space:]]*\)/#\1/g' ${1}
|
||||||
|
sed -i -e 's/^#\(pkgbase=linux-\)custom.*$/\1BDisk/g' ${1}
|
||||||
|
sed -i -e '/^_kernelname/a KERNVER=$(echo ${pkgver} | sed -e "s/\\\([0-9]\\\.[0-9]*\\\).*$/\\\1/")' ${1}
|
||||||
|
sed -i -e "s/^\(makedepends=.*\))$/\1 'rsync' 'git')/g" ${1}
|
||||||
|
##cp linux.preset linux-BDisk.preset
|
||||||
|
##sed -i -e 's#^[[:space:]]*install\ -D\ -m644\ "${srcdir}/linux.preset".*$#install -D -m644 "${srcdir}/linux-BDisk.preset" "${pkgdir}/etc/mkinitcpio.d/${pkgbase}.preset"#g' ${1}
|
||||||
|
##sed -i -e "s/\ 'fallback'//g" \
|
||||||
|
##-e '/^fallback/d' \
|
||||||
|
##-e '/^$/d' \
|
||||||
|
##-e '/^[[:space:]]*$/d' \
|
||||||
|
##-e 's#^\(default_image="/boot/initramfs-linux\).*#\1-BDisk"/g' linux-BDisk.preset
|
||||||
|
##-e 's/^\(ALL_kver="/boot/vmlinuz-linux\)\(.*\)/\1-BDisk\2/g' linux-BDisk.preset
|
||||||
|
|
||||||
|
# add source for aufs3
|
||||||
|
## 12.07.2014 - remove the "git checkout <SPECIFIC COMMIT HASH>" once a bug is fixed. currently fails with:
|
||||||
|
## LD fs/aufs/built-in.o
|
||||||
|
## CC [M] fs/aufs/module.o
|
||||||
|
##In file included from fs/aufs/module.c:24:0:
|
||||||
|
##fs/aufs/inode.h:307:12: error: function declaration isn't a prototype
|
||||||
|
##[-Werror=strict-prototypes]
|
||||||
|
## AuStubInt0(au_cpup_xattr, h_dst, h_src, ignore_flags)
|
||||||
|
## ^
|
||||||
|
##fs/aufs/aufs.h:28:21: note: in definition of macro 'AuStub'
|
||||||
|
## static inline type name(__VA_ARGS__) { body; }
|
||||||
|
## ^
|
||||||
|
##fs/aufs/inode.h:307:1: note: in expansion of macro 'AuStubInt0'
|
||||||
|
## AuStubInt0(au_cpup_xattr, h_dst, h_src, ignore_flags)
|
||||||
|
## ^
|
||||||
|
##cc1: some warnings being treated as errors
|
||||||
|
##scripts/Makefile.build:257: recipe for target 'fs/aufs/module.o' failed
|
||||||
|
##make[2]: *** [fs/aufs/module.o] Error 1
|
||||||
|
##scripts/Makefile.build:404: recipe for target 'fs/aufs' failed
|
||||||
|
##make[1]: *** [fs/aufs] Error 2
|
||||||
|
##Makefile:929: recipe for target 'fs' failed
|
||||||
|
##make: *** [fs] Error 2
|
||||||
|
sed -i -e '/^prepare()\ {/a\
|
||||||
|
\ git clone git:\/\/aufs.git.sourceforge.net\/gitroot\/aufs\/aufs3-standalone.git aufs3 > \/dev\/null 2>&1\
|
||||||
|
\ cd aufs3\
|
||||||
|
\ git checkout aufs${KERNVER} > \/dev\/null 2>&1\
|
||||||
|
\ git checkout c75f6dddc1c58950c76cc1581e4b4c7ac8365bff > \/dev\/null 2>&1\
|
||||||
|
\ cd ..\/' ${1}
|
||||||
|
#sed -i -e 's/^\(_kernelname=\).*$/\1"-BDisk"/' ${1}
|
||||||
|
sed -i -e '/^[[:space:]]*patch.*pkgver}"$/i rsync -a ../aufs3/Documentation/. Documentation/. ; rsync -a ../aufs3/fs/. fs/. ; cp -a ../aufs3/include/uapi/linux/aufs_type.h include/uapi/linux/. \
|
||||||
|
\ for i in $(ls -1 ../aufs3/*.patch) ; do patch -p1 -i ../aufs3/${i} ; done' ${1}
|
||||||
|
# and we need to be sure to build aufs3-util
|
||||||
|
#sed -i -e '/^[[:space:]]*install\ -D\ -m644\ vmlinux.*$/a\
|
||||||
|
#\ git clone git:\/\/git.code.sf.net\/p\/aufs\/aufs-util > \/dev\/null 2>&1\
|
||||||
|
#\ cd aufs-util\
|
||||||
|
#\ UTILVER=$(git branch -a | grep -v master | sort -nr | grep -v rcN | head -n1 | cut -f3 -d"\/")\
|
||||||
|
#\ git checkout ${UTILVER} > \/dev\/null 2>&1\
|
||||||
|
#\ make' ${1}
|
||||||
|
|
||||||
|
# and configure the kernel. this gets messy.
|
||||||
|
#-e "s/^#[[:space:]]\\\(CONFIG_AUFS_FS\\\).*$/\\\1=m/g" \\\
|
||||||
|
sed -i -e '/^[[:space:]]*make\ prepare.*$/i yes "" | make olddefconfig >/dev/null' ${1}
|
||||||
|
sed -i -e '/^[[:space:]]*make\ prepare.*$/a sed -i \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_FS\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_BRANCH_MAX_127\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_SBILIST\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_HNOTIFY\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_HFSNOTIFY\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_EXPORT\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_INO_T_64\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_FHSM\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_RDU\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_BDEV_LOOP\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(AUFS_BRANCH_MAX_511\\\).*$/\\\1=n/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(AUFS_BRANCH_MAX_1023\\\).*$/\\\1=n/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(AUFS_BRANCH_MAX_32767\\\).*$/\\\1=n/g" ${srcdir}/../config{,.x86_64}' ${1}
|
||||||
|
# yes, we have to do this twice. with a hammer.
|
||||||
|
sed -i -e '/^[[:space:]]*make\ prepare.*$/a sed -i \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_FS\\\).*$/\\\1=m/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_BRANCH_MAX_127\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_SBILIST\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_HNOTIFY\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_HFSNOTIFY\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_EXPORT\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_INO_T_64\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_FHSM\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_RDU\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(CONFIG_AUFS_BDEV_LOOP\\\).*$/\\\1=y/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(AUFS_BRANCH_MAX_511\\\).*$/\\\1=n/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(AUFS_BRANCH_MAX_1023\\\).*$/\\\1=n/g" \\\
|
||||||
|
-e "s/^#[[:space:]]\\\(AUFS_BRANCH_MAX_32767\\\).*$/\\\1=n/g" .config' ${1}
|
||||||
|
sed -i -e 's/^\([[:space:]]*yes\ ""\ |\ \)make\ config/\1make olddefconfig/' ${1}
|
||||||
|
# and we have to edit the linux.install as well.
|
||||||
|
sed -i -e 's/^\(KERNEL_NAME=\).*$/\1-BDisk/g' linux.install*
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
sed -re 's@^(source=\(").*$@\1https://github.com/kwilczynski/lsi/blob/master/lsiutil/LSIUtil_1.62.zip?raw=true")@g' ${1}
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
if [[ ! -f "/usr/lib/libdialog.so" ]];
|
|
||||||
then
|
|
||||||
echo "Please run the following: sudo ln -s /usr/lib/libdialog.so.1.2 /usr/lib/libdialog.so"
|
|
||||||
echo "This package will fail to build otherwise."
|
|
||||||
fi
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
sed -i -re "s/'any'/'i686' 'x86_64'/g" ${1}
|
|
||||||
@@ -1,90 +0,0 @@
|
|||||||
[H[J
|
|
||||||
MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMW0dc,.. ..;cxKWMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMMMMMMMMMMMW0d:'. .,cx0WMMMMMMMMMMMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMMMMMMMNx:. .';cldxkkOOOOkkxdl:,.. .ckNMMMMMMMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMMMMKl. .;okKXXXXXXXXXXXXXXXXXXXXXX0xl;. 'oXMMMMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMXl. .:d0XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX0d;. .dNMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMM0; .cOXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXKk: :KMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMO' 'xKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXKd. ,KMMMMMMMMMM
|
|
||||||
MMMMMMMMX, ,OXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXx' :NMMMMMMMM
|
|
||||||
MMMMMMMd .kXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXd. .kMMMMMMM
|
|
||||||
MMMMMN' oKKxl:;,;:lkKXXXXXXXXXXXXXXXXXXXXXXXX0dl:;,;:ld0XXXXXXXXXXKc ;WMMMMM
|
|
||||||
MMMMK. .O0; ':ool:. ;kXXXXXXXXXXXXXXXXXXX0l. .,coooc' .c0XXXXXXXXXk. .NMMMM
|
|
||||||
MMMK. 'Kx cNMMMMK. ,0XXXXXXXXXXXXXXXKc :0MMMMMMk. cKXXXXXXXX0. .NMMM
|
|
||||||
MMN. 'Kd kMMMMMM' .OXXXXXXXXXXXXX0. 'XMMMMMMMN 'KXXXXXXXX0. .WMM
|
|
||||||
MW. .K0 xMMMMMMMd .KXXXXXXXXXXXK' ;WMMMMMMMMM: 'KXXXXXXXX0. ;MM
|
|
||||||
Mo OXc .MMMMMMMMMXo:;ckN. dXXXXXXXXXXXd NMMMMMMMMMMM0l::l0N dXXXXXXXXXx xM
|
|
||||||
N :XX, :MMMMMMMMMMMMMMMM; :XXXXXXXXXXX; ,MMMMMMMMMMMMMMMMMMM' :XXXXXXXXXX, .M
|
|
||||||
d OXX; ,MMMMMMMMMMMMMMMM, :XXXXXXXXXXX: ,MMMMMMMMMMMMMMMMMMM' :XXXXXXXXXXx O
|
|
||||||
, .XXXx dxxxxxxxxxxxxxxd xXXXXXXXXXXXx dxxxxxxxxxxxxxxxxxd xXXXXXXXXXXK. c
|
|
||||||
. :XXXXc'''''''''''''''''':XXXXXXXXXXXXXc'''''''''''''''''''''cXXXXXXXXXXXX, '
|
|
||||||
lXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX: .
|
|
||||||
lXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX; .
|
|
||||||
. :XXXXXK0000000000000000000000000000000000000000000000000000KXXXXXXXXXXXXX, '
|
|
||||||
, .XXXXXk .KXXXXXXXXXXXK. c
|
|
||||||
x OXXXXXKKo .............................................. lXXXXXXXXXXXx 0
|
|
||||||
W. ;XXXXXXXO ............................................... .XXXXXXXXXXX' .M
|
|
||||||
Md kXXXXXXX, .............................................. KXXXXXXXXXd OM
|
|
||||||
MM, .0XXXXXX0. .............................................. KXXXXXXXXO cMM
|
|
||||||
MMN. .KXXXXXXk ............................................ ;XXXXXXXX0. ,WMM
|
|
||||||
MMMX. .0XXXXXXk .........................'''............... .0XXXXXXXO. 'WMMM
|
|
||||||
MMMMX. .kXXXXXXO. .................,cdkO0KKK0Oxo:'........ .kXXXXXXXd ,WMMMM
|
|
||||||
MMMMMW; cKXXXXXK; .............'ckKKKKKKKKKKKKKK0x;.... '0XXXXXX0; cWMMMMM
|
|
||||||
MMMMMMMk. .dXXXXXXx. ..........:OKKKKKKKKKKKKKKKKKKKo. .oXXXXXXKl .0MMMMMMM
|
|
||||||
MMMMMMMMNc .xXXXXXKo. .......lKKKKKKKKKKKKKKKKKK0o' .dKXXXXXKd. lWMMMMMMMM
|
|
||||||
MMMMMMMMMMK; .oKXXXXKd' ...:KKKKKKKKKKKKKKK0xc' .:kXXXXXX0l. cXMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMXc ;xKXXXX0o,. .;ldxkkOkkxol:'. .,lOXXXXXXKd, .lNMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMWx, ,lOXXXXX0xl:,.........';cok0XXXXXXKkl' ;kWMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMMMMNx, .'cdOKXXXXXXXXXXXXXXXXXXXXKOd:' ;kWMMMMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMMMMMMMW0o, .';:loddxxxxddol:,.. .,o0MMMMMMMMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMMMMMMMMMMMMXko:'. .':oONMMMMMMMMMMMMMMMMMMMMMMMMM
|
|
||||||
MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMW0dc;'......,:lx0WMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM
|
|
||||||
':ox0KXXK0koc'.
|
|
||||||
.;ok000kxollcccclodxOKXKko;.
|
|
||||||
;d00dc'. .;lkXKd;.
|
|
||||||
.o0Oc. .,codkO0KKKKK0Okxdl;'. .;dXKo'
|
|
||||||
.oKx, .:d0XXXXXXXXXXXXXXXXXXXXXXXKkl,. .c0Nd.
|
|
||||||
,0O; .:xKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXOl' .oN0;
|
|
||||||
;Kx. ;xKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX0l. :KX:
|
|
||||||
,Kx. .lKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXk, ;XX,
|
|
||||||
k0. .oKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXO, oWO.
|
|
||||||
,No :KXX0Okk0XXXXXXXXXXXXXXXXXXXXXXXXXXXK0Okk0KXXXXXXXXXXXk. .KW;
|
|
||||||
cN, .kKl' ... 'l0XXXXXXXXXXXXXXXXXXXXk:. ... .;dKXXXXXXXXK: kMo
|
|
||||||
oN. '0d. c0WMMWo ;0XXXXXXXXXXXXXXXKo. 'dKWMMMX, .cKXXXXXXXXo xMd
|
|
||||||
lW. 'Kl .KMMMMM: xXXXXXXXXXXXXX0' ,KMMMMMMM. .OXXXXXXXXx xMd
|
|
||||||
;M; .Kd .NMMMMMMl kXXXXXXXXXXXK. lMMMMMMMMM. .OXXXXXXXXd 0M:
|
|
||||||
Nx 0X. dMMMMMMMMk;..;dl 'XXXXXXXXXXXc 'MMMMMMMMMMWd,..:Oc ,XXXXXXXXX: .WW.
|
|
||||||
dW. lXK KMMMMMMMMMMMMMMK KXXXXXXXXXX. dMMMMMMMMMMMMMMMMM0 KXXXXXXXXK. dMk
|
|
||||||
Wx KXK 0MMMMMMMMMMMMMMK KXXXXXXXXXX. xMMMMMMMMMMMMMMMMM0 KXXXXXXXXXc .MM.
|
|
||||||
:M; ;XXX; ,xxxxxxxxxxxxxx: 'XXXXXXXXXXXc 'xxxxxxxxxxxxxxxxx; ,XXXXXXXXXXO KMl
|
|
||||||
xM. oXXX0,,,,,,,,,,,,,,,,,,kXXXXXXXXXXXK;,,,,,,,,,,,,,,,,,,,,OXXXXXXXXXXX. xMO
|
|
||||||
0M xXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. oMK
|
|
||||||
0M dXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. oMK
|
|
||||||
xM. lXXXXXkdddddddddddddddddddddddddddddddddddddddddddddddddKXXXXXXXXXXXK kMk
|
|
||||||
:Mc 'XXXXXc'. :XXXXXXXXXXXx XMc
|
|
||||||
W0 OXXXXXX0 ............................................ OXXXXXXXXXX; ,MM.
|
|
||||||
oM' ,XXXXXXX, ............................................ oXXXXXXXXXO 0Mx
|
|
||||||
NK dXXXXXXO ........................................... lXXXXXXXXK. ;MN.
|
|
||||||
,Md kXXXXXXd .......................................... xXXXXXXXX; .NM;
|
|
||||||
cMl kXXXXXXo ......................................... .KXXXXXXK; .XMl
|
|
||||||
lMl dXXXXXXd ..................':lodxxdol:'......... .0XXXXXXK' .XMo
|
|
||||||
:Wx :KXXXXXk. ..............,lkKKKKKKKKKKKKkc'.... .0XXXXXXk. 'NMc
|
|
||||||
.XK. .xXXXXXK: ..........'oKKKKKKKKKKKKKKKKK0l.. lKXXXXX0; oMN'
|
|
||||||
dWo .xXXXXXO; .......,OKKKKKKKKKKKKKKKKKkc. .c0XXXXX0c 'KMx
|
|
||||||
.0Nc .oKXXXXO:. ...'0KKKKKKKKKKKKKK0d:. ,xKXXXXXO: .OM0'
|
|
||||||
,0No. ;xKXXXKx:. .;ldxkOOkkxol;'. 'cxKXXXXX0l. ,OMK;
|
|
||||||
'kWk, ,o0XXXXKko:,.........,:ldOKXXXXXKkc. .lXMO,
|
|
||||||
.cKNx; .,cxOKXXXXXXXXXXXXXXXXXXKko:. .lKMKl.
|
|
||||||
.cOWKd;. ..,;cllooollc:;'. 'ckNM0c.
|
|
||||||
'lONW0xl;.. .,:okXMNOo,
|
|
||||||
.,cdOXWMWNXKK00KKXNMMWXOdc,.
|
|
||||||
.,cokO00Okdc,.
|
|
||||||
|
|
||||||
|
|
||||||
[H[J
|
|
||||||
|
|
||||||
bdisk
|
|
||||||
\d \t
|
|
||||||
\4
|
|
||||||
\4{tun0}
|
|
||||||
http://bdisk.square-r00t.net/
|
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
# run. Advanced users may wish to specify all system modules
|
# run. Advanced users may wish to specify all system modules
|
||||||
# in this array. For instance:
|
# in this array. For instance:
|
||||||
# MODULES="piix ide_disk reiserfs"
|
# MODULES="piix ide_disk reiserfs"
|
||||||
MODULES="overlay ata_generic ata_piix loop nls_cp437 ext4 raid456 vfat netconsole"
|
MODULES="aufs ata_generic ata_piix loop nls_cp437 ext4 raid456 vfat netconsole"
|
||||||
|
|
||||||
# BINARIES
|
# BINARIES
|
||||||
# This setting includes any additional binaries a given user may
|
# This setting includes any additional binaries a given user may
|
||||||
@@ -50,7 +50,7 @@ FILES=""
|
|||||||
# usr, fsck and shutdown hooks.
|
# usr, fsck and shutdown hooks.
|
||||||
#HOOKS="base udev autodetect modconf block filesystems keyboard fsck"
|
#HOOKS="base udev autodetect modconf block filesystems keyboard fsck"
|
||||||
#HOOKS="base udev memdisk archiso_shutdown archiso modconf net ssh archiso_loop_mnt archiso_pxe_common archiso_pxe_nbd archiso_pxe_http archiso_pxe_nfs archiso_kms block pcmcia filesystems keyboard livecd"
|
#HOOKS="base udev memdisk archiso_shutdown archiso modconf net ssh archiso_loop_mnt archiso_pxe_common archiso_pxe_nbd archiso_pxe_http archiso_pxe_nfs archiso_kms block pcmcia filesystems keyboard livecd"
|
||||||
HOOKS="base udev memdisk archiso_shutdown archiso-custom modconf net ssh archiso_loop_mnt archiso_pxe_common archiso_pxe_nbd archiso_http_custom archiso_pxe_nfs archiso_kms block pcmcia filesystems keyboard livecd"
|
HOOKS="base udev memdisk archiso_shutdown archiso-custom modconf net ssh archiso_loop_mnt archiso_pxe_common archiso_pxe_nbd archiso_pxe_http archiso_pxe_nfs archiso_kms block pcmcia filesystems keyboard livecd"
|
||||||
|
|
||||||
# COMPRESSION
|
# COMPRESSION
|
||||||
# Use this to compress the initramfs image. By default, gzip compression
|
# Use this to compress the initramfs image. By default, gzip compression
|
||||||
|
|||||||
@@ -1,15 +0,0 @@
|
|||||||
# mkinitcpio preset file for the 'linux' package
|
|
||||||
|
|
||||||
ALL_config="/etc/mkinitcpio.conf"
|
|
||||||
ALL_kver="/boot/vmlinuz-linux"
|
|
||||||
|
|
||||||
#PRESETS=('default' 'fallback')
|
|
||||||
PRESETS=('default')
|
|
||||||
|
|
||||||
#default_config="/etc/mkinitcpio.conf"
|
|
||||||
default_image="/boot/initramfs-linux.img"
|
|
||||||
#default_options=""
|
|
||||||
|
|
||||||
#fallback_config="/etc/mkinitcpio.conf"
|
|
||||||
#fallback_image="/boot/initramfs-linux-fallback.img"
|
|
||||||
#fallback_options="-S autodetect"
|
|
||||||
@@ -1,40 +0,0 @@
|
|||||||
':ox0KXXK0koc'.
|
|
||||||
.;ok000kxollcccclodxOKXKko;.
|
|
||||||
;d00dc'. .;lkXKd;.
|
|
||||||
.o0Oc. .,codkO0KKKKK0Okxdl;'. .;dXKo'
|
|
||||||
.oKx, .:d0XXXXXXXXXXXXXXXXXXXXXXXKkl,. .c0Nd.
|
|
||||||
,0O; .:xKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXOl' .oN0;
|
|
||||||
;Kx. ;xKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX0l. :KX:
|
|
||||||
,Kx. .lKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXk, ;XX,
|
|
||||||
k0. .oKXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXO, oWO.
|
|
||||||
,No :KXX0Okk0XXXXXXXXXXXXXXXXXXXXXXXXXXXK0Okk0KXXXXXXXXXXXk. .KW;
|
|
||||||
cN, .kKl' ... 'l0XXXXXXXXXXXXXXXXXXXXk:. ... .;dKXXXXXXXXK: kMo
|
|
||||||
oN. '0d. c0WMMWo ;0XXXXXXXXXXXXXXXKo. 'dKWMMMX, .cKXXXXXXXXo xMd
|
|
||||||
lW. 'Kl .KMMMMM: xXXXXXXXXXXXXX0' ,KMMMMMMM. .OXXXXXXXXx xMd
|
|
||||||
;M; .Kd .NMMMMMMl kXXXXXXXXXXXK. lMMMMMMMMM. .OXXXXXXXXd 0M:
|
|
||||||
Nx 0X. dMMMMMMMMk;..;dl 'XXXXXXXXXXXc 'MMMMMMMMMMWd,..:Oc ,XXXXXXXXX: .WW.
|
|
||||||
dW. lXK KMMMMMMMMMMMMMMK KXXXXXXXXXX. dMMMMMMMMMMMMMMMMM0 KXXXXXXXXK. dMk
|
|
||||||
Wx KXK 0MMMMMMMMMMMMMMK KXXXXXXXXXX. xMMMMMMMMMMMMMMMMM0 KXXXXXXXXXc .MM.
|
|
||||||
:M; ;XXX; ,xxxxxxxxxxxxxx: 'XXXXXXXXXXXc 'xxxxxxxxxxxxxxxxx; ,XXXXXXXXXXO KMl
|
|
||||||
xM. oXXX0,,,,,,,,,,,,,,,,,,kXXXXXXXXXXXK;,,,,,,,,,,,,,,,,,,,,OXXXXXXXXXXX. xMO
|
|
||||||
0M xXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. oMK
|
|
||||||
0M dXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX. oMK
|
|
||||||
xM. lXXXXXkdddddddddddddddddddddddddddddddddddddddddddddddddKXXXXXXXXXXXK kMk
|
|
||||||
:Mc 'XXXXXc'. :XXXXXXXXXXXx XMc
|
|
||||||
W0 OXXXXXX0 ............................................ OXXXXXXXXXX; ,MM.
|
|
||||||
oM' ,XXXXXXX, ............................................ oXXXXXXXXXO 0Mx
|
|
||||||
NK dXXXXXXO ........................................... lXXXXXXXXK. ;MN.
|
|
||||||
,Md kXXXXXXd .......................................... xXXXXXXXX; .NM;
|
|
||||||
cMl kXXXXXXo ......................................... .KXXXXXXK; .XMl
|
|
||||||
lMl dXXXXXXd ..................':lodxxdol:'......... .0XXXXXXK' .XMo
|
|
||||||
:Wx :KXXXXXk. ..............,lkKKKKKKKKKKKKkc'.... .0XXXXXXk. 'NMc
|
|
||||||
.XK. .xXXXXXK: ..........'oKKKKKKKKKKKKKKKKK0l.. lKXXXXX0; oMN'
|
|
||||||
dWo .xXXXXXO; .......,OKKKKKKKKKKKKKKKKKkc. .c0XXXXX0c 'KMx
|
|
||||||
.0Nc .oKXXXXO:. ...'0KKKKKKKKKKKKKK0d:. ,xKXXXXXO: .OM0'
|
|
||||||
,0No. ;xKXXXKx:. .;ldxkOOkkxol;'. 'cxKXXXXX0l. ,OMK;
|
|
||||||
'kWk, ,o0XXXXKko:,.........,:ldOKXXXXXKkc. .lXMO,
|
|
||||||
.cKNx; .,cxOKXXXXXXXXXXXXXXXXXXKko:. .lKMKl.
|
|
||||||
.cOWKd;. ..,;cllooollc:;'. 'ckNM0c.
|
|
||||||
'lONW0xl;.. .,:okXMNOo,
|
|
||||||
.,cdOXWMWNXKK00KKXNMMWXOdc,.
|
|
||||||
.,cokO00Okdc,.
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
# Configuration for resolvconf(8)
|
|
||||||
# See resolvconf.conf(5) for details
|
|
||||||
|
|
||||||
resolv_conf=/etc/resolv.conf
|
|
||||||
# If you run a local name server, you should uncomment the below line and
|
|
||||||
# configure your subscribers configuration files below.
|
|
||||||
#name_servers=127.0.0.1
|
|
||||||
append_nameservers='4.2.2.1 4.2.2.2 4.2.2.3'
|
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
# yaourtrc - Configuration for yaourt
|
||||||
|
#
|
||||||
|
# See yaourtrc(5) for more information
|
||||||
|
#
|
||||||
|
#
|
||||||
|
|
||||||
|
# General
|
||||||
|
#AUTOSAVEBACKUPFILE=0
|
||||||
|
#DEVELBUILDDIR="/var/abs/local/yaourtbuild"
|
||||||
|
#DEVEL=0
|
||||||
|
#EDITOR="$EDITOR"
|
||||||
|
#FORCEENGLISH=0
|
||||||
|
#FORCE=0
|
||||||
|
#TMPDIR="/tmp"
|
||||||
|
TMPDIR="/var/tmp"
|
||||||
|
|
||||||
|
# SUDO
|
||||||
|
#SUDONOVERIF=0 # Avoid multiple sudo checks when timestamp_timeout=0
|
||||||
|
#SUDOREDIRECT=1 # Define to 0 in case you use a fingerprint device
|
||||||
|
|
||||||
|
# ABS
|
||||||
|
# If the package "abs" is installed, those var are parsed from abs.conf
|
||||||
|
#REPOS=() # REPOS available at $SYNCSERVER
|
||||||
|
#SYNCSERVER=""
|
||||||
|
|
||||||
|
# AUR
|
||||||
|
#AURURL="https://aur.archlinux.org"
|
||||||
|
AURCOMMENT=0
|
||||||
|
#AURDEVELONLY=0
|
||||||
|
#AURSEARCH=1
|
||||||
|
#AURUPGRADE=0
|
||||||
|
#AURVOTE=1
|
||||||
|
|
||||||
|
# Build
|
||||||
|
#EXPORT=0 # Export to 1: EXPORTDIR or PKGDEST
|
||||||
|
# 2: pacman cache (as root)
|
||||||
|
#EXPORTSRC=0 # Need EXPORT>0 to be used
|
||||||
|
#EXPORTDIR="" # If empty, use makepkg's connfiguration (see makepkg.conf)
|
||||||
|
|
||||||
|
# Prompt
|
||||||
|
NOCONFIRM=0
|
||||||
|
UP_NOCONFIRM=1
|
||||||
|
BUILD_NOCONFIRM=1
|
||||||
|
PU_NOCONFIRM=1
|
||||||
|
EDITFILES=0
|
||||||
|
NOENTER=1
|
||||||
|
|
||||||
|
# Output
|
||||||
|
USECOLOR=1
|
||||||
|
#USEPAGER=0
|
||||||
|
DETAILUPGRADE=1
|
||||||
|
SHOWORPHANS=1
|
||||||
|
TERMINALTITLE=1
|
||||||
|
|
||||||
|
# Command
|
||||||
|
#PACMAN="pacman"
|
||||||
|
#DIFFEDITCMD="vimdiff"
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
set -e
|
|
||||||
|
|
||||||
apacman --noconfirm --noedit -S --needed customizepkg-scripting
|
|
||||||
ln -s /usr/lib/libdialog.so.1.2 /usr/lib/libdialog.so
|
|
||||||
|
|
||||||
echo "Done."
|
|
||||||
@@ -11,13 +11,19 @@ _mnt_fs() {
|
|||||||
ro_dev=$(losetup --find --show --read-only "${img}")
|
ro_dev=$(losetup --find --show --read-only "${img}")
|
||||||
echo ${ro_dev} >> /run/archiso/used_block_devices
|
echo ${ro_dev} >> /run/archiso/used_block_devices
|
||||||
ro_dev_size=$(blockdev --getsz ${ro_dev})
|
ro_dev_size=$(blockdev --getsz ${ro_dev})
|
||||||
|
if [[ "${cowfile_size}" == "100" ]]; then
|
||||||
|
rw_dev_size=${ro_dev_size}
|
||||||
|
else
|
||||||
|
# size calculation done in this way to avoid integer overflow when ro_dev_size is > 10.2G
|
||||||
|
rw_dev_size=$((ro_dev_size/100*cowfile_size))
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ "${cow_persistent}" == "P" ]]; then
|
if [[ "${cow_persistent}" == "P" ]]; then
|
||||||
if [[ -f "/run/archiso/cowspace/${cow_directory}/${img_name}.cow" ]]; then
|
if [[ -f "/run/archiso/cowspace/${cow_directory}/${img_name}.cow" ]]; then
|
||||||
msg ":: Found '/run/archiso/cowspace/${cow_directory}/${img_name}.cow', using as persistent."
|
msg ":: Found '/run/archiso/cowspace/${cow_directory}/${img_name}.cow', using as persistent."
|
||||||
else
|
else
|
||||||
msg ":: Creating '/run/archiso/cowspace/${cow_directory}/${img_name}.cow' as persistent."
|
msg ":: Creating '/run/archiso/cowspace/${cow_directory}/${img_name}.cow' as persistent."
|
||||||
truncate -s "${cowfile_size}" "/run/archiso/cowspace/${cow_directory}/${img_name}.cow"
|
dd of="/run/archiso/cowspace/${cow_directory}/${img_name}.cow" count=0 seek=${rw_dev_size} &> /dev/null
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
if [[ -f "/run/archiso/cowspace/${cow_directory}/${img_name}.cow" ]]; then
|
if [[ -f "/run/archiso/cowspace/${cow_directory}/${img_name}.cow" ]]; then
|
||||||
@@ -25,13 +31,13 @@ _mnt_fs() {
|
|||||||
rm -f "/run/archiso/cowspace/${cow_directory}/${img_name}.cow"
|
rm -f "/run/archiso/cowspace/${cow_directory}/${img_name}.cow"
|
||||||
fi
|
fi
|
||||||
msg ":: Creating '/run/archiso/cowspace/${cow_directory}/${img_name}.cow' as non-persistent."
|
msg ":: Creating '/run/archiso/cowspace/${cow_directory}/${img_name}.cow' as non-persistent."
|
||||||
truncate -s "${cowfile_size}" "/run/archiso/cowspace/${cow_directory}/${img_name}.cow"
|
dd of="/run/archiso/cowspace/${cow_directory}/${img_name}.cow" count=0 seek=${rw_dev_size} &> /dev/null
|
||||||
fi
|
fi
|
||||||
|
|
||||||
rw_dev=$(losetup --find --show "/run/archiso/cowspace/${cow_directory}/${img_name}.cow")
|
rw_dev=$(losetup --find --show "/run/archiso/cowspace/${cow_directory}/${img_name}.cow")
|
||||||
echo ${rw_dev} >> /run/archiso/used_block_devices
|
echo ${rw_dev} >> /run/archiso/used_block_devices
|
||||||
|
|
||||||
dmsetup create ${dm_snap_name} --table "0 ${ro_dev_size} snapshot ${ro_dev} ${rw_dev} ${cow_persistent} 8"
|
echo "0 ${ro_dev_size} snapshot ${ro_dev} ${rw_dev} ${cow_persistent} 8" | dmsetup create ${dm_snap_name}
|
||||||
|
|
||||||
_mnt_dev "/dev/mapper/${dm_snap_name}" "${newroot}${mnt}" "-w"
|
_mnt_dev "/dev/mapper/${dm_snap_name}" "${newroot}${mnt}" "-w"
|
||||||
echo $(readlink -f /dev/mapper/${dm_snap_name}) >> /run/archiso/used_block_devices
|
echo $(readlink -f /dev/mapper/${dm_snap_name}) >> /run/archiso/used_block_devices
|
||||||
@@ -46,8 +52,7 @@ _mnt_sfs() {
|
|||||||
|
|
||||||
if [[ "${copytoram}" == "y" ]]; then
|
if [[ "${copytoram}" == "y" ]]; then
|
||||||
msg -n ":: Copying squashfs image to RAM..."
|
msg -n ":: Copying squashfs image to RAM..."
|
||||||
#if ! cp "${img}" "/run/archiso/copytoram/${img_fullname}" ; then
|
if ! cp "${img}" "/run/archiso/copytoram/${img_fullname}" ; then
|
||||||
if ! pv -pterabT "${img}" > "/run/archiso/copytoram/${img_fullname}" ; then
|
|
||||||
echo "ERROR: while copy '${img}' to '/run/archiso/copytoram/${img_fullname}'"
|
echo "ERROR: while copy '${img}' to '/run/archiso/copytoram/${img_fullname}'"
|
||||||
launch_interactive_shell
|
launch_interactive_shell
|
||||||
fi
|
fi
|
||||||
@@ -103,7 +108,9 @@ run_hook() {
|
|||||||
[[ -z "${dm_snap_prefix}" ]] && dm_snap_prefix="arch"
|
[[ -z "${dm_snap_prefix}" ]] && dm_snap_prefix="arch"
|
||||||
[[ -z "${archisodevice}" ]] && archisodevice="/dev/disk/by-label/${archisolabel}"
|
[[ -z "${archisodevice}" ]] && archisodevice="/dev/disk/by-label/${archisolabel}"
|
||||||
if [[ -z "${cowfile_size}" ]]; then
|
if [[ -z "${cowfile_size}" ]]; then
|
||||||
cowfile_size="256M"
|
cowfile_size="100"
|
||||||
|
else
|
||||||
|
cowfile_size=${cowfile_size/%}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ -n "${cow_label}" ]]; then
|
if [[ -n "${cow_label}" ]]; then
|
||||||
@@ -169,7 +176,7 @@ archiso_mount_handler() {
|
|||||||
|
|
||||||
_mnt_sfs "/run/archiso/bootmnt/${archisobasedir}/${arch}/airootfs.sfs" "/run/archiso/sfs/airootfs"
|
_mnt_sfs "/run/archiso/bootmnt/${archisobasedir}/${arch}/airootfs.sfs" "/run/archiso/sfs/airootfs"
|
||||||
# _mnt_fs "/run/archiso/sfs/airootfs/airootfs.img" "${newroot}" "/"
|
# _mnt_fs "/run/archiso/sfs/airootfs/airootfs.img" "${newroot}" "/"
|
||||||
mount --bind "/run/archiso/sfs/airootfs" "/new_root"
|
mount --bind "run/archiso/sfs/airootfs" "/new_root"
|
||||||
|
|
||||||
if [[ "${copytoram}" == "y" ]]; then
|
if [[ "${copytoram}" == "y" ]]; then
|
||||||
umount /run/archiso/bootmnt
|
umount /run/archiso/bootmnt
|
||||||
|
|||||||
@@ -1,49 +0,0 @@
|
|||||||
# vim: set ft=sh:
|
|
||||||
|
|
||||||
run_hook() {
|
|
||||||
if [[ -n "${ip}" && -n "${archiso_http_srv}" ]]; then
|
|
||||||
|
|
||||||
archiso_http_srv=$(eval echo ${archiso_http_srv})
|
|
||||||
[[ -z "${archiso_http_spc}" ]] && archiso_http_spc="75%"
|
|
||||||
|
|
||||||
mount_handler="archiso_pxe_http_mount_handler"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# Fetch a file with CURL
|
|
||||||
#
|
|
||||||
# $1 URL
|
|
||||||
# $2 Destination directory inside httpspace/${archisobasedir}
|
|
||||||
_curl_get() {
|
|
||||||
local _url="${1}"
|
|
||||||
local _dst="${2}"
|
|
||||||
|
|
||||||
msg ":: Downloading image"
|
|
||||||
if ! curl -L -f -o "/run/archiso/httpspace/${archisobasedir}${_dst}/${_url##*/}" --create-dirs "${_url}"; then
|
|
||||||
echo "ERROR: Downloading failed."
|
|
||||||
#echo " Falling back to interactive prompt"
|
|
||||||
#echo " You can try to fix the problem manually, log out when you are finished"
|
|
||||||
#launch_interactive_shell
|
|
||||||
sleep 4
|
|
||||||
reboot -f
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
archiso_pxe_http_mount_handler () {
|
|
||||||
newroot="${1}"
|
|
||||||
|
|
||||||
msg ":: Mounting /run/archiso/httpspace (tmpfs) filesystem, size='${archiso_http_spc}'"
|
|
||||||
mkdir -p "/run/archiso/httpspace"
|
|
||||||
mount -t tmpfs -o size="${archiso_http_spc}",mode=0755 httpspace "/run/archiso/httpspace"
|
|
||||||
|
|
||||||
_curl_get "${archiso_http_srv}${archisobasedir}/${arch}/airootfs.sfs" "/${arch}"
|
|
||||||
|
|
||||||
if [[ "${checksum}" == "y" ]]; then
|
|
||||||
_curl_get "${archiso_http_srv}${archisobasedir}/${arch}/airootfs.md5" "/${arch}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
mkdir -p "/run/archiso/bootmnt"
|
|
||||||
mount -o bind /run/archiso/httpspace /run/archiso/bootmnt
|
|
||||||
|
|
||||||
archiso_mount_handler ${newroot}
|
|
||||||
}
|
|
||||||
@@ -1,18 +1,15 @@
|
|||||||
# vim: set ft=sh:
|
# vim: set ft=sh:
|
||||||
|
|
||||||
run_cleanuphook () {
|
run_cleanuphook () {
|
||||||
msg ":: Mounting OverlayFS on / with tmpfs=rw, ${root}=ro ..."
|
msg ":: Mounting aufs on / with tmpfs=rw, ${root}=ro ..."
|
||||||
modprobe overlay
|
modprobe aufs
|
||||||
|
|
||||||
echo "Now attempting overlay mount..."
|
echo "Now attempting aufs mount..."
|
||||||
|
|
||||||
#mkdir /new_root.hw
|
mkdir /new_root.hw
|
||||||
mkdir -p /run/archiso/cowspace/upperdir /run/archiso/cowspace/workdir
|
mount --move /new_root /new_root.hw
|
||||||
#mount --move /new_root /new_root.hw
|
mkdir /dev/shm
|
||||||
#mkdir /dev/shm
|
mount -t tmpfs none /dev/shm
|
||||||
#mount -t tmpfs none /dev/shm
|
mount -t aufs none /new_root -o dirs=/dev/shm=rw:/new_root.hw=ro -o noatime
|
||||||
#mount -t overlay overlay -olowerdir=/new_root.hw,upperdir=/new_root,workdir=/dev/shm -o noatime
|
|
||||||
umount -l /new_root > /dev/null 2>&1
|
|
||||||
mount -t overlay -o lowerdir=/run/archiso/sfs/airootfs,upperdir=/run/archiso/cowspace/upperdir,workdir=/run/archiso/cowspace/workdir airootfs /new_root
|
|
||||||
pkill -9 dropbear #kill SSH (in preparation for the live system starting ssh on port 22
|
pkill -9 dropbear #kill SSH (in preparation for the live system starting ssh on port 22
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,7 +13,6 @@ build() {
|
|||||||
add_binary losetup
|
add_binary losetup
|
||||||
add_binary mountpoint
|
add_binary mountpoint
|
||||||
add_binary truncate
|
add_binary truncate
|
||||||
add_binary pv
|
|
||||||
|
|
||||||
add_file /usr/lib/udev/rules.d/60-cdrom_id.rules
|
add_file /usr/lib/udev/rules.d/60-cdrom_id.rules
|
||||||
add_file /usr/lib/udev/rules.d/10-dm.rules
|
add_file /usr/lib/udev/rules.d/10-dm.rules
|
||||||
|
|||||||
@@ -1,18 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
build() {
|
|
||||||
add_runscript
|
|
||||||
|
|
||||||
add_binary curl
|
|
||||||
|
|
||||||
add_full_dir /etc/ssl
|
|
||||||
add_full_dir /etc/ca-certificates
|
|
||||||
}
|
|
||||||
|
|
||||||
help() {
|
|
||||||
cat<<HELPEOF
|
|
||||||
This hook loads the necessary modules for boot via PXE and HTTP.
|
|
||||||
HELPEOF
|
|
||||||
}
|
|
||||||
|
|
||||||
# vim: set ft=sh ts=4 sw=4 et:
|
|
||||||
@@ -4,7 +4,7 @@ build()
|
|||||||
{
|
{
|
||||||
add_module 'squashfs'
|
add_module 'squashfs'
|
||||||
add_module 'loop'
|
add_module 'loop'
|
||||||
add_module 'overlay'
|
add_module 'aufs'
|
||||||
|
|
||||||
add_binary "sed"
|
add_binary "sed"
|
||||||
add_binary "pkill"
|
add_binary "pkill"
|
||||||
@@ -16,6 +16,6 @@ build()
|
|||||||
help()
|
help()
|
||||||
{
|
{
|
||||||
cat <<HELPEOF
|
cat <<HELPEOF
|
||||||
Mount a squashed flat-file directory with OverlayFS on /
|
Mount a squashed flat-file directory with AUFS3 on /
|
||||||
HELPEOF
|
HELPEOF
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,30 @@
|
|||||||
|
function im_batman {
|
||||||
|
set +e # false errors are bad mmk
|
||||||
|
# Detect the distro and set some vars
|
||||||
|
if [ -f "/usr/bin/yum" ]; # CentOS/Redhat, etc.
|
||||||
|
then
|
||||||
|
OS_STRING='RHEL-like'
|
||||||
|
DISTRO='RHEL'
|
||||||
|
INST_CMD='yum -y install '
|
||||||
|
elif [ -f "/usr/bin/pacman" ]; # Arch, Manjaro, etc.
|
||||||
|
then
|
||||||
|
OS_STRING='Arch-like'
|
||||||
|
DISTRO='Arch'
|
||||||
|
INST_CMD='pacman -S '
|
||||||
|
elif [ -f "/usr/bin/emerge" ]; # Gentoo
|
||||||
|
then
|
||||||
|
OS_STRING='Gentoo-like'
|
||||||
|
DISTRO='Gentoo'
|
||||||
|
INST_CMD='emerge '
|
||||||
|
elif [ -f "/usr/bin/apt-get" ]; # Debian, Ubuntu (and derivatives), etc.
|
||||||
|
then
|
||||||
|
OS_STRING='Debian-like'
|
||||||
|
DISTRO="Debian"
|
||||||
|
INST_CMD='apt-get install '
|
||||||
|
else
|
||||||
|
echo 'Sorry, I cannot detect which distro you are running. Please report this along with what distro you are running. Dying now.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
set -e # and turn this back on lolz
|
||||||
|
}
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
function holla_atcha_boi {
|
||||||
|
|
||||||
|
if [[ "${I_AM_A_RACECAR}" == "y" ]];
|
||||||
|
then
|
||||||
|
RACECAR_CHK='nice -n -19 '
|
||||||
|
else
|
||||||
|
RACECAR_CHK=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Do we have an existing chroot set up yet? If not, create.
|
||||||
|
if [[ ! -d "root.x86_64/root" || ! -d "root.i686/root" ]];
|
||||||
|
then
|
||||||
|
echo "No existing chroot environment found. Creating..."
|
||||||
|
rm -f ${LOCKFILE}
|
||||||
|
${RACECAR_CHK} ${BASEDIR}/lib/mk.chroot.sh
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,50 @@
|
|||||||
|
function release_me () {
|
||||||
|
## check for mountpoints from a manual chroot and umount them if they're still mounted.
|
||||||
|
## NOTE: you can use findmnt(8) to view a tree of mountpoints, including bindmounts etc.
|
||||||
|
# Is there an active chroot?
|
||||||
|
set +e
|
||||||
|
if [[ "${1}" == "64" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.x86_64"
|
||||||
|
local BUILDDIR="${BUILDDIR}64"
|
||||||
|
elif [[ "${1}" == "32" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.i686"
|
||||||
|
local BUILDDIR="${BUILDDIR}32"
|
||||||
|
else
|
||||||
|
echo "WHOOPS. We hit an error that makes no logical sense."
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Checking for and cleaning up mountpoints from the chroot environment..."
|
||||||
|
for i in tmp run dev/shm dev/pts dev
|
||||||
|
do
|
||||||
|
umount -l ${CHROOTDIR}/${i}
|
||||||
|
done
|
||||||
|
# and is it using efivars?
|
||||||
|
if [ -d ${CHROOTDIR}/sys/firmware/efi/efivars ];
|
||||||
|
then
|
||||||
|
umount -l ${CHROOTDIR}/sys/firmware/efi/efivars
|
||||||
|
fi
|
||||||
|
# and finish cleaning up normal chroots
|
||||||
|
for i in sys proc
|
||||||
|
do
|
||||||
|
umount -l ${CHROOTDIR}/${i}
|
||||||
|
done
|
||||||
|
# and is it mounted via two mountpoints a la arch-chroot?
|
||||||
|
mount | awk '{print $3}' | grep -q ${MOUNTPT}
|
||||||
|
if [[ ${?} == "0" ]];
|
||||||
|
then
|
||||||
|
umount ${MOUNTPT}
|
||||||
|
fi
|
||||||
|
if [ -d ${SRCDIR}/efiboot ];
|
||||||
|
then
|
||||||
|
umount -l ${SRCDIR}/efiboot
|
||||||
|
fi
|
||||||
|
rm -rf ${SRCDIR}/efiboot
|
||||||
|
#rm -rf ${TEMPDIR}/*
|
||||||
|
set -e # and go back to failing on non-0 exit status.
|
||||||
|
CHROOTDIR="${CHROOTDIR_GLOB}"
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
}
|
||||||
@@ -0,0 +1,39 @@
|
|||||||
|
function facehugger () {
|
||||||
|
local ARCHSUFFIX="${1}"
|
||||||
|
if [[ "${1}" == "64" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.x86_64"
|
||||||
|
local BUILDDIR="${BUILDDIR}64"
|
||||||
|
elif [[ "${1}" == "32" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.i686"
|
||||||
|
local BUILDDIR="${BUILDDIR}32"
|
||||||
|
else
|
||||||
|
echo "WHOOPS. We hit an error that makes no logical sense."
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Creating manual chroot mountpoints."
|
||||||
|
# Latch on and inject ourself into the environment. Get it?
|
||||||
|
mount -t proc -o nosuid,noexec,nodev proc ${CHROOTDIR}/proc &&
|
||||||
|
mount -t sysfs -o nosuid,noexec,nodev,ro sys ${CHROOTDIR}/sys &&
|
||||||
|
if [ -d /sys/firmware/efi/efivars ];
|
||||||
|
then
|
||||||
|
mount -t efivarfs -o nosuid,noexec,nodev efivarfs ${CHROOTDIR}/sys/firmware/efi/efivars
|
||||||
|
fi &&
|
||||||
|
mount -t devtmpfs -o mode=0755,nosuid udev ${CHROOTDIR}/dev &&
|
||||||
|
mount -t devpts -o mode=0620,gid=5,nosuid,noexec devpts ${CHROOTDIR}/dev/pts &&
|
||||||
|
mount -t tmpfs -o mode=1777,nosuid,nodev shm ${CHROOTDIR}/dev/shm &&
|
||||||
|
mount -t tmpfs -o nosuid,nodev,mode=0755 run ${CHROOTDIR}/run &&
|
||||||
|
mount -t tmpfs -o mode=1777,strictatime,nodev,nosuid tmp ${CHROOTDIR}/tmp
|
||||||
|
echo "======================"
|
||||||
|
echo "NOW ENTERING CHROOT..."
|
||||||
|
echo "======================"
|
||||||
|
chroot ${CHROOTDIR} /bin/bash
|
||||||
|
rm -f ${CHROOTDIR}/root/chroot
|
||||||
|
CHROOTDIR="${CHROOTDIR_GLOB}"
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
release_me ${ARCHSUFFIX}
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,29 @@
|
|||||||
|
function chroot_wrapper () {
|
||||||
|
local ARCHSUFFIX="${1}"
|
||||||
|
if [[ "${1}" == "64" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.x86_64"
|
||||||
|
local BUILDDIR="${BUILDDIR}64"
|
||||||
|
elif [[ "${1}" == "32" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.i686"
|
||||||
|
local BUILDDIR="${BUILDDIR}32"
|
||||||
|
else
|
||||||
|
echo "WHOOPS. We hit an error that makes no logical sense."
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f "/usr/bin/systemd-nspawn" ];
|
||||||
|
then
|
||||||
|
CHROOTCMD="systemd-nspawn -D ${CHROOTDIR}"
|
||||||
|
else
|
||||||
|
CHROOTCMD="facehugger ${ARCHSUFFIX}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "NOW ENTERING ${CHROOTDIR}...."
|
||||||
|
echo "_____________________________"
|
||||||
|
${CHROOTCMD}
|
||||||
|
CHROOTDIR="${CHROOTDIR_GLOB}"
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
function jenny_craig () {
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
if [[ "${1}" == "64" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.x86_64"
|
||||||
|
local BUILDDIR="${BUILDDIR}64"
|
||||||
|
elif [[ "${1}" == "32" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.i686"
|
||||||
|
local BUILDDIR="${BUILDDIR}32"
|
||||||
|
else
|
||||||
|
echo "WHOOPS. We hit an error that makes no logical sense."
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
local _CURDIR=$(pwd)
|
||||||
|
echo "Syncing important files to ${BUILDDIR} for building the squashed filesystem (this may take some time)..."
|
||||||
|
|
||||||
|
# we have to do this or else the package management from LIVE doesn't really work too hot.
|
||||||
|
cd ${CHROOTDIR}/var/lib/pacman
|
||||||
|
echo "Compressing the package DB..."
|
||||||
|
#rm -f ${CHROOTDIR}/usr/local/pacman.db.tar.xz
|
||||||
|
tar -cf - local | xz -c9 > ../../../usr/local/pacman.db.tar.xz
|
||||||
|
cd ${_CURDIR}
|
||||||
|
|
||||||
|
# sync over new changes and trim out the fat
|
||||||
|
rsync -a --delete ${CHROOTDIR}/. ${BUILDDIR}/.
|
||||||
|
set +e
|
||||||
|
cp -af ${BUILDDIR}/usr/share/zoneinfo/EST5EDT ${BUILDDIR}/etc/localtime
|
||||||
|
cp -af ${CHROOTDIR}/usr/share/zoneinfo/EST5EDT ${CHROOTDIR}/etc/localtime
|
||||||
|
set -e
|
||||||
|
cp -af ${BUILDDIR}/usr/share/locale/locale.alias ${BUILDDIR}/tmp/.
|
||||||
|
echo "Cleaning up unnecessary cruft in ${BUILDDIR}..."
|
||||||
|
|
||||||
|
rm -f ${BUILDDIR}/root/.bash_history
|
||||||
|
rm -f ${BUILDDIR}/root/.viminfo
|
||||||
|
#rm -f ${BUILDDIR}/etc/localtime
|
||||||
|
rm -f ${BUILDDIR}/root/.bashrc
|
||||||
|
# DISABLE when no longer building custom kernel
|
||||||
|
find ${BUILDDIR}/usr/lib/modules/ -maxdepth 1 -iname "*-ARCH" -exec rm -rf '{}' \;
|
||||||
|
find ${BUILDDIR}/ -type f -name "*.pacnew" -exec rm -rf '{}' \;
|
||||||
|
rm -rf ${BUILDDIR}/usr/share/locale/*
|
||||||
|
mv -f ${BUILDDIR}/tmp/locale.alias ${BUILDDIR}/usr/share/locale/.
|
||||||
|
rm -rf ${BUILDDIR}/var/cache/pacman/*
|
||||||
|
rm -rf ${BUILDDIR}/var/cache/pkgfile/*
|
||||||
|
rm -rf ${BUILDDIR}/var/lib/pacman/*
|
||||||
|
mkdir -p ${BUILDDIR}/var/lib/pacman/local
|
||||||
|
rm -rf ${BUILDDIR}/var/abs/local/yaourtbuild/*
|
||||||
|
rm -rf ${BUILDDIR}/usr/share/zoneinfo
|
||||||
|
rm -rf ${BUILDDIR}/tmp/*
|
||||||
|
rm -rf ${BUILDDIR}/var/tmp/*
|
||||||
|
rm -rf ${BUILDDIR}/var/abs/*
|
||||||
|
rm -rf ${BUILDDIR}/run/*
|
||||||
|
rm -rf ${BUILDDIR}/boot/*
|
||||||
|
rm -rf ${BUILDDIR}/usr/src/*
|
||||||
|
rm -rf ${BUILDDIR}/var/log/*
|
||||||
|
rm -rf ${BUILDDIR}/.git
|
||||||
|
CHROOTDIR="${CHROOTDIR_GLOB}"
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
function centos_is_stupid {
|
||||||
|
echo "Checking for appropriate kernel version and mksquashfs version..."
|
||||||
|
SQFS_VER=$(mksquashfs -version 2>&1 | head -n1 | awk '{print $3}' | sed -re 's/(^[0-9]*\.[0-9]*).*$/\1/g')
|
||||||
|
KERN_VER=$(uname -r | cut -f1 -d"-")
|
||||||
|
SQUASH_OPTS="-noappend -comp xz"
|
||||||
|
|
||||||
|
set +e
|
||||||
|
ver_check() {
|
||||||
|
[ "$1" == "$2" ] && return 10
|
||||||
|
ver1front=`echo $1 | cut -d "." -f -1`
|
||||||
|
ver1back=`echo $1 | cut -d "." -f 2-`
|
||||||
|
ver2front=`echo $2 | cut -d "." -f -1`
|
||||||
|
ver2back=`echo $2 | cut -d "." -f 2-`
|
||||||
|
if [ "$ver1front" != "$1" ] || [ "$ver2front" != "$2" ]; then
|
||||||
|
[ "$ver1front" -gt "$ver2front" ] && return 11
|
||||||
|
[ "$ver1front" -lt "$ver2front" ] && return 9
|
||||||
|
[ "$ver1front" == "$1" ] || [ -z "$ver1back" ] && ver1back=0
|
||||||
|
[ "$ver2front" == "$2" ] || [ -z "$ver2back" ] && ver2back=0
|
||||||
|
ver_check "$ver1back" "$ver2back"
|
||||||
|
return $?
|
||||||
|
else
|
||||||
|
[ "$1" -gt "$2" ] && return 11 || return 9
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
ver_check ${KERN_VER} "2.6.38"
|
||||||
|
KERNTEST=${?}
|
||||||
|
ver_check ${SQFS_VER} "4.2"
|
||||||
|
SQFSTEST=${?}
|
||||||
|
if [ ${KERNTEST} -lt "10" ];
|
||||||
|
then
|
||||||
|
echo "You need a newer kernel to even think about doing this. (>= 2.6.38)"
|
||||||
|
echo "If you're on CentOS, there are 3.x branches available via the elrepo repository."
|
||||||
|
echo "I recommend the 'kernel-lt' package from there."
|
||||||
|
echo "Bailing out."
|
||||||
|
exit 1
|
||||||
|
#elif [ ${SQFS_VER} -ge "4.2" ] && [ ${KERN_VER} -ge "2.6.38" ];
|
||||||
|
elif [ ${SQFSTEST} -ge "10" ] && [ ${KERNTEST} -ge "10" ];
|
||||||
|
then
|
||||||
|
#echo "Awesome; your mksquashfs (if found) is not less than v4.2."
|
||||||
|
SQUASH_CMD=$(which mksquashfs)
|
||||||
|
if [ ${?} != "0" ];
|
||||||
|
then
|
||||||
|
echo "...Except you need to install whatever package you need to for mksquashfs."
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
SQUASH_CMD=$(which mksquashfs)
|
||||||
|
fi
|
||||||
|
elif [ ${SQFSTEST} -lt "10" ] && [ ${KERNTEST} -ge "10" ];
|
||||||
|
then
|
||||||
|
if [ ! -f ${SRCDIR}/squashfs4.2/squashfs-tools/mksquashfs ];
|
||||||
|
then
|
||||||
|
echo "Boy howdy. We need to compile a custom version of the squashfs-tools because you aren't running a version that supports XZ. Give me a second."
|
||||||
|
set -e
|
||||||
|
mkdir -p ${SRCDIR} ${ROOTDIR}/bin
|
||||||
|
cd ${SRCDIR}
|
||||||
|
#wget --quiet -O squashfs4.2.tar.gz "http://downloads.sourceforge.net/project/squashfs/squashfs/squashfs4.2/squashfs4.2.tar.gz?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fsquashfs%2Ffiles%2F&ts=1387047818&use_mirror=hivelocity"
|
||||||
|
curl -o squashfs4.2.tar.gz "http://downloads.sourceforge.net/project/squashfs/squashfs/squashfs4.2/squashfs4.2.tar.gz?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fsquashfs%2Ffiles%2F&ts=1387047818&use_mirror=hivelocity" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
tar -zxf squashfs4.2.tar.gz
|
||||||
|
cd squashfs4.2/squashfs-tools
|
||||||
|
make clean
|
||||||
|
sed -i -e 's/^#\(XZ_SUPPORT\)/\1/g' Makefile
|
||||||
|
make
|
||||||
|
SQUASH_CMD="${SRCDIR}/squashfs4.2/squashfs-tools/mksquashfs"
|
||||||
|
else
|
||||||
|
echo "Using custom-compiled mksquashfs from an earlier run."
|
||||||
|
SQUASH_CMD="${SRCDIR}/squashfs4.2/squashfs-tools/mksquashfs"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
set -e
|
||||||
|
}
|
||||||
@@ -0,0 +1,77 @@
|
|||||||
|
function will_it_blend () {
|
||||||
|
local ARCHSUFFIX="${1}"
|
||||||
|
if [[ "${1}" == "64" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.x86_64"
|
||||||
|
local BUILDDIR="${BUILDDIR}64"
|
||||||
|
local AIROOT="x86_64"
|
||||||
|
_CHROOT=${CHROOTDIR}
|
||||||
|
_BUILD=${BUILDDIR}
|
||||||
|
_AIROOT=${AIROOT}
|
||||||
|
elif [[ "${1}" == "32" ]];
|
||||||
|
then
|
||||||
|
local CHROOTDIR="${CHROOTDIR}root.i686"
|
||||||
|
local BUILDDIR="${BUILDDIR}32"
|
||||||
|
local AIROOT="i686"
|
||||||
|
_CHROOT=${CHROOTDIR}
|
||||||
|
_BUILD=${BUILDDIR}
|
||||||
|
_AIROOT=${AIROOT}
|
||||||
|
else
|
||||||
|
echo "WHOOPS. We hit an error that makes no logical sense."
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${I_AM_A_RACECAR}" == "y" ]];
|
||||||
|
then
|
||||||
|
RACECAR_CHK='nice -n -19 '
|
||||||
|
else
|
||||||
|
RACECAR_CHK=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "${CHROOTDIR}/root/.bash_history" -nt "${ARCHBOOT}/${AIROOT}/airootfs.sfs" ] || [ ! -d "${BUILDDIR}/root/" ];
|
||||||
|
then
|
||||||
|
echo "Data is not sync'd to buildroot; syncing..."
|
||||||
|
CHROOTDIR="${CHROOTDIR_GLOB}"
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
jenny_craig ${ARCHSUFFIX}
|
||||||
|
CHROOTDIR="${_CHROOT}"
|
||||||
|
BUILDDIR="${_BUILD}"
|
||||||
|
fi
|
||||||
|
echo "[${ARCHSUFFIX}-bit] Now generating the squashed image (if we need to) and hashes. This may take some time."
|
||||||
|
BUILDDIR="${BUILDDIR_GLOB}"
|
||||||
|
local BUILDDIR="${BUILDDIR}${ARCHSUFFIX}"
|
||||||
|
|
||||||
|
# now let's build the squashed image... and generate some checksums as well to verify download integrity.
|
||||||
|
mkdir -p ${ARCHBOOT}/${AIROOT}
|
||||||
|
|
||||||
|
if [ ! -f "${ARCHBOOT}/${AIROOT}/airootfs.sfs" ] || [ "${CHROOTDIR}/root/.bash_history" -nt "${ARCHBOOT}/${AIROOT}/airootfs.sfs" ];
|
||||||
|
then
|
||||||
|
echo "[${ARCHSUFFIX}-bit] Squashing filesystem. This can take a while depending on the size of your chroot(s)."
|
||||||
|
${RACECAR_CHK}${SQUASH_CMD} ${BUILDDIR} ${ARCHBOOT}/${AIROOT}/airootfs.sfs ${SQUASH_OPTS} >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
cd ${ARCHBOOT}/${AIROOT}
|
||||||
|
${RACECAR_CHK}sha256sum airootfs.sfs >> airootfs.sha256
|
||||||
|
${RACECAR_CHK}md5sum airootfs.sfs >> airootfs.md5
|
||||||
|
cd ${ROOTDIR}
|
||||||
|
else
|
||||||
|
cd ${ROOTDIR}
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Generate the mtree spec.
|
||||||
|
# Not really necessary anymore.
|
||||||
|
#mtree -c -p ${ROOTDIR}/chroot -K flags,gid,mode,nlink,uid,link,time,type > ${ROOTDIR}/extra/mtree.spec
|
||||||
|
|
||||||
|
# and now we copy stuff into the live directories
|
||||||
|
echo "[${ARCHSUFFIX}-bit] Copying files for PXE, and ISO building, please be patient."
|
||||||
|
#rm -rf ${TEMPDIR}/*
|
||||||
|
cp -af ${BASEDIR}/extra/${UXNAME}.png ${TEMPDIR}/.
|
||||||
|
cp -af ${BASEDIR}/extra/${UXNAME}.png ${TFTPDIR}/.
|
||||||
|
mkdir -p ${TEMPDIR}/boot
|
||||||
|
cp -af ${CHROOTDIR}/boot/initramfs-linux-${PNAME}.img ${TEMPDIR}/boot/${UXNAME}.${ARCHSUFFIX}.img
|
||||||
|
cp -af ${CHROOTDIR}/boot/vmlinuz-linux-${PNAME} ${TEMPDIR}/boot/${UXNAME}.${ARCHSUFFIX}.kern
|
||||||
|
cp -af ${CHROOTDIR}/boot/initramfs-linux-${PNAME}.img ${TFTPDIR}/${UXNAME}.${ARCHSUFFIX}.img
|
||||||
|
cp -af ${CHROOTDIR}/boot/vmlinuz-linux-${PNAME} ${TFTPDIR}/${UXNAME}.${ARCHSUFFIX}.kern
|
||||||
|
cp -af ${ARCHBOOT}/* ${HTTPDIR}/${DISTNAME}/.
|
||||||
|
chown -R ${HTTPUSR}:${HTTPGRP} ${HTTPDIR}
|
||||||
|
chown ${TFTPUSR}:${TFTPGRP} ${TFTPDIR}/${UXNAME}.*
|
||||||
|
}
|
||||||
@@ -0,0 +1,106 @@
|
|||||||
|
function stuffy {
|
||||||
|
|
||||||
|
cp -f ${BASEDIR}/VERSION_INFO.txt ${TEMPDIR}/.
|
||||||
|
|
||||||
|
if [[ "${I_AM_A_RACECAR}" == "y" ]];
|
||||||
|
then
|
||||||
|
RACECAR_CHK='nice -n -19 '
|
||||||
|
else
|
||||||
|
RACECAR_CHK=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Setting up EFI stuff..."
|
||||||
|
|
||||||
|
mkdir -p ${TEMPDIR}/{EFI/{${DISTNAME},boot},loader/entries}
|
||||||
|
# this stuff comes from the prebootloader pkg and gummiboot pkg. lets us boot on UEFI machines with secureboot still enabled.
|
||||||
|
cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/PreLoader.efi ${TEMPDIR}/EFI/boot/bootx64.efi
|
||||||
|
cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/HashTool.efi ${TEMPDIR}/EFI/boot/.
|
||||||
|
cp ${BASEDIR}/root.x86_64/usr/lib/gummiboot/gummibootx64.efi ${TEMPDIR}/EFI/boot/loader.efi # TODO: can i use syslinux.efi instead?
|
||||||
|
|
||||||
|
echo "Checking/fetching UEFI shells..."
|
||||||
|
if [ ! -f "${TEMPDIR}/EFI/shellx64_v2.efi" ];
|
||||||
|
then
|
||||||
|
# EFI Shell 2.0 for UEFI 2.3+ ( http://sourceforge.net/apps/mediawiki/tianocore/index.php?title=UEFI_Shell )
|
||||||
|
curl -o ${TEMPDIR}/EFI/shellx64_v2.efi https://svn.code.sf.net/p/edk2/code/trunk/edk2/ShellBinPkg/UefiShell/X64/Shell.efi >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
if [ ! -f "${TEMPDIR}/EFI/shellx64_v1.efi" ];
|
||||||
|
then
|
||||||
|
# EFI Shell 1.0 for non UEFI 2.3+ ( http://sourceforge.net/apps/mediawiki/tianocore/index.php?title=Efi-shell )
|
||||||
|
curl -o ${TEMPDIR}/EFI/shellx64_v1.efi https://svn.code.sf.net/p/edk2/code/trunk/edk2/EdkShellBinPkg/FullShell/X64/Shell_Full.efi >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# now for setting up loader config/entries. maybe add memtest or something in the future? i dunno.
|
||||||
|
cat > ${TEMPDIR}/loader/loader.conf << EOF
|
||||||
|
timeout 3
|
||||||
|
default ${UXNAME}_ram
|
||||||
|
EOF
|
||||||
|
cat > ${TEMPDIR}/loader/entries/${UXNAME}_ram.conf << EOF
|
||||||
|
title ${PNAME}
|
||||||
|
linux /boot/${UXNAME}.kern
|
||||||
|
initrd /boot/${UXNAME}.img
|
||||||
|
options copytoram archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
EOF
|
||||||
|
cat > ${TEMPDIR}/loader/entries/${UXNAME}.conf << EOF
|
||||||
|
title ${PNAME} (Run from media)
|
||||||
|
linux /boot/${UXNAME}.kern
|
||||||
|
initrd /boot/${UXNAME}.img
|
||||||
|
options archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
EOF
|
||||||
|
cat > ${TEMPDIR}/loader/entries/uefi2.conf << EOF
|
||||||
|
title UEFI Shell (v2)
|
||||||
|
efi /EFI/shellx64_v2.efi
|
||||||
|
EOF
|
||||||
|
cat > ${TEMPDIR}/loader/entries/uefi1.conf << EOF
|
||||||
|
title UEFI Shell (v1)
|
||||||
|
efi /EFI/shellx64_v1.efi
|
||||||
|
EOF
|
||||||
|
|
||||||
|
|
||||||
|
# create the embedded efiboot FAT stuff
|
||||||
|
# how big should we make the disk?
|
||||||
|
echo "Generating the EFI embedded FAT filesystem..."
|
||||||
|
FTSIZE=$(du -sc ${TEMPDIR}/{boot,EFI,loader} | tail -n1 | awk '{print $1}')
|
||||||
|
FATSIZE=$((${FTSIZE} + 64)) # let's give a little wiggle room
|
||||||
|
${RACECAR_CHK}truncate -s "${FATSIZE}"K ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img
|
||||||
|
${RACECAR_CHK}mkfs.vfat -n ${DISTNAME}_EFI ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
mkdir -p ${SRCDIR}/efiboot
|
||||||
|
mount ${TEMPDIR}/EFI/${DISTNAME}/efiboot.img ${SRCDIR}/efiboot
|
||||||
|
mkdir -p ${SRCDIR}/efiboot/EFI/${DISTNAME}
|
||||||
|
cp ${TEMPDIR}/boot/${UXNAME}.64.kern ${SRCDIR}/efiboot/EFI/${DISTNAME}/${UXNAME}.efi
|
||||||
|
cp ${TEMPDIR}/boot/${UXNAME}.64.img ${SRCDIR}/efiboot/EFI/${DISTNAME}/${UXNAME}.img
|
||||||
|
mkdir -p ${SRCDIR}/efiboot/{EFI/boot,loader/entries}
|
||||||
|
# GETTING DEJA VU HERE.
|
||||||
|
cat > ${SRCDIR}/efiboot/loader/loader.conf << EOF
|
||||||
|
timeout 3
|
||||||
|
default ${UXNAME}_ram
|
||||||
|
EOF
|
||||||
|
cat > ${SRCDIR}/efiboot/loader/entries/${UXNAME}_ram.conf << EOF
|
||||||
|
title ${PNAME}
|
||||||
|
linux /EFI/${DISTNAME}/${UXNAME}.efi
|
||||||
|
initrd /EFI/${DISTNAME}/${UXNAME}.img
|
||||||
|
options copytoram archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
EOF
|
||||||
|
cat > ${SRCDIR}/efiboot/loader/entries/${UXNAME}.conf << EOF
|
||||||
|
title ${PNAME} (Run from media)
|
||||||
|
linux /EFI/${DISTNAME}/${UXNAME}.efi
|
||||||
|
initrd /EFI/${DISTNAME}/${UXNAME}.img
|
||||||
|
options archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
EOF
|
||||||
|
cat > ${SRCDIR}/efiboot/loader/entries/uefi2.conf << EOF
|
||||||
|
title UEFI Shell (v2)
|
||||||
|
efi /EFI/shellx64_v2.efi
|
||||||
|
EOF
|
||||||
|
cat > ${SRCDIR}/efiboot/loader/entries/uefi1.conf << EOF
|
||||||
|
title UEFI Shell (v1)
|
||||||
|
efi /EFI/shellx64_v1.efi
|
||||||
|
EOF
|
||||||
|
|
||||||
|
cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/PreLoader.efi ${SRCDIR}/efiboot/EFI/boot/bootx64.efi
|
||||||
|
cp ${BASEDIR}/root.x86_64/usr/lib/prebootloader/HashTool.efi ${SRCDIR}/efiboot/EFI/boot/.
|
||||||
|
cp ${BASEDIR}/root.x86_64/usr/lib/gummiboot/gummibootx64.efi ${SRCDIR}/efiboot/EFI/boot/loader.efi # TODO: can i use syslinux.efi instead?
|
||||||
|
cp ${TEMPDIR}/EFI/shellx64_v* ${SRCDIR}/efiboot/EFI/.
|
||||||
|
umount ${SRCDIR}/efiboot
|
||||||
|
echo "EFI configuration complete..."
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,296 @@
|
|||||||
|
function yo_dj () {
|
||||||
|
ARCH="${1}"
|
||||||
|
echo "Building the actual .iso image. This may take a while."
|
||||||
|
im_batman
|
||||||
|
ISOFILENAME="${UXNAME}-${VERSION}.iso"
|
||||||
|
if [[ "${MULTIARCH}" == "y" ]];
|
||||||
|
then
|
||||||
|
ISOFILENAME="${UXNAME}-${VERSION}-any.iso"
|
||||||
|
else
|
||||||
|
ISOFILENAME="${UXNAME}-${VERSION}-${ARCH}.iso"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${I_AM_A_RACECAR}" == "y" ]];
|
||||||
|
then
|
||||||
|
RACECAR_CHK='nice -n -19 '
|
||||||
|
else
|
||||||
|
RACECAR_CHK=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
# and why not? generate the ISO.
|
||||||
|
## we need to generate the isolinux.cfg
|
||||||
|
mkdir -p ${TEMPDIR}/isolinux
|
||||||
|
if [[ "${MULTIARCH}" == "y" ]];
|
||||||
|
then
|
||||||
|
## MULTIARCH ISO
|
||||||
|
cat > ${TEMPDIR}/isolinux/isolinux.cfg << EOF
|
||||||
|
UI vesamenu.c32
|
||||||
|
DEFAULT check
|
||||||
|
PROMPT 0
|
||||||
|
TIMEOUT 50
|
||||||
|
MENU HIDDEN
|
||||||
|
#ONTIMEOUT ${UXNAME}_ram
|
||||||
|
ONTIMEOUT check
|
||||||
|
MENU TABMSG Press [TAB] to edit options
|
||||||
|
#MENU TITLE ${PNAME} (ISO edition)
|
||||||
|
MENU ROWS 16
|
||||||
|
MENU TIMEOUTROW 22
|
||||||
|
MENU TABMSGROW 24
|
||||||
|
MENU CMDLINEROW 24
|
||||||
|
MENU HELPMSGROW 26
|
||||||
|
MENU WIDTH 78
|
||||||
|
MENU MARGIN 6
|
||||||
|
MENU IMMEDIATE
|
||||||
|
# http://www.colorpicker.com/
|
||||||
|
MENU color border 0 #00000000 #00000000 none
|
||||||
|
MENU color title 0 #FFF5B800 #00000000 std
|
||||||
|
MENU color sel 7;37;40 #FF000000 #FFFFFFFF all
|
||||||
|
MENU color hotsel 1;7;37;40 #FFFF0000 #FFC0C0C0 all
|
||||||
|
MENU color hotkey 1;7;37;40 #FF0000CC #FFC0C0C0 all
|
||||||
|
MENU color tabmsg 1;31;40 #FF808080 #00000000 std
|
||||||
|
MENU color help 1;31;40 #FFFFFFFF #FF000000 none
|
||||||
|
MENU color timeout_msg 0 #FFFFB300 #00000000 none
|
||||||
|
MENU color timeout 0 #FFFF0000 #FF000000 none
|
||||||
|
MENU color cmdline 0 #FFFFFFFF #FF000000 none
|
||||||
|
MENU color cmdmark 1;36;40 #C000FFFF #FF000000 std
|
||||||
|
MENU color scrollbar 30;44 #FF00FF00 #FF000000 std
|
||||||
|
MENU color msg07 0 #FF000000 #00FFFFFF none
|
||||||
|
MENU BACKGROUND /${UXNAME}.png
|
||||||
|
|
||||||
|
LABEL check
|
||||||
|
MENU LABEL Your best supported kernel should be detected automatically.
|
||||||
|
COM32 ifcpu64.c32
|
||||||
|
APPEND ${UXNAME}_ram_64 -- ${UXNAME}_ram_32
|
||||||
|
MENU DEFAULT
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
LABEL local_override
|
||||||
|
MENU LABEL Local ^Boot
|
||||||
|
localboot 0
|
||||||
|
TEXT HELP
|
||||||
|
Boot from the local system instead.
|
||||||
|
ENDTEXT
|
||||||
|
|
||||||
|
LABEL reboot
|
||||||
|
MENU LABEL ^Reboot
|
||||||
|
COM32 reboot.c32
|
||||||
|
TEXT HELP
|
||||||
|
Reboot the machine
|
||||||
|
ENDTEXT
|
||||||
|
|
||||||
|
MENU SEPARATOR
|
||||||
|
|
||||||
|
## 64 BIT
|
||||||
|
MENU BEGIN 64BIT
|
||||||
|
MENU LABEL ^1) 64-Bit ...
|
||||||
|
ONTIMEOUT ${UXNAME}_ram_64
|
||||||
|
|
||||||
|
LABEL ${UXNAME}_ram_64
|
||||||
|
MENU LABEL ^1) ${PNAME} (run from RAM) (Default)
|
||||||
|
LINUX /boot/${UXNAME}.64.kern
|
||||||
|
INITRD /boot/${UXNAME}.64.img
|
||||||
|
APPEND copytoram archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
TEXT HELP
|
||||||
|
64-bit, run from RAM
|
||||||
|
ENDTEXT
|
||||||
|
MENU DEFAULT
|
||||||
|
|
||||||
|
LABEL ${UXNAME}_64
|
||||||
|
MENU LABEL ^1) ${PNAME}
|
||||||
|
LINUX /boot/${UXNAME}.64.kern
|
||||||
|
INITRD /boot/${UXNAME}.64.img
|
||||||
|
APPEND archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
TEXT HELP
|
||||||
|
Same as the above, except run directly from the CD-
|
||||||
|
don't copy the image to RAM. (Best for lower-memory boxes)
|
||||||
|
ENDTEXT
|
||||||
|
|
||||||
|
MENU END
|
||||||
|
|
||||||
|
MENU BEGIN 32BIT
|
||||||
|
MENU LABEL ^2) 32-Bit ...
|
||||||
|
ONTIMEOUT ${UXNAME}_ram_32
|
||||||
|
|
||||||
|
## 32 BIT
|
||||||
|
LABEL ${UXNAME}_ram_32
|
||||||
|
MENU LABEL ^1) ${PNAME} (run from RAM) (Default)
|
||||||
|
LINUX /boot/${UXNAME}.32.kern
|
||||||
|
INITRD /boot/${UXNAME}.32.img
|
||||||
|
APPEND copytoram archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
TEXT HELP
|
||||||
|
32-bit, run from RAM
|
||||||
|
ENDTEXT
|
||||||
|
MENU DEFAULT
|
||||||
|
|
||||||
|
LABEL ${UXNAME}_32
|
||||||
|
MENU LABEL ^2) ${PNAME}
|
||||||
|
LINUX /boot/${UXNAME}.32.kern
|
||||||
|
INITRD /boot/${UXNAME}.32.img
|
||||||
|
APPEND archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
TEXT HELP
|
||||||
|
Same as the above, except run directly from the CD-
|
||||||
|
don't copy the image to RAM. (Best for lower-memory boxes)
|
||||||
|
ENDTEXT
|
||||||
|
|
||||||
|
MENU END
|
||||||
|
EOF
|
||||||
|
else
|
||||||
|
## ARCH-SPECIFIC ISO
|
||||||
|
cat > ${TEMPDIR}/isolinux/isolinux.cfg << EOF
|
||||||
|
UI vesamenu.c32
|
||||||
|
DEFAULT check
|
||||||
|
PROMPT 0
|
||||||
|
TIMEOUT 50
|
||||||
|
MENU HIDDEN
|
||||||
|
ONTIMEOUT ${UXNAME}_ram_${ARCH}
|
||||||
|
MENU TABMSG Press [TAB] to edit options
|
||||||
|
#MENU TITLE ${PNAME} (ISO edition)
|
||||||
|
MENU ROWS 16
|
||||||
|
MENU TIMEOUTROW 22
|
||||||
|
MENU TABMSGROW 24
|
||||||
|
MENU CMDLINEROW 24
|
||||||
|
MENU HELPMSGROW 26
|
||||||
|
MENU WIDTH 78
|
||||||
|
MENU MARGIN 6
|
||||||
|
MENU IMMEDIATE
|
||||||
|
# http://www.colorpicker.com/
|
||||||
|
MENU color border 0 #00000000 #00000000 none
|
||||||
|
MENU color title 0 #FFF5B800 #00000000 std
|
||||||
|
MENU color sel 7;37;40 #FF000000 #FFFFFFFF all
|
||||||
|
MENU color hotsel 1;7;37;40 #FFFF0000 #FFC0C0C0 all
|
||||||
|
MENU color hotkey 1;7;37;40 #FF0000CC #FFC0C0C0 all
|
||||||
|
MENU color tabmsg 1;31;40 #FF808080 #00000000 std
|
||||||
|
MENU color help 1;31;40 #FFFFFFFF #FF000000 none
|
||||||
|
MENU color timeout_msg 0 #FFFFB300 #00000000 none
|
||||||
|
MENU color timeout 0 #FFFF0000 #FF000000 none
|
||||||
|
MENU color cmdline 0 #FFFFFFFF #FF000000 none
|
||||||
|
MENU color cmdmark 1;36;40 #C000FFFF #FF000000 std
|
||||||
|
MENU color scrollbar 30;44 #FF00FF00 #FF000000 std
|
||||||
|
MENU color msg07 0 #FF000000 #00FFFFFF none
|
||||||
|
MENU BACKGROUND /${UXNAME}.png
|
||||||
|
|
||||||
|
LABEL local_override
|
||||||
|
MENU LABEL Local ^Boot
|
||||||
|
localboot 0
|
||||||
|
TEXT HELP
|
||||||
|
Boot from the local system instead.
|
||||||
|
ENDTEXT
|
||||||
|
|
||||||
|
LABEL reboot
|
||||||
|
MENU LABEL ^Reboot
|
||||||
|
COM32 reboot.c32
|
||||||
|
TEXT HELP
|
||||||
|
Reboot the machine
|
||||||
|
ENDTEXT
|
||||||
|
|
||||||
|
MENU SEPARATOR
|
||||||
|
|
||||||
|
MENU BEGIN ${ARCH}BIT
|
||||||
|
MENU LABEL ^1) ${ARCH}-Bit ...
|
||||||
|
ONTIMEOUT ${UXNAME}_ram_${ARCH}
|
||||||
|
|
||||||
|
LABEL ${UXNAME}_ram_${ARCH}
|
||||||
|
MENU LABEL ^1) ${PNAME} (run from RAM) (Default)
|
||||||
|
LINUX /boot/${UXNAME}.${ARCH}.kern
|
||||||
|
INITRD /boot/${UXNAME}.${ARCH}.img
|
||||||
|
APPEND copytoram archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
TEXT HELP
|
||||||
|
${ARCH}-bit, run from RAM
|
||||||
|
ENDTEXT
|
||||||
|
MENU DEFAULT
|
||||||
|
|
||||||
|
LABEL ${UXNAME}_${ARCH}
|
||||||
|
MENU LABEL ^1) ${PNAME}
|
||||||
|
LINUX /boot/${UXNAME}.${ARCH}.kern
|
||||||
|
INITRD /boot/${UXNAME}.${ARCH}.img
|
||||||
|
APPEND archisobasedir=${DISTNAME} archisolabel=${DISTNAME}
|
||||||
|
TEXT HELP
|
||||||
|
Same as the above, except run directly from the CD-
|
||||||
|
don't copy the image to RAM. (Best for lower-memory boxes)
|
||||||
|
ENDTEXT
|
||||||
|
|
||||||
|
MENU END
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
stuffy
|
||||||
|
|
||||||
|
rm -f ${ISOFILENAME}
|
||||||
|
if [ "${ARCHBOOT}" != "${TEMPDIR}/${DISTNAME}" ];
|
||||||
|
then
|
||||||
|
mkdir -p ${TEMPDIR}/${DISTNAME}
|
||||||
|
rsync -a --delete ${ARCHBOOT}/. ${TEMPDIR}/${DISTNAME}/.
|
||||||
|
fi
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/isolinux.bin ${TEMPDIR}/isolinux
|
||||||
|
#cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/isolinux-debug.bin ${TEMPDIR}/isolinux/isolinux.bin #debugging
|
||||||
|
#cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/* ${TEMPDIR}/isolinux/. #debugging
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/vesamenu.c32 ${TEMPDIR}/isolinux
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/linux.c32 ${TEMPDIR}/isolinux
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/reboot.c32 ${TEMPDIR}/isolinux
|
||||||
|
if [ -f ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/ldlinux.c32 ];
|
||||||
|
then
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/ldlinux.c32 ${TEMPDIR}/isolinux
|
||||||
|
fi
|
||||||
|
if [ -f ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/libcom32.c32 ];
|
||||||
|
then
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/libcom32.c32 ${TEMPDIR}/isolinux
|
||||||
|
fi
|
||||||
|
if [ -f ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/libutil.c32 ];
|
||||||
|
then
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/libutil.c32 ${TEMPDIR}/isolinux
|
||||||
|
fi
|
||||||
|
if [ -f ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/ifcpu64.c32 ];
|
||||||
|
then
|
||||||
|
cp -af ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/ifcpu64.c32 ${TEMPDIR}/isolinux
|
||||||
|
fi
|
||||||
|
cd ${TEMPDIR}
|
||||||
|
|
||||||
|
cd ..
|
||||||
|
${RACECAR_CHK}xorriso -as mkisofs \
|
||||||
|
-quiet \
|
||||||
|
`#-joliet` \
|
||||||
|
`#-rock` \
|
||||||
|
`#-omit-version-number` \
|
||||||
|
`#-disable-deep-relocation` \
|
||||||
|
-iso-level 3 \
|
||||||
|
-full-iso9660-filenames \
|
||||||
|
-volid "${DISTNAME}" \
|
||||||
|
-appid "${DISTDESC}" \
|
||||||
|
-publisher "${DISTPUB}" \
|
||||||
|
`#-preparer "prepared by ${0}"` \
|
||||||
|
-preparer "prepared by ${DISTPUB}" \
|
||||||
|
-eltorito-boot isolinux/isolinux.bin \
|
||||||
|
-eltorito-catalog isolinux/boot.cat \
|
||||||
|
`#-isohybrid-mbr ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/isohdpfx.bin` \
|
||||||
|
-no-emul-boot \
|
||||||
|
-boot-load-size 4 \
|
||||||
|
-boot-info-table \
|
||||||
|
-isohybrid-mbr ${BASEDIR}/root.x86_64/usr/lib/syslinux/bios/isohdpfx.bin \
|
||||||
|
-eltorito-alt-boot \
|
||||||
|
-e EFI/${DISTNAME}/efiboot.img \
|
||||||
|
-no-emul-boot \
|
||||||
|
`#--efi-boot EFI/${DISTNAME}/efiboot.img` \
|
||||||
|
-isohybrid-gpt-basdat \
|
||||||
|
-output "${ISODIR}/${ISOFILENAME}" "${TEMPDIR}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
|
||||||
|
|
||||||
|
#isohybrid ${ISOFILENAME}
|
||||||
|
cd ${ISODIR}
|
||||||
|
${RACECAR_CHK}sha256sum ${ISOFILENAME} > ${ISOFILENAME}.sha256
|
||||||
|
cd ..
|
||||||
|
echo "ISO generated; size is $(ls -lh ${ISODIR}/${ISOFILENAME} | awk '{print $5}')."
|
||||||
|
echo "SHA256 sum is: $(awk '{print $1}' ${ISODIR}/${ISOFILENAME}.sha256)"
|
||||||
|
echo "You can find it at ${ISODIR}/${ISOFILENAME}"
|
||||||
|
#rm -rf ${TEMPDIR}/*
|
||||||
|
|
||||||
|
# are we rsyncing?
|
||||||
|
if [ -n "${RSYNC_HOST}" ];
|
||||||
|
then
|
||||||
|
rsync -a ${TFTPDIR}/. ${RSYNC_HOST}:${RSYNC_DEST}/tftpboot/.
|
||||||
|
rsync -a ${HTTPDIR}/. ${RSYNC_HOST}:${RSYNC_DEST}/http/.
|
||||||
|
# rsync -a ${TEMPDIR}/boot/${UXNAME}.* ${RSYNC_HOST}:${RSYNC_DEST}/http/.
|
||||||
|
rsync -a ${ISODIR}/. ${RSYNC_HOST}:${RSYNC_DEST}/iso/.
|
||||||
|
rsync -a ${ROOTDIR}/extra/. ${RSYNC_HOST}:${RSYNC_DEST}/extra/.
|
||||||
|
fi
|
||||||
|
}
|
||||||
@@ -0,0 +1,104 @@
|
|||||||
|
function mentos {
|
||||||
|
# Freshen up the chroots to git's HEAD. Package lists, overlay, etc.
|
||||||
|
sed -i -e '/base-devel/d ; /multilib-devel/d' ${BASEDIR}/extra/packages.*
|
||||||
|
# both
|
||||||
|
echo "Installing common packages..."
|
||||||
|
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.both | tr '\n' ' ')
|
||||||
|
|
||||||
|
if [ -f "/usr/bin/systemd-nspawn" ];
|
||||||
|
then
|
||||||
|
CHROOTCMD="systemd-nspawn -D"
|
||||||
|
else
|
||||||
|
CHROOTCMD="${CHROOTDIR64}/bin/arch-chroot"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${I_AM_A_RACECAR}" == "y" ]];
|
||||||
|
then
|
||||||
|
RACECAR_CHK='nice -n -19 '
|
||||||
|
else
|
||||||
|
RACECAR_CHK=""
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ -n $(find ${BASEDIR}/extra/pre-build.d/ -type f -newer ${BASEDIR}/root.x86_64/boot/vmlinuz-linux-${PNAME}) ]];
|
||||||
|
then
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
sleep 2
|
||||||
|
find ${BASEDIR}/extra/pre-build.d/ -exec touch '{}' \;
|
||||||
|
rsync -a ${BASEDIR}/extra/pre-build.d/64/. ${BASEDIR}/root.x86_64/.
|
||||||
|
rsync -a ${BASEDIR}/extra/pre-build.d/32/. ${BASEDIR}/root.i686/.
|
||||||
|
find ${BASEDIR}/root.x86_64/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
find ${BASEDIR}/root.i686/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
fi
|
||||||
|
|
||||||
|
for i in ${CHROOTDIR32} ${CHROOTDIR64};
|
||||||
|
do
|
||||||
|
echo -n "...Packages installing/upgrading to ${i}..."
|
||||||
|
local INSTKERN=$(file ${i}/boot/vmlinuz-linux-${PNAME} | awk '{print $9}' | cut -f1 -d"-")
|
||||||
|
local MIRROR=$(egrep '^Server' ${i}/etc/pacman.d/mirrorlist | head -n1 | sed -e 's/^Server\ =\ //g ; s#$repo.*#core/os/x86_64/#g')
|
||||||
|
local NEWKERN=$(curl -s "${MIRROR}" | grep linux | awk '{print $3}' | cut -f2 -d\" | egrep '^linux-[0-9].*pkg.tar.xz$' | cut -f2 -d"-")
|
||||||
|
|
||||||
|
if [[ -n $(find ${BASEDIR}/extra/pre-build.d/ -type f -newer ${BASEDIR}/root.x86_64/boot/vmlinuz-linux-${PNAME}) ]] || [[ "${INSTKERN}" != "${NEWKERN}" ]];
|
||||||
|
then
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "${RACECAR_CHK}yaourt -Syyua --noconfirm --devel" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
else
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "${RACECAR_CHK}yaourt -Syyua --noconfirm --devel --ignore linux,linux-${PNAME}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "${RACECAR_CHK}yaourt -S --needed --ignore linux,linux-${PNAME} --noconfirm ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
|
||||||
|
#${CHROOTCMD} ${i}/ bash -c "yaourt -S --needed --noconfirm ${PKGLIST}"
|
||||||
|
if [[ -n $(find ${BASEDIR}/extra/pre-build.d/ -type f -newer root.x86_64/boot/vmlinuz-linux-${PNAME}) ]];
|
||||||
|
then
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "${RACECAR_CHK}mkinitcpio -p linux-${PNAME}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
echo "Done."
|
||||||
|
done
|
||||||
|
|
||||||
|
# we need to set -e for the following as they may fail.
|
||||||
|
# 32-bit
|
||||||
|
echo "Installing packages for 32-bit..."
|
||||||
|
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.32 | tr '\n' ' ')
|
||||||
|
if [ -n "${PKGLIST}" ];
|
||||||
|
then
|
||||||
|
${CHROOTCMD} ${CHROOTDIR32}/ bash -c "yes '' | ${RACECAR_CHK}yaourt -S --needed --noconfirm ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
for x in $(find ${CHROOTDIR32}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
|
||||||
|
|
||||||
|
# 64-bit
|
||||||
|
echo "Installing packages for 64-bit..."
|
||||||
|
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.64 | tr '\n' ' ')
|
||||||
|
if [ -n "${PKGLIST}" ];
|
||||||
|
then
|
||||||
|
${CHROOTCMD} ${CHROOTDIR64}/ bash -c "${RACECAR_CHK}yaourt -S --needed --noconfirm ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
for x in $(find ${CHROOTDIR64}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
|
||||||
|
#${CHROOTCMD} ${CHROOTDIR64}/ bash -c "yaourt -S --needed --noconfirm ${PKGLIST}"
|
||||||
|
echo "Syncing overlay..."
|
||||||
|
rsync -a ${BASEDIR}/overlay/64/. ${CHROOTDIR64}/.
|
||||||
|
echo "Done."
|
||||||
|
|
||||||
|
echo "Syncing overlay..."
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
sleep 2
|
||||||
|
find ${BASEDIR}/overlay -exec touch '{}' \;
|
||||||
|
rsync -a --exclude '/32' --exclude '/64' ${BASEDIR}/overlay/. ${CHROOTDIR64}/.
|
||||||
|
rsync -a --exclude '/32' --exclude '/64' ${BASEDIR}/overlay/. ${CHROOTDIR32}/.
|
||||||
|
rsync -a ${BASEDIR}/overlay/32/. ${CHROOTDIR32}/.
|
||||||
|
rsync -a ${BASEDIR}/overlay/64/. ${CHROOTDIR64}/.
|
||||||
|
find ${CHROOTDIR64}/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
find ${CHROOTDIR32}/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
chown -R 1000:1000 ${CHROOTDIR32}/home/${REGUSR}
|
||||||
|
chown -R 1000:1000 ${CHROOTDIR64}/home/${REGUSR}
|
||||||
|
find ${CHROOTDIR64}/home/${REGUSR}/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR64}/home/${REGUSR}/ -type f -exec chmod 600 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/home/${REGUSR}/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/home/${REGUSR}/ -type f -exec chmod 600 '{}' \;
|
||||||
|
chown -R 0:0 ${CHROOTDIR32}/root
|
||||||
|
chown -R 0:0 ${CHROOTDIR64}/root
|
||||||
|
find ${CHROOTDIR64}/root/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR64}/root/ -type f -exec chmod 600 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/root/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/root/ -type f -exec chmod 600 '{}' \;
|
||||||
|
echo "Done."
|
||||||
|
|
||||||
|
}
|
||||||
Executable
+293
@@ -0,0 +1,293 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
function mkchroot {
|
||||||
|
|
||||||
|
# just in case we don't inherit.
|
||||||
|
if [[ -z "${FUNCNAME}" ]];
|
||||||
|
then
|
||||||
|
FUNCNAME='mkchroot-standalone'
|
||||||
|
fi
|
||||||
|
|
||||||
|
## Import settings
|
||||||
|
if [ -f "build.conf" ];
|
||||||
|
then
|
||||||
|
echo "Now importing settings/variables."
|
||||||
|
set -e
|
||||||
|
source build.conf
|
||||||
|
set +e
|
||||||
|
else
|
||||||
|
echo "You have not configured a build.conf OR you are not running from the project's root directory (the git repository's working directory)."
|
||||||
|
echo "If you are indeed in the correct directory, you may copy the sample at ../extra/build.conf.sample,"
|
||||||
|
echo "edit it for appropriate values, and copy to <PROJECT ROOT>/build.conf"
|
||||||
|
echo 'This error is fatal. Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ ${EUID} -ne 0 ]];
|
||||||
|
then
|
||||||
|
#echo "This script must be run as root" 1>&2
|
||||||
|
echo "This script must be run as root."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "${BASEDIR}" ];
|
||||||
|
then
|
||||||
|
echo 'You need to export the directory ("$BASEDIR") which will hold the chroots and the git project directory.'
|
||||||
|
echo "(don't worry, there's a .gitignore for the chroots)"
|
||||||
|
echo "e.g. export BASEDIR=\"/opt/dev/work/client-diag-disc/\""
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -d "${BASEDIR}" ];
|
||||||
|
then
|
||||||
|
echo "You need to make sure ${BASEDIR} is a valid, existing directory. This script does not automatically create it as a sanity measure."
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${EUID}" != "0" ]];
|
||||||
|
then
|
||||||
|
echo "This script must be run as root."
|
||||||
|
echo 'Dying.'
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f ${LOCKFILE} ];
|
||||||
|
then
|
||||||
|
echo "Script already running, stale lockfile present, or an error occurred during last run."
|
||||||
|
echo "Please clear ${LOCKFILE} by hand before attempting another build."
|
||||||
|
echo -n "Timestamp of lockfile is: "
|
||||||
|
ls -l ${LOCKFILE} | awk '{print $6" "$7" "$8}'
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f "/usr/bin/systemd-nspawn" ];
|
||||||
|
then
|
||||||
|
CHROOTCMD="systemd-nspawn -D"
|
||||||
|
else
|
||||||
|
CHROOTCMD="${CHROOTDIR64}/bin/arch-chroot"
|
||||||
|
fi
|
||||||
|
|
||||||
|
cd "${BASEDIR}"
|
||||||
|
|
||||||
|
## Set some vars.
|
||||||
|
MIRROR='http://mirrors.kernel.org/archlinux'
|
||||||
|
RLSDIR="${MIRROR}/iso/latest"
|
||||||
|
|
||||||
|
CURRLS64=$(curl -s ${RLSDIR}/sha1sums.txt | grep bootstrap | awk '{print $2}' | grep 'x86_64')
|
||||||
|
CKSUM64=$(curl -s ${RLSDIR}/sha1sums.txt | grep bootstrap | grep x86_64 | awk '{print $1}')
|
||||||
|
CURRLS32=$(curl -s ${RLSDIR}/sha1sums.txt | grep bootstrap | awk '{print $2}' | grep 'i686')
|
||||||
|
CKSUM32=$(curl -s ${RLSDIR}/sha1sums.txt | grep bootstrap | grep i686 | awk '{print $1}')
|
||||||
|
|
||||||
|
## Fetch latest tarball release
|
||||||
|
echo "Checking/fetching snapshots..."
|
||||||
|
if [ -f "latest.64.tar.gz" ];
|
||||||
|
then
|
||||||
|
LOCSUM64=$(sha1sum latest.64.tar.gz | awk '{print $1}')
|
||||||
|
if [[ "${CKSUM64}" != "${LOCSUM64}" ]];
|
||||||
|
then
|
||||||
|
echo "WARNING: CHECKSUMS DON'T MATCH."
|
||||||
|
echo "Local: ${LOCSUM64}"
|
||||||
|
echo "Remote: ${CKSUM64}"
|
||||||
|
echo "Fetching fresh copy."
|
||||||
|
curl -o latest.64.tar.gz "${RLSDIR}/${CURRLS64}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
curl -o latest.64.tar.gz "${RLSDIR}/${CURRLS64}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f "latest.32.tar.gz" ];
|
||||||
|
then
|
||||||
|
LOCSUM32=$(sha1sum latest.32.tar.gz | awk '{print $1}')
|
||||||
|
if [[ "${CKSUM32}" != "${LOCSUM32}" ]];
|
||||||
|
then
|
||||||
|
echo "WARNING: CHECKSUMS DON'T MATCH."
|
||||||
|
echo "Local: ${LOCSUM32}"
|
||||||
|
echo "Remote: ${CKSUM32}"
|
||||||
|
echo "Fetching fresh copy."
|
||||||
|
curl -o latest.32.tar.gz "${RLSDIR}/${CURRLS32}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
curl -o latest.32.tar.gz "${RLSDIR}/${CURRLS32}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -f "${CHROOTDIR32}/etc/pacman.d/gnupg/trustdb.gpg" ] || [ ! -f "${CHROOTDIR64}/etc/pacman.d/gnupg/trustdb.gpg" ];
|
||||||
|
then
|
||||||
|
# Now let's ${BASEDIR}/extract that shit
|
||||||
|
echo "Extracting snapshots. This will take a while..."
|
||||||
|
## 64-bit
|
||||||
|
tar -xpzf latest.64.tar.gz
|
||||||
|
## 32-bit
|
||||||
|
tar -xpzf latest.32.tar.gz
|
||||||
|
|
||||||
|
# And configure the package manager
|
||||||
|
echo "Configuring snapshots..."
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
sleep 2
|
||||||
|
find ${BASEDIR}/extra/pre-build.d/ -exec touch '{}' \;
|
||||||
|
rsync -a --exclude '/32' --exclude '/64' ${BASEDIR}/extra/pre-build.d/. ${BASEDIR}/root.x86_64/.
|
||||||
|
rsync -a --exclude '/32' --exclude '/64' ${BASEDIR}/extra/pre-build.d/. ${BASEDIR}/root.i686/.
|
||||||
|
rsync -a ${BASEDIR}/extra/pre-build.d/64/. ${BASEDIR}/root.x86_64/.
|
||||||
|
rsync -a ${BASEDIR}/extra/pre-build.d/32/. ${BASEDIR}/root.i686/.
|
||||||
|
chmod -f 755 ${BASEDIR}/extra/pre-build.d/{32/,64/,}etc/customizepkg.d/*
|
||||||
|
find ${BASEDIR}/root.x86_64/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
find ${BASEDIR}/root.i686/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
for i in i686 x86_64;
|
||||||
|
do
|
||||||
|
cat > ${BASEDIR}/root.${i}/etc/os-release << EOF
|
||||||
|
NAME="Arch Linux"
|
||||||
|
ID=arch
|
||||||
|
PRETTY_NAME="Arch Linux"
|
||||||
|
ANSI_COLOR="0;36"
|
||||||
|
HOME_URL="https://www.archlinux.org/"
|
||||||
|
SUPPORT_URL="https://bbs.archlinux.org/"
|
||||||
|
BUG_REPORT_URL="https://bugs.archlinux.org/"
|
||||||
|
EOF
|
||||||
|
done
|
||||||
|
|
||||||
|
# And make it usable.
|
||||||
|
echo "Initializing chroots..."
|
||||||
|
|
||||||
|
for i in ${CHROOTDIR32} ${CHROOTDIR64};
|
||||||
|
do
|
||||||
|
echo "Prepping ${i}. This will take a while..."
|
||||||
|
echo -n "...Key initializing..."
|
||||||
|
${CHROOTCMD} ${i}/ pacman-key --init >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
echo "Done."
|
||||||
|
echo -n "...Importing keys..."
|
||||||
|
${CHROOTCMD} ${i}/ pacman-key --populate archlinux >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
echo "Done."
|
||||||
|
echo -n "...Installing base packages..."
|
||||||
|
#${CHROOTCMD} ${i}/ pacstrap -dGcM base
|
||||||
|
# if that doesn't work,
|
||||||
|
|
||||||
|
${CHROOTCMD} ${i}/ pacman -Syy >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
${CHROOTCMD} ${i}/ pacman -S --noconfirm --needed base syslinux >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
echo "Done."
|
||||||
|
echo -n "...Upgrading any outdated packages..."
|
||||||
|
${CHROOTCMD} ${i}/ pacman -Syyu --noconfirm >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
echo "Done. Finishing/cleaning up..."
|
||||||
|
${CHROOTCMD} ${i}/ pacman -S --noconfirm --needed yaourt >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
${CHROOTCMD} ${i}/ pacman -S --noconfirm --needed base-devel >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
done
|
||||||
|
${CHROOTCMD} ${CHROOTDIR64}/ 'pacman --noconfirm -R gcc-libs libtool' >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
${CHROOTCMD} ${CHROOTDIR64}/ 'pacman --noconfirm -S multilib-devel' >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# preprocessing
|
||||||
|
sed -i -e '/base-devel/d ; /multilib-devel/d' ${BASEDIR}/extra/packages.*
|
||||||
|
# both
|
||||||
|
echo "Installing common packages..."
|
||||||
|
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.both | tr '\n' ' ')
|
||||||
|
for i in ${CHROOTDIR32} ${CHROOTDIR64};
|
||||||
|
do
|
||||||
|
echo -n "...Packages installing to ${i}..."
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "yaourt -S --needed --noconfirm customizepkg-scripting" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
echo -n "Compiling kernel sources..."
|
||||||
|
set +e
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "yaourt -S --needed --noconfirm linux" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
set -e
|
||||||
|
# Uncomment if you wish to use the mkpasswd binary from within the chroot...
|
||||||
|
#${CHROOTCMD} ${i}/ bash -c "yaourt -S --needed --noconfirm debian-whois-mkpasswd" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
echo -n "Regular packages..."
|
||||||
|
set +e
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "yes '' | yaourt -S --needed --noconfirm ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
for x in $(find ${i}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%%.pacorig} ; done
|
||||||
|
set -e
|
||||||
|
echo -n "...Creating ${REGUSR} user..."
|
||||||
|
${CHROOTCMD} ${i}/ useradd -m -s /bin/bash -c "Default user" ${REGUSR} >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
${CHROOTCMD} ${i}/ usermod -aG users,games,video,audio ${REGUSR} >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
${CHROOTCMD} ${i}/ passwd -d ${REGUSR} >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
mkdir -p ${i}/etc/sudoers.d ; chmod 750 ${i}/etc/sudoers.d
|
||||||
|
echo "${REGUSR} ALL=(ALL) ALL" >> ${i}/etc/sudoers.d/${REGUSR}
|
||||||
|
if [ -n "${REGUSR_PASS}" ];
|
||||||
|
then
|
||||||
|
${CHROOTCMD} ${i}/ "echo ${REGUSR}:${REGUSR_PASS} | chpasswd -e" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
else
|
||||||
|
sed -i -e "s/^${REGUSR}::/${REGUSR}:!:/g" ${i}/etc/shadow
|
||||||
|
fi
|
||||||
|
if [ -n "${ROOT_PASS}" ];
|
||||||
|
then
|
||||||
|
${CHROOTCMD} ${i}/ "echo ${root}:${ROOT_PASS} | chpasswd -e" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
else
|
||||||
|
sed -i -e 's/^root::/root:!:/g' ${i}/etc/shadow
|
||||||
|
fi
|
||||||
|
# The following is supposed to do the same as the above, but "cleaner". However, it currently fails with "execv() failed: No such file or directory"
|
||||||
|
##${CHROOTCMD} ${i}/ usermod -L root >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
echo "Done."
|
||||||
|
done
|
||||||
|
|
||||||
|
for i in ${CHROOTDIR32} ${CHROOTDIR64};
|
||||||
|
do
|
||||||
|
echo "[DEBUG] ${i}: mkinitcpio" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
${CHROOTCMD} ${i}/ bash -c "mkinitcpio -p linux-${PNAME}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
done
|
||||||
|
|
||||||
|
# 32-bit
|
||||||
|
echo "Installing packages for 32-bit..."
|
||||||
|
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.32 | tr '\n' ' ')
|
||||||
|
if [ -n "${PKGLIST}" ];
|
||||||
|
then
|
||||||
|
echo "[DEBUG] 32-bit: installing packages" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
${CHROOTCMD} ${CHROOTDIR32}/ bash -c "yaourt -S --needed --noconfirm ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
set +e
|
||||||
|
for x in $(find ${CHROOTDIR32}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
|
||||||
|
echo "[DEBUG] 32-bit: pacorig move" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
set -e
|
||||||
|
echo "Done."
|
||||||
|
|
||||||
|
# 64-bit
|
||||||
|
echo "Installing packages for 64-bit..."
|
||||||
|
PKGLIST=$(sed -e '/^[[:space:]]*#/d ; /^[[:space:]]*$/d' ${BASEDIR}/extra/packages.64 | tr '\n' ' ')
|
||||||
|
if [ -n "${PKGLIST}" ];
|
||||||
|
then
|
||||||
|
echo "[DEBUG] 64-bit: installing packages" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
${CHROOTCMD} ${CHROOTDIR64}/ bash -c "yaourt -S --needed --noconfirm ${PKGLIST}" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
fi
|
||||||
|
set +e
|
||||||
|
for x in $(find ${CHROOTDIR64}/etc/ -type f -iname "*.pacorig");do mv -f ${x} ${x%.pacorig} ; done
|
||||||
|
echo "[DEBUG] 64-bit: pacorig move" >> "${LOGFILE}.${FUNCNAME}" 2>&1
|
||||||
|
set -e
|
||||||
|
echo "Done."
|
||||||
|
|
||||||
|
echo "Syncing overlay..."
|
||||||
|
touch ${LOCKFILE}
|
||||||
|
sleep 2
|
||||||
|
find ${BASEDIR}/overlay -exec touch '{}' \;
|
||||||
|
rsync -a --exclude '/32' --exclude '/64' ${BASEDIR}/overlay/. ${CHROOTDIR64}/.
|
||||||
|
rsync -a --exclude '/32' --exclude '/64' ${BASEDIR}/overlay/. ${CHROOTDIR32}/.
|
||||||
|
rsync -a ${BASEDIR}/overlay/32/. ${CHROOTDIR32}/.
|
||||||
|
rsync -a ${BASEDIR}/overlay/64/. ${CHROOTDIR64}/.
|
||||||
|
find ${CHROOTDIR64}/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
find ${CHROOTDIR32}/ -newer ${LOCKFILE} -exec chown -R root:root '{}' \;
|
||||||
|
chown -R 1000:1000 ${CHROOTDIR32}/home/${REGUSR}
|
||||||
|
chown -R 1000:1000 ${CHROOTDIR64}/home/${REGUSR}
|
||||||
|
find ${CHROOTDIR64}/home/${REGUSR}/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR64}/home/${REGUSR}/ -type f -exec chmod 600 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/home/${REGUSR}/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/home/${REGUSR}/ -type f -exec chmod 600 '{}' \;
|
||||||
|
find ${CHROOTDIR64}/root/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR64}/root/ -type f -exec chmod 600 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/root/ -type d -exec chmod 700 '{}' \;
|
||||||
|
find ${CHROOTDIR32}/root/ -type f -exec chmod 600 '{}' \;
|
||||||
|
echo "Done."
|
||||||
|
|
||||||
|
|
||||||
|
rm -f ${LOCKFILE}
|
||||||
|
|
||||||
|
echo "Chroot setup complete."
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
mkchroot
|
||||||
@@ -1,64 +0,0 @@
|
|||||||
#
|
|
||||||
# /etc/bash.bashrc
|
|
||||||
#
|
|
||||||
|
|
||||||
# If not running interactively, don't do anything
|
|
||||||
[[ $- != *i* ]] && return
|
|
||||||
|
|
||||||
PS1='[\u@\h \W]\$ '
|
|
||||||
PS2='> '
|
|
||||||
PS3='> '
|
|
||||||
PS4='+ '
|
|
||||||
|
|
||||||
case ${TERM} in
|
|
||||||
xterm*|rxvt*|Eterm|aterm|kterm|gnome*)
|
|
||||||
PROMPT_COMMAND=${PROMPT_COMMAND:+$PROMPT_COMMAND; }'printf "\033]0;%s@%s:%s\007" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/\~}"'
|
|
||||||
|
|
||||||
;;
|
|
||||||
screen)
|
|
||||||
PROMPT_COMMAND=${PROMPT_COMMAND:+$PROMPT_COMMAND; }'printf "\033_%s@%s:%s\033\\" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/\~}"'
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
|
|
||||||
[ -r /usr/share/bash-completion/bash_completion ] && . /usr/share/bash-completion/bash_completion
|
|
||||||
|
|
||||||
alias vi='/usr/bin/vim'
|
|
||||||
export EDITOR="vim"
|
|
||||||
|
|
||||||
if [ -f ~/.bashrc ];
|
|
||||||
then
|
|
||||||
source ~/.bashrc
|
|
||||||
fi
|
|
||||||
if [ -d ~/bin ];
|
|
||||||
then
|
|
||||||
export PATH="$PATH:~/bin"
|
|
||||||
fi
|
|
||||||
|
|
||||||
alias grep='grep --color'
|
|
||||||
alias egrep='egrep --color'
|
|
||||||
|
|
||||||
alias ls='ls --color=auto'
|
|
||||||
PS1='[\u@\h \W]\$ '
|
|
||||||
|
|
||||||
export HISTTIMEFORMAT="%F %T "
|
|
||||||
export PATH="${PATH}:/sbin:/bin:/usr/sbin"
|
|
||||||
|
|
||||||
DEFROUTEIF=$(ip route show | egrep '^default' | awk '{print $5}')
|
|
||||||
|
|
||||||
echo
|
|
||||||
echo "==================================="
|
|
||||||
date
|
|
||||||
if [ -n "${DEFROUTEIF}" ];
|
|
||||||
then
|
|
||||||
IPADDR=$(ip a s dev ${DEFROUTEIF} | egrep '^[[:space:]]*inet\ ' | awk '{print $2}' | cut -f1 -d"/")
|
|
||||||
HWADDR=$(ip l show dev ${DEFROUTEIF} | egrep '^[[:space:]]*link' | awk '{print $2}')
|
|
||||||
echo
|
|
||||||
echo -n "${DEFROUTEIF} (${HWADDR}) is: ${IPADDR}"
|
|
||||||
fi
|
|
||||||
echo
|
|
||||||
echo -n "tun0 is:"
|
|
||||||
ifconfig tun0 | grep inet | grep -v "inet6" | awk '{print $2}'
|
|
||||||
echo
|
|
||||||
echo "http://bdisk.square-r00t.net/"
|
|
||||||
echo "==================================="
|
|
||||||
echo
|
|
||||||
@@ -1,54 +1,9 @@
|
|||||||
#/bin/sh -
|
#/bin/sh -
|
||||||
|
|
||||||
#chmod 4755 /opt/google/chrome-beta/chrome-sandbox
|
#chmod 4755 /opt/google/chrome-beta/chrome-sandbox
|
||||||
|
mkdir -p /var/db/sudo/lectured
|
||||||
|
touch /var/db/sudo/lectured/bdisk
|
||||||
|
chmod 700 /var/db/sudo/lectured
|
||||||
|
chgrp bdisk /var/db/sudo/lectured/bdisk
|
||||||
|
chmod 600 /var/db/sudo/lectured/bdisk
|
||||||
chmod 4755 /usr/bin/sudo
|
chmod 4755 /usr/bin/sudo
|
||||||
|
|
||||||
function fuck_you_gimme_net() {
|
|
||||||
IFACE=$(ifconfig -a -s | egrep -E '^((en|wl)p?|em)' | awk '{print $1}' | tr '\n' ' ' | sed -e 's/\ $//g')
|
|
||||||
for i in ${IFACE};
|
|
||||||
do
|
|
||||||
|
|
||||||
LINK_STATE=$(ethtool ${i} | egrep '^[[:space:]]*Link' | sed -re 's/^[[:space:]]*Link detected:(.*)/\1/g')
|
|
||||||
DEV=$(echo ${i} | sed -re 's/^([A-Za-z]{1}).*/\1/g' | tr '[[:upper:]]' '[[:lower:]]' )
|
|
||||||
if [ "${DEV}" == "e" ];
|
|
||||||
then
|
|
||||||
if [ "${LINK_STATE}" != "no" ];
|
|
||||||
then
|
|
||||||
DEV='ethernet-dhcp'
|
|
||||||
else
|
|
||||||
# skip disconnected ethernet
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
DEV='wireless-open'
|
|
||||||
fi
|
|
||||||
|
|
||||||
ifconfig ${i} down
|
|
||||||
cp -a /etc/netctl/examples/${DEV} /etc/netctl/${i}
|
|
||||||
sed -i -re "s/^([[:space:]]*Interface[[:space:]]*=).*/\1${i}/g" /etc/netctl/${i}
|
|
||||||
if [ "${DEV}" == "wireless-open" ];
|
|
||||||
then
|
|
||||||
ifconfig ${i} up && \
|
|
||||||
ESSID=$(iwlist ${i} scanning | egrep -A5 -B5 '^[[:space:]]*Encryption key:off' | egrep '^[[:space:]]*ESSID:' | sed -re 's/^[[:space:]]*ESSID:(.*)/\1/g')
|
|
||||||
sed -i -re "s/^([[:space:]]*ESSID[[:space:]]*=).*/\1${ESSID}/g" /etc/netctl/${i}
|
|
||||||
ifconfig ${i} down
|
|
||||||
fi
|
|
||||||
netctl restart ${i} > /dev/null 2>&1
|
|
||||||
#cat /etc/resolvconf.conf.failover > /etc/resolvconf.conf
|
|
||||||
#resolvconf -u
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
ping -c1 google.com | grep -q '1 received'
|
|
||||||
if [[ "${?}" != "0" ]];
|
|
||||||
then
|
|
||||||
fuck_you_gimme_net
|
|
||||||
systemctl restart openvpn@*
|
|
||||||
fi
|
|
||||||
|
|
||||||
# And lastly, do we need to set custom DNS servers?
|
|
||||||
host -s -W1 bdisk.square-r00t.net | egrep -q '^bdisk\.square-r00t\.net\ has\ address'
|
|
||||||
if [[ "${?}" != "0" ]];
|
|
||||||
then
|
|
||||||
resolvconf -u
|
|
||||||
fi
|
|
||||||
|
|||||||
@@ -0,0 +1 @@
|
|||||||
|
/usr/lib/systemd/system/openvpn@.service
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
" All system-wide defaults are set in $VIMRUNTIME/archlinux.vim (usually just
|
|
||||||
" /usr/share/vim/vimfiles/archlinux.vim) and sourced by the call to :runtime
|
|
||||||
" you can find below. If you wish to change any of those settings, you should
|
|
||||||
" do it in this file (/etc/vimrc), since archlinux.vim will be overwritten
|
|
||||||
" everytime an upgrade of the vim packages is performed. It is recommended to
|
|
||||||
" make changes after sourcing archlinux.vim since it alters the value of the
|
|
||||||
" 'compatible' option.
|
|
||||||
|
|
||||||
" This line should not be removed as it ensures that various options are
|
|
||||||
" properly set to work with the Vim-related packages.
|
|
||||||
runtime! archlinux.vim
|
|
||||||
|
|
||||||
" If you prefer the old-style vim functionalty, add 'runtime! vimrc_example.vim'
|
|
||||||
" Or better yet, read /usr/share/vim/vim74/vimrc_example.vim or the vim manual
|
|
||||||
" and configure vim to your own liking!
|
|
||||||
|
|
||||||
set number
|
|
||||||
syntax on
|
|
||||||
set paste
|
|
||||||
if has("autocmd")
|
|
||||||
au BufReadPost * if line("'\"") > 1 && line("'\"") <= line("$") | exe "normal! g'\"" | endif
|
|
||||||
endif
|
|
||||||
-1
Submodule src/ipxe deleted from 0a4805bf94
@@ -1,10 +0,0 @@
|
|||||||
## Enable IPv6 support
|
|
||||||
s/^#undef([[:space:]]*NET_PROTO_IPV6)/#define\1/g
|
|
||||||
## Enable HTTPS
|
|
||||||
s/^#undef([[:space:]]*DOWNLOAD_PROTO_HTTPS)/#define\1/g
|
|
||||||
s@^//(#define[[:space:]]*IMAGE_TRUST_CMD@\1@g
|
|
||||||
## Enable FTP
|
|
||||||
s/^#undef([[:space:]]*DOWNLOAD_PROTO_FTP)/#define\1/g
|
|
||||||
## Currently broken for EFI building
|
|
||||||
#s@^//(#define[[:space:]]*CONSOLE_CMD)@\1@g
|
|
||||||
#s@^//(#define[[:space:]]*IMAGE_PNG@\1@g
|
|
||||||
@@ -1,2 +0,0 @@
|
|||||||
## Currently broken on EFI systems
|
|
||||||
#s@^//(#define[[:space:]]*CONSOLE_VESAFB)@\1@g
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
#!ipxe
|
|
||||||
|
|
||||||
dhcp
|
|
||||||
## TODO: signed kernel and initrd
|
|
||||||
#imgtrust --permanent
|
|
||||||
#imgverify vmlinuz path/to/vmlinuz.sig
|
|
||||||
#imgverify initrd path/to/initrd.sig
|
|
||||||
chain https://bdisk.square-r00t.net
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
Thanks to "eworm" for his work on the AUR iPXE-git package:
|
|
||||||
https://aur.archlinux.org/packages/ipxe-git/
|
|
||||||
|
|
||||||
and specifically the following patches:
|
|
||||||
http://www.eworm.de/download/linux/ipxe-0001-git-version.patch
|
|
||||||
http://www.eworm.de/download/linux/ipxe-0002-banner.patch
|
|
||||||
http://www.eworm.de/download/linux/ipxe-0003-iso-efi.patch
|
|
||||||
http://www.eworm.de/download/linux/ipxe-0004-fix-no-pie-workaround.patch
|
|
||||||
@@ -1,32 +0,0 @@
|
|||||||
From 4c139ece028b5dd6c4e5f46ce2bf8134c390de90 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Christian Hesse <mail@eworm.de>
|
|
||||||
Date: Thu, 12 Feb 2015 08:59:37 +0100
|
|
||||||
Subject: [PATCH] git version
|
|
||||||
|
|
||||||
Signed-off-by: Christian Hesse <mail@eworm.de>
|
|
||||||
---
|
|
||||||
src/Makefile | 7 ++++---
|
|
||||||
1 file changed, 4 insertions(+), 3 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/Makefile b/src/Makefile
|
|
||||||
index cf9cfd2..38ebb3d 100644
|
|
||||||
--- a/src/Makefile
|
|
||||||
+++ b/src/Makefile
|
|
||||||
@@ -194,10 +194,11 @@ VERSION_MINOR = 0
|
|
||||||
VERSION_PATCH = 0
|
|
||||||
EXTRAVERSION = +
|
|
||||||
MM_VERSION = $(VERSION_MAJOR).$(VERSION_MINOR)
|
|
||||||
-VERSION = $(MM_VERSION).$(VERSION_PATCH)$(EXTRAVERSION)
|
|
||||||
ifneq ($(wildcard ../.git),)
|
|
||||||
-GITVERSION := $(shell git describe --always --abbrev=1 --match "" 2>/dev/null)
|
|
||||||
-VERSION += ($(GITVERSION))
|
|
||||||
+GITVERSION := $(shell git describe --tags --long 2>/dev/null)
|
|
||||||
+VERSION = $(GITVERSION)
|
|
||||||
+else
|
|
||||||
+VERSION = $(MM_VERSION).$(VERSION_PATCH)$(EXTRAVERSION)
|
|
||||||
endif
|
|
||||||
version :
|
|
||||||
@$(ECHO) "$(VERSION)"
|
|
||||||
--
|
|
||||||
2.3.0
|
|
||||||
|
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
--- a/src/usr/autoboot.c 2015-06-29 04:18:17.055394598 -0400
|
|
||||||
+++ b/src/usr/autoboot.c 2015-06-29 22:04:28.692916217 -0400
|
|
||||||
@@ -71,6 +71,7 @@
|
|
||||||
#define NORMAL "\033[0m"
|
|
||||||
#define BOLD "\033[1m"
|
|
||||||
#define CYAN "\033[36m"
|
|
||||||
+#define BLUE "\033[34m"
|
|
||||||
|
|
||||||
/** The "scriptlet" setting */
|
|
||||||
const struct setting scriptlet_setting __setting ( SETTING_MISC, scriptlet ) = {
|
|
||||||
@@ -560,9 +561,9 @@
|
|
||||||
* do so.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
- printf ( NORMAL "\n\n" PRODUCT_NAME "\n" BOLD PRODUCT_SHORT_NAME " %s"
|
|
||||||
- NORMAL " -- " PRODUCT_TAG_LINE " -- "
|
|
||||||
- CYAN PRODUCT_URI NORMAL "\nFeatures:", product_version );
|
|
||||||
+ printf ( NORMAL "\n\n" PRODUCT_NAME "\n" BOLD PRODUCT_SHORT_NAME
|
|
||||||
+ CYAN PRODUCT_URI NORMAL "\n"
|
|
||||||
+ BOLD BLUE "http://bdisk.square-r00t.net/" NORMAL "\n" );
|
|
||||||
for_each_table_entry ( feature, FEATURES )
|
|
||||||
printf ( " %s", feature->name );
|
|
||||||
printf ( "\n" );
|
|
||||||
@@ -1,125 +0,0 @@
|
|||||||
From d2092664b3cf866b2ab338fe056149d3266d0acc Mon Sep 17 00:00:00 2001
|
|
||||||
From: Christian Hesse <mail@eworm.de>
|
|
||||||
Date: Sun, 19 Apr 2015 13:16:09 +0200
|
|
||||||
Subject: [PATCH 1/1] allow to build ISO image with EFI support (ipxe.eiso)
|
|
||||||
|
|
||||||
Signed-off-by: Christian Hesse <mail@eworm.de>
|
|
||||||
---
|
|
||||||
src/arch/i386/Makefile.pcbios | 6 +++++
|
|
||||||
src/util/geniso | 52 +++++++++++++++++++++++++++++++++----------
|
|
||||||
2 files changed, 46 insertions(+), 12 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/arch/i386/Makefile.pcbios b/src/arch/i386/Makefile.pcbios
|
|
||||||
index ff82373..c7a58eb 100644
|
|
||||||
--- a/src/arch/i386/Makefile.pcbios
|
|
||||||
+++ b/src/arch/i386/Makefile.pcbios
|
|
||||||
@@ -59,6 +59,12 @@ NON_AUTO_MEDIA += iso
|
|
||||||
$(QM)$(ECHO) " [GENISO] $@"
|
|
||||||
$(Q)ISOLINUX_BIN=$(ISOLINUX_BIN) VERSION="$(VERSION)" bash util/geniso -o $@ $<
|
|
||||||
|
|
||||||
+# rule to make a non-emulation ISO boot image with EFI support
|
|
||||||
+NON_AUTO_MEDIA += eiso
|
|
||||||
+%eiso: %lkrn bin-i386-efi/ipxe.efi bin-x86_64-efi/ipxe.efi util/geniso
|
|
||||||
+ $(QM)$(ECHO) " [GENISO] $@"
|
|
||||||
+ $(Q)ISOLINUX_BIN=$(ISOLINUX_BIN) VERSION="$(VERSION)" bash util/geniso -e -o $@ $<
|
|
||||||
+
|
|
||||||
# rule to make a floppy emulation ISO boot image
|
|
||||||
NON_AUTO_MEDIA += liso
|
|
||||||
%liso: %lkrn util/geniso
|
|
||||||
diff --git a/src/util/geniso b/src/util/geniso
|
|
||||||
index 521c929..9e8588c 100755
|
|
||||||
--- a/src/util/geniso
|
|
||||||
+++ b/src/util/geniso
|
|
||||||
@@ -6,16 +6,21 @@ function help() {
|
|
||||||
echo "usage: ${0} [OPTIONS] foo.lkrn [bar.lkrn,...]"
|
|
||||||
echo
|
|
||||||
echo "where OPTIONS are:"
|
|
||||||
+ echo " -e build image with EFI support"
|
|
||||||
echo " -h show this help"
|
|
||||||
echo " -l build legacy image with floppy emulation"
|
|
||||||
echo " -o FILE save iso image to file"
|
|
||||||
}
|
|
||||||
|
|
||||||
+EFI=0
|
|
||||||
LEGACY=0
|
|
||||||
FIRST=""
|
|
||||||
|
|
||||||
-while getopts "hlo:" opt; do
|
|
||||||
+while getopts "ehlo:" opt; do
|
|
||||||
case ${opt} in
|
|
||||||
+ e)
|
|
||||||
+ EFI=1
|
|
||||||
+ ;;
|
|
||||||
h)
|
|
||||||
help
|
|
||||||
exit 0
|
|
||||||
@@ -37,17 +42,25 @@ if [ -z "${OUT}" ]; then
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
-# There should either be mkisofs or the compatible genisoimage program
|
|
||||||
-for command in genisoimage mkisofs; do
|
|
||||||
- if ${command} --version >/dev/null 2>/dev/null; then
|
|
||||||
- mkisofs=(${command})
|
|
||||||
- break
|
|
||||||
- fi
|
|
||||||
-done
|
|
||||||
-
|
|
||||||
-if [ -z "${mkisofs}" ]; then
|
|
||||||
- echo "${0}: mkisofs or genisoimage not found, please install or set PATH" >&2
|
|
||||||
+# We need xorriso (from libisoburn) for EFI support, so try that first.
|
|
||||||
+if xorriso --version >/dev/null 2>/dev/null; then
|
|
||||||
+ mkisofs=(xorriso -as mkisofs)
|
|
||||||
+elif [ ${EFI} -eq 1 ]; then
|
|
||||||
+ echo "${0}: xorriso not found, but required for EFI support. Please install." >&2
|
|
||||||
exit 1
|
|
||||||
+else
|
|
||||||
+ # fall back to mkisofs or the compatible genisoimage program
|
|
||||||
+ for command in genisoimage mkisofs; do
|
|
||||||
+ if ${command} --version >/dev/null 2>/dev/null; then
|
|
||||||
+ mkisofs=(${command})
|
|
||||||
+ break
|
|
||||||
+ fi
|
|
||||||
+ done
|
|
||||||
+
|
|
||||||
+ if [ -z "${mkisofs}" ]; then
|
|
||||||
+ echo "${0}: mkisofs or genisoimage not found, please install or set PATH" >&2
|
|
||||||
+ exit 1
|
|
||||||
+ fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
dir=$(mktemp -d bin/iso.dir.XXXXXX)
|
|
||||||
@@ -122,6 +135,21 @@ case "${LEGACY}" in
|
|
||||||
# copy isolinux bootloader
|
|
||||||
cp ${ISOLINUX_BIN} ${dir}
|
|
||||||
|
|
||||||
+ mkisofs+=(-b isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table)
|
|
||||||
+
|
|
||||||
+ if [ "${EFI}" -eq 1 ]; then
|
|
||||||
+ # generate EFI image
|
|
||||||
+ img=${dir}/efiboot.img
|
|
||||||
+
|
|
||||||
+ mformat -f 2880 -C -i ${img} ::
|
|
||||||
+ mmd -i ${img} "::/EFI"
|
|
||||||
+ mmd -i ${img} "::/EFI/BOOT"
|
|
||||||
+ mcopy -m -i ${img} bin-x86_64-efi/ipxe.efi "::EFI/BOOT/BOOTX64.EFI"
|
|
||||||
+ mcopy -m -i ${img} bin-i386-efi/ipxe.efi "::EFI/BOOT/BOOTIA32.EFI"
|
|
||||||
+
|
|
||||||
+ mkisofs+=(-eltorito-alt-boot -e efiboot.img -isohybrid-gpt-basdat -no-emul-boot)
|
|
||||||
+ fi
|
|
||||||
+
|
|
||||||
# syslinux 6.x needs a file called ldlinux.c32
|
|
||||||
LDLINUX_C32=$(dirname ${ISOLINUX_BIN})/ldlinux.c32
|
|
||||||
if [ -s ${LDLINUX_C32} ]; then
|
|
||||||
@@ -129,7 +157,7 @@ case "${LEGACY}" in
|
|
||||||
fi
|
|
||||||
|
|
||||||
# generate the iso image
|
|
||||||
- "${mkisofs[@]}" -b isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table -output ${OUT} ${dir}
|
|
||||||
+ "${mkisofs[@]}" -output ${OUT} ${dir}
|
|
||||||
|
|
||||||
# isohybrid will be used if available
|
|
||||||
if isohybrid --version >/dev/null 2>/dev/null; then
|
|
||||||
--
|
|
||||||
2.3.5
|
|
||||||
|
|
||||||
@@ -1,34 +0,0 @@
|
|||||||
From a4f7e3ba395af4cd0a706df635309d4ef837ecf8 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Christian Hesse <mail@eworm.de>
|
|
||||||
Date: Wed, 8 Apr 2015 09:51:41 +0200
|
|
||||||
Subject: [PATCH 2/2] Fix no-PIE workaround for i386 builds
|
|
||||||
|
|
||||||
This workaround did not work for my version of gcc (4.9.2 20150304) as
|
|
||||||
no option -nopie exists.
|
|
||||||
|
|
||||||
We take another way: Let's check whether or not the macro __PIE__ is defined
|
|
||||||
and add -fno-PIE if it is.
|
|
||||||
|
|
||||||
Signed-off-by: Christian Hesse <mail@eworm.de>
|
|
||||||
---
|
|
||||||
src/arch/i386/Makefile | 4 ++--
|
|
||||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/src/arch/i386/Makefile b/src/arch/i386/Makefile
|
|
||||||
index 99f8753..897081b 100644
|
|
||||||
--- a/src/arch/i386/Makefile
|
|
||||||
+++ b/src/arch/i386/Makefile
|
|
||||||
@@ -75,8 +75,8 @@ CFLAGS += -Ui386
|
|
||||||
# output on stderr instead of checking the exit status.
|
|
||||||
#
|
|
||||||
ifeq ($(CCTYPE),gcc)
|
|
||||||
-PIE_TEST = [ -z "`$(CC) -fno-PIE -nopie -x c -c /dev/null -o /dev/null 2>&1`" ]
|
|
||||||
-PIE_FLAGS := $(shell $(PIE_TEST) && $(ECHO) '-fno-PIE -nopie')
|
|
||||||
+PIE_TEST = $(CC) -dM -E - < /dev/null | grep -q '__PIE__'
|
|
||||||
+PIE_FLAGS := $(shell $(PIE_TEST) && $(ECHO) '-fno-PIE')
|
|
||||||
WORKAROUND_CFLAGS += $(PIE_FLAGS)
|
|
||||||
endif
|
|
||||||
|
|
||||||
--
|
|
||||||
2.3.5
|
|
||||||
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
[ ca ]
|
|
||||||
default_ca = ca_default
|
|
||||||
|
|
||||||
[ ca_default ]
|
|
||||||
certificate = crts/ca.crt
|
|
||||||
private_key = keys/ca.key
|
|
||||||
serial = txt/ca.srl
|
|
||||||
database = txt/ca.idx
|
|
||||||
#new_certs_dir = signed
|
|
||||||
new_certs_dir = crts
|
|
||||||
#default_md = default
|
|
||||||
default_md = sha512
|
|
||||||
policy = policy_anything
|
|
||||||
preserve = yes
|
|
||||||
default_days = 90
|
|
||||||
unique_subject = no
|
|
||||||
|
|
||||||
[ policy_anything ]
|
|
||||||
countryName = optional
|
|
||||||
stateOrProvinceName = optional
|
|
||||||
localityName = optional
|
|
||||||
organizationName = optional
|
|
||||||
organizationalUnitName = optional
|
|
||||||
commonName = optional
|
|
||||||
emailAddress = optional
|
|
||||||
|
|
||||||
[ cross ]
|
|
||||||
basicConstraints = critical,CA:true
|
|
||||||
keyUsage = critical,cRLSign,keyCertSign
|
|
||||||
|
|
||||||
[ codesigning ]
|
|
||||||
keyUsage = digitalSignature
|
|
||||||
extendedKeyUsage = codeSigning
|
|
||||||
Reference in New Issue
Block a user