#!/usr/bin/env bash # --- T2-COPYRIGHT-NOTE-BEGIN --- # T2 SDE: scripts/Bootstrap # Copyright (C) 2022 - 2023 The T2 SDE Project # # This Copyright note is generated by scripts/Create-CopyPatch, # more information can be found in the files COPYING and README. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2. # --- T2-COPYRIGHT-NOTE-END --- set -e pkg="bash zstd sed gawk" mkdir -p src SDECFG_PARALLEL_MAX="$(getconf _NPROCESSORS_ONLN)" for p in $pkg; do url=$(sed -n '/\[D\] /{ s,\[D\] [^ ]* \([^ ]*\) \([^ ]*\),\2\1, ; p; q; }' package/*/$p/$p.desc) file=${url##*/} [ ! -e src/$file ] && curl -L -C - -o src/$file.tmp "$url" && mv src/$file{.tmp,} ( cd src tar xf $file cd ${file%.tar*} [ -e configure -a ! -e Makefile ] && ./configure make -j${SDECFG_PARALLEL_MAX:-1} make install ) done mkdir -p /var/adm/flists /etc/profile.d echo "Essential bootstrap done. To finalize a minimal t2/homebrew, simply first run:" echo " scripts/Emerge-Pkg -deps=none xz coreutils findutils tar pkgconfig" echo "" echo "To use Subversion, also install:" echo " scripts/Emerge-Pkg -deps=none apr apr-util openssl utf8proc python scons serf sqlite subversion"