mirror of
https://github.com/CloverHackyColor/CloverBootloader.git
synced 2024-11-22 11:25:42 +01:00
update build system by LAbyOne
Signed-off-by: SergeySlice <sergey.slice@gmail.com>
This commit is contained in:
parent
42172b4fcc
commit
f66297ebee
@ -6,8 +6,8 @@
|
|||||||
#, fuzzy
|
#, fuzzy
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: Clover r5146\n"
|
"Project-Id-Version: Clover r5149\n"
|
||||||
"POT-Creation-Date: 2022-06-23 20:44+0300\n"
|
"POT-Creation-Date: 2022-10-17 22:07+0300\n"
|
||||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||||
|
@ -27,8 +27,8 @@ set -u # exit with error if unbound variables
|
|||||||
# GCC toolchain source version
|
# GCC toolchain source version
|
||||||
# here we can change source versions of tools
|
# here we can change source versions of tools
|
||||||
#
|
#
|
||||||
export BINUTILS_VERSION=${BINUTILS_VERSION:-binutils-2.38}
|
export BINUTILS_VERSION=${BINUTILS_VERSION:-binutils-2.39}
|
||||||
export GCC_VERSION=${GCC_VERSION:-12.1.0}
|
export GCC_VERSION=${GCC_VERSION:-12.2.0}
|
||||||
|
|
||||||
# Version of libraries are from ./contrib/download_prerequisites in gcc source directory
|
# Version of libraries are from ./contrib/download_prerequisites in gcc source directory
|
||||||
export GMP_VERSION=${GMP_VERSION:-gmp-6.2.1}
|
export GMP_VERSION=${GMP_VERSION:-gmp-6.2.1}
|
||||||
@ -360,7 +360,7 @@ CompileBinutils () {
|
|||||||
rm -rf "$BUILD_BINUTILS_DIR"
|
rm -rf "$BUILD_BINUTILS_DIR"
|
||||||
mkdir -p "$BUILD_BINUTILS_DIR" && cd "$BUILD_BINUTILS_DIR"
|
mkdir -p "$BUILD_BINUTILS_DIR" && cd "$BUILD_BINUTILS_DIR"
|
||||||
echo "- ${BINUTILS_VERSION} configure..."
|
echo "- ${BINUTILS_VERSION} configure..."
|
||||||
local cmd="LDFLAGS=\"-dead_strip\" ${BINUTILS_DIR}/configure --host=${BUILDARCH}-apple-darwin${BUILDREV} --enable-plugins --build=${BUILDARCH}-apple-darwin${BUILDREV} --target=$TARGET --prefix=$PREFIX/cross --with-included-gettext --disable-werror --with-gmp=$PREFIX --with-mpfr=$PREFIX --with-mpc=$PREFIX --with-isl=$PREFIX --disable-isl-version-check --disable-nls --enable-deterministic-archives --with-mmap --with-system-zlib"
|
local cmd="LDFLAGS=\"-dead_strip\" ${BINUTILS_DIR}/configure --host=${BUILDARCH}-apple-darwin${BUILDREV} --enable-plugins --build=${BUILDARCH}-apple-darwin${BUILDREV} --target=$TARGET --prefix=$PREFIX/cross --with-included-gettext --disable-werror --with-gmp=$PREFIX --with-mpfr=$PREFIX --with-mpc=$PREFIX --with-isl=$PREFIX --disable-isl-version-check --disable-nls --enable-deterministic-archives --with-mmap --with-system-zlib --enable-gprofng=NO"
|
||||||
local logfile="$DIR_LOGS/binutils.$ARCH.configure.log.txt"
|
local logfile="$DIR_LOGS/binutils.$ARCH.configure.log.txt"
|
||||||
echo "$cmd" > "$logfile"
|
echo "$cmd" > "$logfile"
|
||||||
eval "$cmd" >> "$logfile" 2>&1
|
eval "$cmd" >> "$logfile" 2>&1
|
||||||
|
@ -10,7 +10,7 @@ set -u
|
|||||||
# Gettext source version
|
# Gettext source version
|
||||||
# here we can change source versions of tools
|
# here we can change source versions of tools
|
||||||
#
|
#
|
||||||
export GETTEXT_VERSION=${GETTEXT_VERSION:-gettext-0.20.1}
|
export GETTEXT_VERSION=${GETTEXT_VERSION:-gettext-0.21.1}
|
||||||
|
|
||||||
# Change PREFIX if you want gettext installed on different place
|
# Change PREFIX if you want gettext installed on different place
|
||||||
#
|
#
|
||||||
@ -95,7 +95,7 @@ fnDownloadGettext ()
|
|||||||
local tarball="${GETTEXT_VERSION}.tar.xz"
|
local tarball="${GETTEXT_VERSION}.tar.xz"
|
||||||
if [[ ! -f "$tarball" ]]; then
|
if [[ ! -f "$tarball" ]]; then
|
||||||
echo "Status: $tarball not found."
|
echo "Status: $tarball not found."
|
||||||
curl -f -o download.tmp --remote-name https://ftp.gnu.org/pub/gnu/gettext/$tarball || exit 1
|
curl -k -f -o download.tmp --remote-name https://ftp.gnu.org/pub/gnu/gettext/$tarball || exit 1
|
||||||
mv download.tmp $tarball
|
mv download.tmp $tarball
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
33
buildme
33
buildme
@ -26,6 +26,8 @@ declare -r SYSNAME="$(uname)"
|
|||||||
MYTOOLCHAIN=${1:-GCC53}
|
MYTOOLCHAIN=${1:-GCC53}
|
||||||
revision=$(git describe --tags $(git rev-list --tags --max-count=1))
|
revision=$(git describe --tags $(git rev-list --tags --max-count=1))
|
||||||
lsha1="not a git repo"
|
lsha1="not a git repo"
|
||||||
|
pyversion=$(echo $COL_CYAN"Installed Python version: "$COL_WHITE$(/usr/local/bin/python3 --version))
|
||||||
|
pynone=$(echo -e "$COL_RED Python3 seems missing on this machine, it is required to build Clover ")
|
||||||
export DIR_OUT=${DIR_OUT:-"$CLOVERROOT"/toolchain/tools/output}
|
export DIR_OUT=${DIR_OUT:-"$CLOVERROOT"/toolchain/tools/output}
|
||||||
export DIR_SCT=${DIR_SCT:-${CLOVERROOT}/toolchain/tools/Scripts}
|
export DIR_SCT=${DIR_SCT:-${CLOVERROOT}/toolchain/tools/Scripts}
|
||||||
if [[ ! -d ${DIR_SCT} ]] || [[ ! -d ${DIR_OUT} ]]; then
|
if [[ ! -d ${DIR_SCT} ]] || [[ ! -d ${DIR_OUT} ]]; then
|
||||||
@ -240,7 +242,12 @@ buildClover() {
|
|||||||
./ebuild.sh -fr -D NO_GRUB_DRIVERS_EMBEDDED -D LESS_DEBUG -t $MYTOOLCHAIN
|
./ebuild.sh -fr -D NO_GRUB_DRIVERS_EMBEDDED -D LESS_DEBUG -t $MYTOOLCHAIN
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
# Run a post build script if exist (${DIR_TOOLS}/Scripts/postbuild.sh)
|
# Run a post build script if exist (${DIR_TOOLS}/CloverScripts/postbuild.sh)
|
||||||
|
if [[ -x "${DIR_TOOLS}"/CloverScripts/postbuild.sh ]]; then
|
||||||
|
echo "Running Clover postbuild script"
|
||||||
|
"${DIR_TOOLS}"/CloverScripts/postbuild.sh "${CLOVERROOT}" $MYTOOLCHAIN
|
||||||
|
fi
|
||||||
|
# Run a custom post build script if exist (${DIR_TOOLS}/Scripts/postbuild.sh)
|
||||||
if [[ -x "${DIR_TOOLS}"/Scripts/postbuild.sh ]]; then
|
if [[ -x "${DIR_TOOLS}"/Scripts/postbuild.sh ]]; then
|
||||||
echo "Running postbuild script"
|
echo "Running postbuild script"
|
||||||
"${DIR_TOOLS}"/Scripts/postbuild.sh "${CLOVERROOT}" $MYTOOLCHAIN
|
"${DIR_TOOLS}"/Scripts/postbuild.sh "${CLOVERROOT}" $MYTOOLCHAIN
|
||||||
@ -452,13 +459,13 @@ USBMap() {
|
|||||||
open $HOME/Desktop/ClovUtils
|
open $HOME/Desktop/ClovUtils
|
||||||
}
|
}
|
||||||
|
|
||||||
QtiASL() {
|
Xiasl() {
|
||||||
if [[ ! -d $HOME/Desktop/ClovUtils ]]; then
|
if [[ ! -d $HOME/Desktop/ClovUtils ]]; then
|
||||||
mkdir -p $HOME/Desktop/ClovUtils
|
mkdir -p $HOME/Desktop/ClovUtils
|
||||||
fi
|
fi
|
||||||
cd $HOME/Desktop/ClovUtils && curl -sLq https://github.com/ic005k/QtiASL/releases/download/1.1.63/Xiasl_Mac.dmg > Xiasl_Mac.dmg
|
cd $HOME/Desktop/ClovUtils && curl -sLq https://github.com/ic005k/Xiasl/releases/download/1.1.66/Xiasl_Mac.dmg > Xiasl_Mac.dmg
|
||||||
hdiutil attach -quiet -noverify -nobrowse Xiasl_Mac.dmg && cp -Rf /Volumes/bin\:release\:Xiasl/Xiasl.app $HOME/Desktop/ClovUtils
|
hdiutil attach -quiet -noverify -nobrowse Xiasl_Mac.dmg && cp -Rf /Volumes/bin\:release\:Xiasl/Xiasl.app $HOME/Desktop/ClovUtils
|
||||||
hdiutil detach -force /Volumes/bin\:release\:QtiASL
|
hdiutil detach -force /Volumes/bin\:release\:Xiasl
|
||||||
rm -r $HOME/Desktop/ClovUtils/Xiasl_Mac.dmg && open $HOME/Desktop/ClovUtils
|
rm -r $HOME/Desktop/ClovUtils/Xiasl_Mac.dmg && open $HOME/Desktop/ClovUtils
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -553,7 +560,7 @@ options=( 'Get CloverConfigPlistValidator '
|
|||||||
'Get NativeDisplayBrightness '
|
'Get NativeDisplayBrightness '
|
||||||
'Get SSDTTime'
|
'Get SSDTTime'
|
||||||
'Get USBMap'
|
'Get USBMap'
|
||||||
'Get QtiASL'
|
'Get Xiasl'
|
||||||
'Get CsrDecode'
|
'Get CsrDecode'
|
||||||
'Get gibMacOS'
|
'Get gibMacOS'
|
||||||
'Get mountR/W'
|
'Get mountR/W'
|
||||||
@ -602,8 +609,8 @@ select opt in "${options[@]}"
|
|||||||
USBMap
|
USBMap
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"Get QtiASL")
|
"Get Xiasl")
|
||||||
QtiASL
|
Xiasl
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"Get CsrDecode")
|
"Get CsrDecode")
|
||||||
@ -638,10 +645,18 @@ Utilities
|
|||||||
menu() {
|
menu() {
|
||||||
echo
|
echo
|
||||||
echo -e $COL_GREEN" ------------------------------------------------------------------------------"
|
echo -e $COL_GREEN" ------------------------------------------------------------------------------"
|
||||||
echo -e " 🍀 Clover r${revision}$COL_WHITE (SHA: $lsha1)"
|
if [[ ! -x "/usr/local/bin/pip3" ]]; then
|
||||||
|
echo -e " ${pynone}"
|
||||||
|
fi
|
||||||
|
echo -e "$COL_GREEN 🍀 Clover r${revision}$COL_WHITE (SHA: $lsha1)"
|
||||||
echo -e "$COL_CYAN TOOLCHAIN: $MYTOOLCHAIN (override example: './buildme XCODE8')"
|
echo -e "$COL_CYAN TOOLCHAIN: $MYTOOLCHAIN (override example: './buildme XCODE8')"
|
||||||
echo -e $COL_GREEN" ------------------------------------------------------------------------------"$COL_RESET
|
if [[ -x "/usr/local/bin/pip3" ]]; then
|
||||||
|
echo -e $COL_GREEN" ------------------- ${pyversion}$COL_GREEN ------------------ "$COL_RESET
|
||||||
echo -e "\n\n\n\n\n\n\n\n"
|
echo -e "\n\n\n\n\n\n\n\n"
|
||||||
|
else
|
||||||
|
echo -e $COL_GREEN" ------------------------------------------------------------------------------"$COL_RESET
|
||||||
|
echo -e "\n\n\n\n\n\n\n"
|
||||||
|
fi
|
||||||
PS3='
|
PS3='
|
||||||
Please enter your choice: '
|
Please enter your choice: '
|
||||||
options=( 'build Clover'
|
options=( 'build Clover'
|
||||||
|
Loading…
Reference in New Issue
Block a user