Jump to content

Clover General discussion


ErmaC
30,171 posts in this topic

Recommended Posts

@STLVNUB

I'm actually now in the process to migrate Clover Suite Builder to something else

https://github.com/LAbyOne/Clover-Suite-Builder-SetUp

which is most likely a merged version of Clover Suite Builder + Clover Setup

(for now i just created the page, i'm still not so sure if it's really a good idea (lol), and files will be up pretty soon)

in the meantime i'm also thinking about building a Themes Downloader with a decent GUI, but still evaluating / testing all possible ideas

so not really available

So if you ever need some advice feel free to ask, and if I can will gladly help.

  • Like 4
  • Thanks 1
Link to comment
Share on other sites

  • 3 weeks later...
42 minutes ago, Matgen84 said:

Hi @Slice

 

I build Clover with Xcode 12.4

Commit 777e573 update nasm to 2.16.01. How to update my local existing nasm 2.15.05 ? Just using buildnasm.sh, right ! Let me know, please

I think the question is to @LAbyOne

I will look.

  • Like 1
Link to comment
Share on other sites

@Matgen84

Internal build system will check if NASm version is greater then 2.12 to update to newer version.

But as you have 2.15 then no update is proposed. You should do it by yourself with the script buildnasm.sh or just download binary from nasm.org.

Or just don't bother.

  • Thanks 1
Link to comment
Share on other sites

2 hours ago, LAbyOne said:

ok

updated nasm version check on main script

will pull it in a moment

 

also is now safe to remove "isl archive" from repo I guess

I included isl archive into repo because otherwise I can't download it from usual addresses. 

If now build from scratch works then we can exclude extra file.

Link to comment
Share on other sites

3 hours ago, Slice said:

I included isl archive into repo because otherwise I can't download it from usual addresses. 

If now build from scratch works then we can exclude extra file.

Yes it does

Now get the files directly from source

Link to comment
Share on other sites

hello, is there any setting with Clover to put in the config.plist,in Platforminfo with CustomMemory under Smbios MacPro 7,1 ?

 

like memory/devices ?

 

restrictevents.kext, does not prevent the warning of the memory installation fault under clover in my config Z390

 

thanks

 

Edited by odemolay
Link to comment
Share on other sites

On 2/23/2023 at 6:57 PM, odemolay said:

hello, is there any setting with Clover to put in the config.plist,in Platforminfo with CustomMemory under Smbios MacPro 7,1 ?

 

like memory/devices ?

 

restrictevents.kext, does not prevent the warning of the memory installation fault under clover in my config Z390

 

thanks

 

But what is the problem? How it is looked? Yes clover has some setting about memory in SMBIOS section.

Link to comment
Share on other sites

ok i make myself clear, rescrictsevent.kext ddoesn't work in my case, i dont know why. 

i had custumised my config.plist opencore with the personnal settings to not use rescrictsevent.kext

but i do prefer tu use clover, so i was wondering if i can do the same in my config.plist Clover.

or if there is a special setting to make work restrictesevent with.

 

Spoiler

image.png.e16762a70a705e12d01350c885224be8.png

 

Edited by odemolay
Link to comment
Share on other sites

  • 3 weeks later...

This is probably a remedial question, so forgive my naivete.  Would anyone be able to briefly explain how CLOVER patches macOS kernel and kexts?  What I don't understand is how CLOVER is able to implement kernel and kext patches if CLOVER operates before macOS boots.  Do CLOVER kernel and kext patches operate on kernel in memory, or do they patch a cache that is stored on disk before macOS boots?  Also, are CLOVER kext patches able to patch kexts that are stored in /S/L/E and also kexts that are stored in /L/E?

 

Thank you.

Link to comment
Share on other sites

16 hours ago, deeveedee said:

This is probably a remedial question, so forgive my naivete.  Would anyone be able to briefly explain how CLOVER patches macOS kernel and kexts?  What I don't understand is how CLOVER is able to implement kernel and kext patches if CLOVER operates before macOS boots.  Do CLOVER kernel and kext patches operate on kernel in memory, or do they patch a cache that is stored on disk before macOS boots?  Also, are CLOVER kext patches able to patch kexts that are stored in /S/L/E and also kexts that are stored in /L/E?

 

