mirror of
https://github.com/CloverHackyColor/CloverBootloader.git
synced 2025-01-07 18:48:04 +01:00
commit
24adc10b84
@ -9,7 +9,7 @@ printf "\n\e[1m%s\e[0m\n" "Usage: $0 [flag1 flag2...]"
|
|||||||
printf "\n%s" "The (optional) exclude flags are being passed to the buildpkg.sh script, when specified."
|
printf "\n%s" "The (optional) exclude flags are being passed to the buildpkg.sh script, when specified."
|
||||||
printf "\n%s\n" "Possible flag values:"
|
printf "\n%s\n" "Possible flag values:"
|
||||||
printf "\n\e[1m%s\e[0m\t%s" "--nothemes" "Excludes the Themes subpackage."
|
printf "\n\e[1m%s\e[0m\t%s" "--nothemes" "Excludes the Themes subpackage."
|
||||||
printf "\n\e[1m%s\e[0m\t%s" "--noprefpane" "Excludes the Clover Prefpane / Clover Updater subpackage."
|
# printf "\n\e[1m%s\e[0m\t%s" "--noprefpane" "Excludes the Clover Prefpane / Clover Updater subpackage."
|
||||||
printf "\n\e[1m%s\e[0m\t\t%s" "--norc" "Excludes the RC scripts subpackage."
|
printf "\n\e[1m%s\e[0m\t\t%s" "--norc" "Excludes the RC scripts subpackage."
|
||||||
printf "\n\e[1m%s\e[0m\t%s" "--nolegacy" "Excludes the CloverEFI subpackages."
|
printf "\n\e[1m%s\e[0m\t%s" "--nolegacy" "Excludes the CloverEFI subpackages."
|
||||||
echo
|
echo
|
||||||
@ -18,7 +18,7 @@ echo
|
|||||||
while [[ $# -gt 0 ]]; do
|
while [[ $# -gt 0 ]]; do
|
||||||
case "${1}" in
|
case "${1}" in
|
||||||
--nothemes ) NOEXTRAS+=" --nothemes";;
|
--nothemes ) NOEXTRAS+=" --nothemes";;
|
||||||
--noprefpane ) NOEXTRAS+=" --noprefpane";;
|
# --noprefpane ) NOEXTRAS+=" --noprefpane";;
|
||||||
--norc ) NOEXTRAS+=" --norc";;
|
--norc ) NOEXTRAS+=" --norc";;
|
||||||
--nolegacy ) NOEXTRAS+=" --nolegacy";;
|
--nolegacy ) NOEXTRAS+=" --nolegacy";;
|
||||||
* ) printf "\e[1m%s\e[0m\n" "Invalid option: ${1} !"; usage; exit 1;;
|
* ) printf "\e[1m%s\e[0m\n" "Invalid option: ${1} !"; usage; exit 1;;
|
||||||
@ -62,13 +62,13 @@ echo "========= Translating Resources ========"
|
|||||||
# Check that XCode is install properly
|
# Check that XCode is install properly
|
||||||
xcode_path=$(/usr/bin/xcode-select --print-path 2>/dev/null)
|
xcode_path=$(/usr/bin/xcode-select --print-path 2>/dev/null)
|
||||||
if [[ -n "$xcode_path" ]]; then
|
if [[ -n "$xcode_path" ]]; then
|
||||||
# Make CloverUpdater
|
# # Make CloverUpdater
|
||||||
"${SRCROOT}"/CloverUpdater/translate_xib.sh # workaround for a bug in Xcode 10 Beta
|
# "${SRCROOT}"/CloverUpdater/translate_xib.sh # workaround for a bug in Xcode 10 Beta
|
||||||
make -C "${SRCROOT}"/CloverUpdater || exit $?
|
# make -C "${SRCROOT}"/CloverUpdater || exit $?
|
||||||
# Make CloverPrefpane
|
# # Make CloverPrefpane
|
||||||
"${SRCROOT}"/CloverPrefpane/translate_xib.sh # workaround for a bug in Xcode 10 Beta
|
# "${SRCROOT}"/CloverPrefpane/translate_xib.sh # workaround for a bug in Xcode 10 Beta
|
||||||
"${SRCROOT}"/CloverPrefpane/translate_source.sh # workaround for a bug in Xcode 10 Beta
|
# "${SRCROOT}"/CloverPrefpane/translate_source.sh # workaround for a bug in Xcode 10 Beta
|
||||||
make -C "${SRCROOT}"/CloverPrefpane || exit $?
|
# make -C "${SRCROOT}"/CloverPrefpane || exit $?
|
||||||
# Make utils
|
# Make utils
|
||||||
make -C "${SRCROOT}"/utils || exit $?
|
make -C "${SRCROOT}"/utils || exit $?
|
||||||
# temporary use ready-to-use binaries
|
# temporary use ready-to-use binaries
|
||||||
|
@ -245,11 +245,11 @@ The target volume must be a bootable OSX system volume.";
|
|||||||
"disable_sleep_proxy_client_title" = "Disable sleep proxy client";
|
"disable_sleep_proxy_client_title" = "Disable sleep proxy client";
|
||||||
"disable_sleep_proxy_client_description" = "Disable the mDNSResponder sleep proxy client service. This will prevent the system waking from sleep every hours";
|
"disable_sleep_proxy_client_description" = "Disable the mDNSResponder sleep proxy client service. This will prevent the system waking from sleep every hours";
|
||||||
|
|
||||||
// ============================================================================
|
/*// ============================================================================
|
||||||
// Clover Preference Pane
|
// Clover Preference Pane
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
"CloverPrefpane_title" = "Install Clover Preference Pane";
|
"CloverPrefpane_title" = "Install Clover Preference Pane";
|
||||||
"CloverPrefpane_description" = "Install Clover Preference Pane on target volume.
|
"CloverPrefpane_description" = "Install Clover Preference Pane on target volume.
|
||||||
Include CloverUpdater that can notify you about Clover updates.";
|
Include CloverUpdater that can notify you about Clover updates.";
|
||||||
|
*/
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
@ -155,13 +155,13 @@ fi
|
|||||||
find "$backupRootDir" -type d -maxdepth 2 -empty -print0 2>/dev/null | xargs -0 rmdir
|
find "$backupRootDir" -type d -maxdepth 2 -empty -print0 2>/dev/null | xargs -0 rmdir
|
||||||
find "$backupRootDir" -type d -maxdepth 1 -empty -print0 2>/dev/null | xargs -0 rmdir
|
find "$backupRootDir" -type d -maxdepth 1 -empty -print0 2>/dev/null | xargs -0 rmdir
|
||||||
|
|
||||||
# Remove old CloverPrefpane
|
# # Remove old CloverPrefpane
|
||||||
pkg='@CLOVER_PACKAGE_IDENTITY@.cloverprefpane'
|
# pkg='@CLOVER_PACKAGE_IDENTITY@.cloverprefpane'
|
||||||
location=$(/usr/sbin/pkgutil --volume "$DEST_VOL" --pkg-info $pkg 2>/dev/null | sed -n 's/^location: *//p')
|
# location=$(/usr/sbin/pkgutil --volume "$DEST_VOL" --pkg-info $pkg 2>/dev/null | sed -n 's/^location: *//p')
|
||||||
pkgutil --volume "$DEST_VOL" --files $pkg 2>/dev/null | \
|
# pkgutil --volume "$DEST_VOL" --files $pkg 2>/dev/null | \
|
||||||
xargs -I @@ echo "$DEST_VOL/$location/@@" | \
|
# xargs -I @@ echo "$DEST_VOL/$location/@@" | \
|
||||||
/usr/bin/grep -iE 'CloverUpdater|Clover.prefPane' | \
|
# /usr/bin/grep -iE 'CloverUpdater|Clover.prefPane' | \
|
||||||
xargs -I @@ rm -rf '@@'
|
# xargs -I @@ rm -rf '@@'
|
||||||
|
|
||||||
# Remove files of old revision.
|
# Remove files of old revision.
|
||||||
pkgs=$(/usr/sbin/pkgutil --volume "$DEST_VOL" --pkgs | /usr/bin/grep -iE '@CLOVER_PACKAGE_IDENTITY@.' | /usr/bin/grep -Ev 'ntfs|apfs|hfsplus')
|
pkgs=$(/usr/sbin/pkgutil --volume "$DEST_VOL" --pkgs | /usr/bin/grep -iE '@CLOVER_PACKAGE_IDENTITY@.' | /usr/bin/grep -Ev 'ntfs|apfs|hfsplus')
|
||||||
|
@ -26,7 +26,7 @@ printf "\n%s" "The following flags are optional and exclude options (subpackages
|
|||||||
printf "\n%s" "Possible values:"
|
printf "\n%s" "Possible values:"
|
||||||
echo
|
echo
|
||||||
printf "\n\e[1m%s\e[0m\t%s" "--nothemes" "Excludes the Themes subpackage."
|
printf "\n\e[1m%s\e[0m\t%s" "--nothemes" "Excludes the Themes subpackage."
|
||||||
printf "\n\e[1m%s\e[0m\t%s" "--noprefpane" "Excludes the Clover Prefpane / Clover Updater subpackage."
|
# printf "\n\e[1m%s\e[0m\t%s" "--noprefpane" "Excludes the Clover Prefpane / Clover Updater subpackage."
|
||||||
printf "\n\e[1m%s\e[0m\t\t%s" "--norc" "Excludes the RC scripts subpackage."
|
printf "\n\e[1m%s\e[0m\t\t%s" "--norc" "Excludes the RC scripts subpackage."
|
||||||
printf "\n\e[1m%s\e[0m\t%s\n\n" "--nolegacy" "Excludes the CloverEFI subpackages."
|
printf "\n\e[1m%s\e[0m\t%s\n\n" "--nolegacy" "Excludes the CloverEFI subpackages."
|
||||||
}
|
}
|
||||||
@ -41,7 +41,7 @@ while [[ $# -gt 0 ]]; do
|
|||||||
--symroot ) declare -r SYMROOT="${2}"; shift;; # ie. src/Clover/CloverPackage/sym
|
--symroot ) declare -r SYMROOT="${2}"; shift;; # ie. src/Clover/CloverPackage/sym
|
||||||
--builddir ) declare -r PKG_BUILD_DIR="${2}"; shift;; # ie. src/Clover/CloverPackage/sym/package
|
--builddir ) declare -r PKG_BUILD_DIR="${2}"; shift;; # ie. src/Clover/CloverPackage/sym/package
|
||||||
--nothemes ) NOEXTRAS+=", Clover Themes";;
|
--nothemes ) NOEXTRAS+=", Clover Themes";;
|
||||||
--noprefpane ) NOEXTRAS+=", Clover Prefpane/Clover Updater";;
|
# --noprefpane ) NOEXTRAS+=", Clover Prefpane/Clover Updater";;
|
||||||
--norc ) NOEXTRAS+=", RC scripts";;
|
--norc ) NOEXTRAS+=", RC scripts";;
|
||||||
--nolegacy ) NOEXTRAS+=", CloverEFI";;
|
--nolegacy ) NOEXTRAS+=", CloverEFI";;
|
||||||
* ) printf "\e[1m%s\e[0m\n" "Invalid option: ${1} !" >&2; usage; exit 1;;
|
* ) printf "\e[1m%s\e[0m\n" "Invalid option: ${1} !" >&2; usage; exit 1;;
|
||||||
@ -1456,30 +1456,30 @@ if [[ -d "${SRCROOT}"/CloverConfigPlistValidator && ${NOEXTRAS} != *"CloverConfi
|
|||||||
# End build CloverConfigPlistValidator packages
|
# End build CloverConfigPlistValidator packages
|
||||||
fi
|
fi
|
||||||
|
|
||||||
local cloverUpdaterDir="${SRCROOT}"/CloverUpdater
|
# local cloverUpdaterDir="${SRCROOT}"/CloverUpdater
|
||||||
local cloverPrefpaneDir="${SRCROOT}"/CloverPrefpane
|
# local cloverPrefpaneDir="${SRCROOT}"/CloverPrefpane
|
||||||
if [[ -x "$cloverPrefpaneDir"/build/Clover.prefPane/Contents/MacOS/Clover && ${NOEXTRAS} != *"Clover Prefpane"* ]]; then
|
# if [[ -x "$cloverPrefpaneDir"/build/Clover.prefPane/Contents/MacOS/Clover && ${NOEXTRAS} != *"Clover Prefpane"* ]]; then
|
||||||
# build CloverPrefpane package
|
# # build CloverPrefpane package
|
||||||
echo "==================== Clover Prefpane ==================="
|
# echo "==================== Clover Prefpane ==================="
|
||||||
packagesidentity="$clover_package_identity"
|
# packagesidentity="$clover_package_identity"
|
||||||
choiceId="CloverPrefpane"
|
# choiceId="CloverPrefpane"
|
||||||
packageRefId=$(getPackageRefId "${packagesidentity}" "${choiceId}")
|
# packageRefId=$(getPackageRefId "${packagesidentity}" "${choiceId}")
|
||||||
# ditto --noextattr --noqtn "$cloverUpdaterDir"/CloverUpdaterUtility.plist \
|
# # ditto --noextattr --noqtn "$cloverUpdaterDir"/CloverUpdaterUtility.plist \
|
||||||
# "${PKG_BUILD_DIR}/${choiceId}"/Root/Library/LaunchAgents/com.projectosx.Clover.Updater.plist
|
# # "${PKG_BUILD_DIR}/${choiceId}"/Root/Library/LaunchAgents/com.projectosx.Clover.Updater.plist
|
||||||
ditto --noextattr --noqtn "$cloverUpdaterDir"/CloverUpdaterUtility \
|
# ditto --noextattr --noqtn "$cloverUpdaterDir"/CloverUpdaterUtility \
|
||||||
"${PKG_BUILD_DIR}/${choiceId}/Root/Library/Application Support/Clover"/
|
# "${PKG_BUILD_DIR}/${choiceId}/Root/Library/Application Support/Clover"/
|
||||||
ditto --noextattr --noqtn "$cloverUpdaterDir"/build/CloverUpdater.app \
|
# ditto --noextattr --noqtn "$cloverUpdaterDir"/build/CloverUpdater.app \
|
||||||
"${PKG_BUILD_DIR}/${choiceId}/Root/Library/Application Support/Clover"/CloverUpdater.app
|
# "${PKG_BUILD_DIR}/${choiceId}/Root/Library/Application Support/Clover"/CloverUpdater.app
|
||||||
ditto --noextattr --noqtn "$cloverPrefpaneDir"/build/Clover.prefPane \
|
# ditto --noextattr --noqtn "$cloverPrefpaneDir"/build/Clover.prefPane \
|
||||||
"${PKG_BUILD_DIR}/${choiceId}/Root/Library/PreferencePanes/"/Clover.prefPane
|
# "${PKG_BUILD_DIR}/${choiceId}/Root/Library/PreferencePanes/"/Clover.prefPane
|
||||||
addTemplateScripts --pkg-rootdir="${PKG_BUILD_DIR}/${choiceId}" \
|
# addTemplateScripts --pkg-rootdir="${PKG_BUILD_DIR}/${choiceId}" \
|
||||||
--subst="INSTALLER_CHOICE=$packageRefId" MarkChoice
|
# --subst="INSTALLER_CHOICE=$packageRefId" MarkChoice
|
||||||
buildpackage "$packageRefId" "${choiceId}" "${PKG_BUILD_DIR}/${choiceId}" "/"
|
# buildpackage "$packageRefId" "${choiceId}" "${PKG_BUILD_DIR}/${choiceId}" "/"
|
||||||
addChoice --start-selected="checkFileExists('/bin/launchctl') && choicePreviouslySelected('$packageRefId')" \
|
# addChoice --start-selected="checkFileExists('/bin/launchctl') && choicePreviouslySelected('$packageRefId')" \
|
||||||
--start-enabled="checkFileExists('/bin/launchctl')" \
|
# --start-enabled="checkFileExists('/bin/launchctl')" \
|
||||||
--pkg-refs="$packageRefId" "${choiceId}"
|
# --pkg-refs="$packageRefId" "${choiceId}"
|
||||||
# end CloverUpdater package
|
# # end CloverUpdater package
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
# build post install package
|
# build post install package
|
||||||
echo "================= Post ================="
|
echo "================= Post ================="
|
||||||
|
65
buildme
65
buildme
@ -147,6 +147,28 @@ else
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
makeRelease() {
|
||||||
|
checkTools
|
||||||
|
|
||||||
|
# to force recreation of the Conf folder. You can still use a custom CONF_PATH if you don't want recreation.
|
||||||
|
rm -rf "$CLOVERROOT"/Conf
|
||||||
|
mkdir "$CLOVERROOT"/Conf
|
||||||
|
|
||||||
|
cd "${CLOVERROOT}"
|
||||||
|
if [[ -z "$WORKSPACE" ]]; then
|
||||||
|
export EDK_TOOLS_PATH="${PWD}"/BaseTools
|
||||||
|
set +u
|
||||||
|
source ./edksetup.sh BaseTools
|
||||||
|
set -u
|
||||||
|
cd "$CLOVERROOT"
|
||||||
|
WORKSPACE="${PWD}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "[BUILD CLOVER RELEASE]"
|
||||||
|
./ebuild.sh -fr -mc --no-usb -D NO_GRUB_DRIVERS_EMBEDDED -t $MYTOOLCHAIN
|
||||||
|
./ebuild.sh -fr -D NO_GRUB_DRIVERS_EMBEDDED -D LESS_DEBUG -t $MYTOOLCHAIN
|
||||||
|
}
|
||||||
|
|
||||||
buildCCPV() {
|
buildCCPV() {
|
||||||
cd "${CLOVERROOT}"/Xcode/CloverConfigPlistValidator
|
cd "${CLOVERROOT}"/Xcode/CloverConfigPlistValidator
|
||||||
make
|
make
|
||||||
@ -186,10 +208,10 @@ if [[ -x "${DIR_TOOLS}"/Scripts/build.sh ]]; then
|
|||||||
else
|
else
|
||||||
local parameter=${1:-none}
|
local parameter=${1:-none}
|
||||||
if [[ "${parameter}" == HFSPlus ]]; then
|
if [[ "${parameter}" == HFSPlus ]]; then
|
||||||
./ebuild.sh -fr -mc --no-usb -D NO_GRUB_DRIVERS_EMBEDDED -D USE_APPLE_HFSPLUS_DRIVER -t $MYTOOLCHAIN
|
#./ebuild.sh -fr -mc --no-usb -D NO_GRUB_DRIVERS_EMBEDDED -D USE_APPLE_HFSPLUS_DRIVER -t $MYTOOLCHAIN
|
||||||
./ebuild.sh -fr -D NO_GRUB_DRIVERS_EMBEDDED -D USE_APPLE_HFSPLUS_DRIVER -t $MYTOOLCHAIN
|
./ebuild.sh -fr -D NO_GRUB_DRIVERS_EMBEDDED -D USE_APPLE_HFSPLUS_DRIVER -t $MYTOOLCHAIN
|
||||||
else
|
else
|
||||||
./ebuild.sh -fr -mc --no-usb -D NO_GRUB_DRIVERS_EMBEDDED -t $MYTOOLCHAIN
|
#./ebuild.sh -fr -mc --no-usb -D NO_GRUB_DRIVERS_EMBEDDED -t $MYTOOLCHAIN
|
||||||
./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
|
||||||
@ -617,13 +639,13 @@ Please enter your choice: '
|
|||||||
options=( 'build Clover'
|
options=( 'build Clover'
|
||||||
'update Clover'
|
'update Clover'
|
||||||
'build Clover with HFSPlus'
|
'build Clover with HFSPlus'
|
||||||
'make pkg'
|
'make pkg'
|
||||||
'make app'
|
|
||||||
'make app (with Clover)'
|
|
||||||
'make iso'
|
'make iso'
|
||||||
|
'make app'
|
||||||
'build all'
|
'build all'
|
||||||
|
'make Release'
|
||||||
'test Clover'
|
'test Clover'
|
||||||
'status'
|
'check status'
|
||||||
'show diff'
|
'show diff'
|
||||||
'open CloverV2/EFI/CLOVER directory'
|
'open CloverV2/EFI/CLOVER directory'
|
||||||
'update Clover (reset changes)'
|
'update Clover (reset changes)'
|
||||||
@ -652,37 +674,44 @@ do
|
|||||||
buildPkg
|
buildPkg
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"make app")
|
|
||||||
buildApp
|
|
||||||
break
|
|
||||||
;;
|
|
||||||
"make app (with Clover)")
|
|
||||||
buildApp withV2
|
|
||||||
break
|
|
||||||
;;
|
|
||||||
"make iso")
|
"make iso")
|
||||||
buildIso
|
buildIso
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
|
"make app")
|
||||||
|
buildApp withV2
|
||||||
|
break
|
||||||
|
;;
|
||||||
|
# "make app (with Clover)")
|
||||||
|
# buildApp withV2
|
||||||
|
# break
|
||||||
|
# ;;
|
||||||
"build all")
|
"build all")
|
||||||
buildClover
|
buildClover
|
||||||
|
buildCCPV
|
||||||
|
BLC
|
||||||
|
buildPkg
|
||||||
|
buildIso
|
||||||
|
break
|
||||||
|
;;
|
||||||
|
"make Release")
|
||||||
|
makeRelease
|
||||||
buildCCPV
|
buildCCPV
|
||||||
BLC
|
BLC
|
||||||
buildPkg
|
buildPkg
|
||||||
buildIso
|
buildIso
|
||||||
buildApp
|
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"test Clover")
|
"test Clover")
|
||||||
testing
|
testing
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"status")
|
"check status")
|
||||||
checkStatus
|
checkStatus
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"show diff")
|
"show diff")
|
||||||
showdiff
|
showdiff
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
"open CloverV2/EFI/CLOVER directory")
|
"open CloverV2/EFI/CLOVER directory")
|
||||||
|
Loading…
Reference in New Issue
Block a user