Thank you.

In the older system there was prelinkedkernel downloaded into memory by boot.efi. Then boot.efi eject event ExitBootServices which catched by Clover and then Clover find the prebootkernel in memory and applies patches to it.

Since BigSur the behavior changed. Now we have KernelCollections where we should make the patches. All gratitudes for the algorithm to Vit9696. We just call OpenCore as a library and commit the patches to it.

  • Like 2
  • Thanks 1
Link to comment
Share on other sites

@Slice Thank you for the explanation.  I was trying to help someone patch HD4000 VRAM.  In "the old days" the patch was achieved by performing a binary replace in AppleIntelFramebufferCapri.kext/Contents/MacOS/AppleIntelFramebufferCapri as follows:

sudo perl -pi -e 's|\x00.{1}\x10\x07\x00\x00\x10\x07|\x00\x80\x10\x07\x00\x00\x10\x07|g' AppleIntelFramebufferCapri.kext/Contents/MacOS/AppleIntelFramebufferCapri

 

I attempted to apply the following kernel patch (to replace the edit of the raw kext), but it doesn't work:

Find: <0000100700001007>
Identifier: com.apple.driver.AppleIntelFramebufferCapri
Mask: <FF00FFFFFFFFFFFF>
Replace: <0080100700001007>

 

I am only able to make the AppleIntelFramebufferCapri patch for HD4000 by using WhateverGreen.kext and the following DeviceProperties:

framebuffer-patch-enable 1
framebuffer-unifiedmem <00000080> 

 

Do you know why the kernel patch (Find/Replace) doesn't work, the perl edit of the raw kext (and then rebuilding KextCache) does work?  It seems to me that the kernel patch should achieve the same as the perl edit.  Thank you.

Edited by deeveedee
Link to comment
Share on other sites

Yes, graphics kext can't be patched from a bootloader because they are not present in bootkernelcollection. I don't know details.

You should write a plugin for Lilu which is able patch kernel and kext when a system is already working.

Or other way, like OCLP you should patch a kext and then apply a method like OCLP to use this kext[k] in the system.

  • Thanks 1
Link to comment
Share on other sites

Hi @Slice and all

 

I would like to go to Monterey on my old ivybridge with Catalina installed. Is this possible? Of course I would like to keep Clover as my bootloader.

How do I do this, if it is possible.

 

Thanks for your help.

Link to comment
Share on other sites

40 minutes ago, deeveedee said:

@Matgen84 You should be able to use Open Core Legacy Patcher (OCLP). It should work fine with CLOVER.  See my proposed steps here.  Ivybridge/HD4000 is reported working with OCLP up to Ventura 13.2.1 (so far).

 

Thanks @deeveedee Catalina is installed on my IvyBridge (SMBIOS iMac 13,2) with a lot of software and data. I just want to upgrade to Monterey without losing anything. If I well understand, I can use the same SMBIOS, right ! 

Link to comment
Share on other sites

@Matgen84  Yes.  I would recommend that you clone your current Catalina volume to a new volume that you can play with, then keep your original Catalina volume in a safe place as you experiment with the upgrade to Monterey.

  1. Leave your CLOVER EFI SMBIOS model as iMac13,2.  
  2. Use OCLP 0.6.1 to generate an OpenCore EFI for SMBIOS iMac13,2.  
  3. Copy kernel patches, kexts and boot-args (possibly other items) from the OCLP-generated EFI to your CLOVER EFI.  You'll need to experiment to determine what elements you need to copy from the OCLP-generated EFI to your CLOVER EFI.  Note that OCLP is intended for REAL MACs ONLY, so there are elements of the OCLP-generated EFI that are intended for REAL MACS.  You do NOT want to copy everything from the OCLP-generated EFI.
  4. After you create your new "hybrid" EFI (a combination of your original CLOVER EFI with the OCLP-generate EFI), use the new hybrid EFI to boot the Monterey installer and perform an in-place upgrade of Catalina to Monterey.
  5. After you upgrade to Monterey, use OCLP to apply post-install patches.  Note that your Monterey graphics performance may be V-E-R-Y S-L-O-W until you apply OCLP post-install patches and reboot.

If you have problems upgrading directly to Monterey, try Big Sur first.  With my hack, I found it easier to upgrade first to Big Sur, but I was still dealing with bugs in OCLP that have since been resolved.  You may have no trouble upgrading directly from Catalina to Monterey.

 

Edited by deeveedee
  • Like 1
  • Thanks 1
Link to comment
Share on other sites

@deeveedee OCLP 0.6.1 can't generate an OpencoreEFI for SMBIOS iMac13,2 (on my Ivybridge Catalina-Clover rig) 😪 Of course I can create macOS Installer. Upgrade to BigSur first seems to be a good idea !

 

Spoiler

1522903171_Capturedcran2023-03-2108_21_31.png.5eb6e474dd6c4ae96cfcfd34bcdb32d0.png

 

 

 

 

Sorry for Off-Topic in Clover general discussion

Link to comment
Share on other sites

@Matgen84 You can run OCLP on any Mac or Hack and choose the target SMBIOS in Settings.  Build and Install Open Core to a USB stick on the other Mac or Hack and use it on your iMac13,2.

 

 

EDIT: @Matgen84 If you don't have another hack or mac:

  1. run OCLP
  2. open Settings
  3. Change target SMBIOS to iMac13,1
  4. Return to main menu
  5. Build Open Core to a USB stick

 

The OCLP-generated EFI for iMac13,1 should be close enough to iMac13,2 that you can get what you need.

 

 

EDIT2: If you need more help, post your questions in this thread.

Edited by deeveedee
Link to comment
Share on other sites

7 minutes ago, deeveedee said:

@Matgen84 You can run OCLP on any Mac or Hack and choose the target SMBIOS in Settings.  Build and Install Open Core to a USB stick on the other Mac or Hack and use it on your iMac13,2.

 

Thanks @deeveedee Unfortunately, I don't have another Hack 😪 to run OCLP and choose target. My old IvyBridge Desktop will stay with Catalina. Bad luck.

Link to comment
Share on other sites

Hi @Slice

I can't build latest commit (Monterey 12.6.3 / XCode 14.2) Command Lines Tools installed. Any ideas ? Please.

 

Spoiler

TOOLCHAIN_DIR: /Users/mathieu/src/opt/local
MTOC_PREFIX: /Users/mathieu/src/opt/local/bin/
NASM_PREFIX: /Users/mathieu/src/opt/local/bin/
NASM_VER: 2.16.01
Initializing workspace
recreate Conf folder
WORKSPACE: /Users/mathieu/src/Cloverbootloader
EDK_TOOLS_PATH: /Users/mathieu/src/Cloverbootloader/BaseTools
CONF_PATH: /Users/mathieu/src/Cloverbootloader/Conf
Copying $EDK_TOOLS_PATH/Conf/build_rule.template
     to /Users/mathieu/src/Cloverbootloader/Conf/build_rule.txt
Copying $EDK_TOOLS_PATH/Conf/tools_def.template
     to /Users/mathieu/src/Cloverbootloader/Conf/tools_def.txt
Copying $EDK_TOOLS_PATH/Conf/target.template
     to /Users/mathieu/src/Cloverbootloader/Conf/target.txt
Build environment: macOS-12.6.3-x86_64-i386-64bit
Build start time: 09:43:05, Mar.22 2023

WORKSPACE        = /Users/mathieu/src/Cloverbootloader
EDK_TOOLS_PATH   = /Users/mathieu/src/Cloverbootloader/BaseTools
CONF_PATH        = /Users/mathieu/src/Cloverbootloader/Conf
PYTHON_COMMAND   = python3

Processing meta-data .. done!


build.py...
 : error C0DE: Unknown fatal error when processing [/Users/mathieu/src/Cloverbootloader/OpenCorePkg/Library/OcDebugLogLibOc2Clover/OcDebugLogLibOc2Clover.inf [X64, XCODE8, RELEASE]]
    
(Please send email to devel@edk2.groups.io for help, attaching following call stack trace!)

(Python 3.11.2 on darwin) Traceback (most recent call last):
  File "/Users/mathieu/src/Cloverbootloader/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/build.py", line 1388, in _BuildPa
    RemoveDirectory(AutoGenObject.BuildDir, True)
  File "/Users/mathieu/src/Cloverbootloader/BaseTools/Source/Python/Common/Misc.py", line 443, in RemoveDirectory
    os.rmdir(Directory)
  File "/Users/mathieu/src/Cloverbootloader/BaseTools/Source/Python/Common/LongFilePathOs.py", line 33, in rmdir
    return os.rmdir(LongFilePath(path))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
OSError: [Errno 66] Directory not empty: '/Users/mathieu/src/Cloverbootloader/Build/Clover/RELEASE_XCODE8'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/mathieu/src/Cloverbootloader/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/build.py", line 2695, in Main
    MyBuild.Launch()
  File "/Users/mathieu/src/Cloverbootloader/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/build.py", line 2488, in Launch
    self._BuildPlatform()
  File "/Users/mathieu/src/Cloverbootloader/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/build.py", line 1823, in _BuildPlatform
    self._BuildPa(self.Target, Pa, FfsCommand=CmdListDict,PcdMaList=PcdMaList)
  File "/Users/mathieu/src/Cloverbootloader/BaseTools/BinWrappers/PosixLike/../../Source/Python/build/build.py", line 1389, in _BuildPa
    except WindowsError as X:
           ^^^^^^^^^^^^
NameError: name 'WindowsError' is not defined


- Failed -
 

 

 

I create a clean local repo: Error compiling cctools-949.0.1 mtoc ! Check the log /Users/mathieu/src/tools/logs/mtoc.make.log.txt. 
Anyway there is an update for cctools : https://opensource.apple.com/source/cctools/cctools -973.0.1/

 

Spoiler

Cloning into '/Users/mathieu/src/Cloverbootloader'...
Updating files:  29% (3016/10224)
Updating files:  30% (3068/10224)
Updating files:  31% (3170/10224)
Updating files:  32% (3272/10224)
Updating files:  33% (3374/10224)
Updating files:  34% (3477/10224)
Updating files:  35% (3579/10224)
Updating files:  36% (3681/10224)
Updating files:  37% (3783/10224)
Updating files:  38% (3886/10224)
Updating files:  39% (3988/10224)
Updating files:  40% (4090/10224)
Updating files:  41% (4192/10224)
Updating files:  42% (4295/10224)
Updating files:  43% (4397/10224)
Updating files:  44% (4499/10224)
Updating files:  45% (4601/10224)
Updating files:  46% (4704/10224)
Updating files:  47% (4806/10224)
Updating files:  48% (4908/10224)
Updating files:  49% (5010/10224)
Updating files:  50% (5112/10224)
Updating files:  51% (5215/10224)
Updating files:  52% (5317/10224)
Updating files:  53% (5419/10224)
Updating files:  54% (5521/10224)
Updating files:  55% (5624/10224)
Updating files:  56% (5726/10224)
Updating files:  57% (5828/10224)
Updating files:  58% (5930/10224)
Updating files:  59% (6033/10224)
Updating files:  60% (6135/10224)
Updating files:  61% (6237/10224)
Updating files:  62% (6339/10224)
Updating files:  63% (6442/10224)
Updating files:  64% (6544/10224)
Updating files:  65% (6646/10224)
Updating files:  66% (6748/10224)
Updating files:  67% (6851/10224)
Updating files:  67% (6887/10224)
Updating files:  68% (6953/10224)
Updating files:  69% (7055/10224)
Updating files:  70% (7157/10224)
Updating files:  71% (7260/10224)
Updating files:  72% (7362/10224)
Updating files:  73% (7464/10224)
Updating files:  74% (7566/10224)
Updating files:  75% (7668/10224)
Updating files:  76% (7771/10224)
Updating files:  77% (7873/10224)
Updating files:  78% (7975/10224)
Updating files:  79% (8077/10224)
Updating files:  80% (8180/10224)
Updating files:  81% (8282/10224)
Updating files:  82% (8384/10224)
Updating files:  83% (8486/10224)
Updating files:  84% (8589/10224)
Updating files:  85% (8691/10224)
Updating files:  86% (8793/10224)
Updating files:  87% (8895/10224)
Updating files:  88% (8998/10224)
Updating files:  88% (9070/10224)
Updating files:  89% (9100/10224)
Updating files:  90% (9202/10224)
Updating files:  91% (9304/10224)
Updating files:  92% (9407/10224)
Updating files:  93% (9509/10224)
Updating files:  94% (9611/10224)
Updating files:  95% (9713/10224)
Updating files:  96% (9816/10224)
Updating files:  97% (9918/10224)
Updating files:  98% (10020/10224)
Updating files:  99% (10122/10224)
Updating files: 100% (10224/10224)
Updating files: 100% (10224/10224), done.
Submodule 'OpenCorePkg' (https://github.com/CloverHackyColor/OpenCorePkg.git) registered for path 'OpenCorePkg'
Cloning into '/Users/mathieu/src/Cloverbootloader/OpenCorePkg'...
Submodule path 'OpenCorePkg': checked out 'ed2fb797dae4e7b67e6dfe5afc4c0f6375d0403f'

Status: gettext-0.21.1.tar.xz not found.
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0 9818k    0 49152    0     0  84035      0  0:01:59 --:--:--  0:01:59 84744
100 9818k  100 9818k    0     0  7412k      0  0:00:01  0:00:01 --:--:-- 7444k
- Creating new RAM disk

Initialized /dev/rdisk5 as a 300 MB case-insensitive HFS Plus volume
-  gettext-0.21.1 extract...
-  gettext-0.21.1 configure...
-  gettext-0.21.1 make...
-  gettext-0.21.1 installing...
-  gettext-0.21.1 installed in /Users/mathieu/src/opt/local

- Ejecting RAM disk
"disk5" ejected.

Status: cctools-949.0.1.tar.gz not found.
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100   257  100   257    0     0   2281      0 --:--:-- --:--:-- --:--:--  2649
- Creating new RAM disk

Initialized /dev/rdisk5 as a 300 MB case-insensitive HFS Plus volume
Unrecognized file format of '/Users/mathieu/src/tools/download/cctools-949.0.1.tar.gz'
-  cctools-949.0.1 make mtoc...
Error compiling cctools-949.0.1 mtoc ! Check the log /Users/mathieu/src/tools/logs/mtoc.make.log.txt

- Ejecting RAM disk

 

 

/mtoc.make.log.txt

(make LTO= EFITOOLS=efitools -C libstuff) && (make -C efitools)
make: *** libstuff: No such file or directory.  Stop.

 

Edited by Matgen84
Link to comment
Share on other sites

@Matgen84

When i tested Monterey on my mobo

all worked out pretty nice, using Clover as BL, in fact was the same I used for Big Sur, had to do nothing else then install the system and use same efi from BS.

i'm on Haswell (rig on 1st signature) so IvyBridge should work just fine even without OC or OCLP.

coming from Cata you should just pay attention to any possible changes needed by the quirks if any (now I can't seem to remember which were the differences if any, from one to another)

but what is sure is, it will work.

  • Like 1
Link to comment
Share on other sites

19 minutes ago, LAbyOne said:

@Matgen84

When i tested Monterey on my mobo

all worked out pretty nice, using Clover as BL, in fact was the same I used for Big Sur, had to do nothing else then install the system and use same efi from BS.

i'm on Haswell (rig on 1st signature) so IvyBridge should work just fine even without OC or OCLP.

coming from Cata you should just pay attention to any possible changes needed by the quirks if any (now I can't seem to remember which were the differences if any, from one to another)

but what is sure is, it will work.

 

For now, I tested Monterey with SMBIOS Macpro6,. With SMBIOS  iMac13,2, I can't install this OS from USB Installer (Clover). I use OCLP only to patch Intel HD4000 and Nvidia GT640. Next week, I try SMBIOS iMac13,2 on Monterey installed.

 

Do you see my previous message: I can't build latest commit (Monterey 12.6.3 / XCode 14.2) Command Lines Tools installed. Any ideas ?

Link to comment
Share on other sites

×
×
  • Create New...