Jump to content
Micky1979

Build_Clover.command, another Script to build standard Clover (or customized)

2,126 posts in this topic

Recommended Posts

Awesome, thank you! One additional feature/option I'd like to see is to force it to update everything first, then run a build, which is how I currently have it setup, by simply enabling both UPDATE_FLAG=YES and BUILD_FLAG=YES.

This way it's easy to build an always up to date version, but again entirely non-interactively.

Yes, with both UPDATE_FLAG and BUILD_FLAG, set to YES, the script will always try to update the Clover (and edk2, if there's a new recommended version) source before building it. In addition, I've added the ForceEDK2Update option to the config, which set to non-zero, will force the edk2 source update and rebuild the edk2 Basetools.

Share this post


Link to post
Share on other sites
Advertisement
It seems that the current script is always designed to only receive the latest version.

Can not you get a specific revision?

Currently, there is only a way to temporarily build a specific version by putting it into the Clover folder.

If you insert the revision file, the script will not correctly recognize the revision.

 

EDIT1.

this SUGGESTED_CLOVER_REV is solution.

 

thanks

Share this post


Link to post
Share on other sites

Hi,

 

 I add any theme manually in CloverV2/Themespkg. After compile, there are  this extension "_title". Can you explain why? Please.

post-1110743-0-55935800-1511418931_thumb.png

Share this post


Link to post
Share on other sites

That's probably something with the buildpkg.sh script, not with this one. Will take a look into it, when I find some time.

Thanks

Share this post


Link to post
Share on other sites

is there a possibility since your script can add APFS to clover that the script can have an option to run this script http://www.insanelymac.com/forum/topic/327584-apfsefi-without-verbose-boot/?p=2532527to quite apfs verbosity on the transferred to clover folder apfs file.

 

Can be done... but the "patch" as is, is not dynamic... I mean "looks like it works".... until now (APFS.efi from latest 10.13.2 beta bla-bla-bla)... can we be sure about this for the next releases?

 

Other way (not automatic way) is patch it before the package process...

 

ErmaC

Share this post


Link to post
Share on other sites

I figured it could be optional not automatic something we can trigger from BuildCloverConfig.txt but yeah I see your point it would have to probably parse apfs kext version to known working versions as it might not be a "fix for all" it's your script you would know better then I :)

Share this post


Link to post
Share on other sites

I figured it could be optional not automatic something we can trigger from BuildCloverConfig.txt

 

Anyway could be a good options... let's see what other say..

 

ErmaC

Share this post


Link to post
Share on other sites

Just updated the script. It now supports those changes. To ensure you have the latest nasm binary, just remove the current one with

rm -f ~/src/opt/local/bin/nasm

To ensure you have the GCC7 toolchain, it's recommended to remove the following two folders:

~/src/opt

~/src/tools

Note that you should set the toolchain as default (Build_Tool=GNU in BuildCloverConfig.txt) in order to download and build it.

I've also merged the other changes from the work branch such as the non-interactive mode, so it's recommended to remove your settings file and let the script create a new one.

Share this post


Link to post
Share on other sites

Just updated the script. It now supports those changes. To ensure you have the latest nasm binary, just remove the current one with

rm -f ~/src/opt/local/bin/nasm

To ensure you have the GCC7 toolchain, it's recommended to remove the following two folders:

~/src/opt

~/src/tools

Note that you should set the toolchain as default (Build_Tool=GNU in BuildCloverConfig.txt) in order to download and build it.

I've also merged the other changes from the work branch such as the non-interactive mode, so it's recommended to remove your settings file and let the script create a new one.

Thanks a lot

Share this post


Link to post
Share on other sites

Since lately i'm having trouble to build Clover, it ends with following

 

 

build.py...

/Users/Xabbu/src/edk2/MdePkg/Library/BaseLib/BaseLib.inf(452): error 000E: File/directory not found in workspace

/Users/Xabbu/src/edk2/MdePkg/Library/BaseLib/X64/WriteTr.nasm

 

 

- Failed -

Build end time: 19:00:32, Dec.11 2017

Build total time: 00:00:03

 

 

 

o_Ops, ./ebuild.sh exited with error(s), aborting.

 

can anyone shed some light plz ?!

 

EDIT: SOLVED

Share this post


Link to post
Share on other sites

Sorry for asking;

I read as noted by the script, it requires at least 16.04 for Ubuntu version, but I've installed Ubuntu 17.10 on my mach.

I then tried to run the script and get these:

BOOTX64.efi && CLOVERX64.efi @1,1KB (instead of 7xxKB if using Ubuntu 16.04 or XCode toolchain under macOS).

(I also remember that on prev 16.04 the script forced to use gcc53 as buildtool, as same as on 17.10 which is gcc72)

 

Any idea to make the script becomes compatible under Ubuntu 17.10? Thanks.  :)

Well, the good news is now Build_Clover script v4.6.1, EDK2 r25909 with Ubuntu 17.10 x64 (kernel: 4.13.0-19) is able to build Clover and no longer get 1KB *.efi. Considering this Ubuntu version for a compatible OS?

 

I have a question; is it normal that GCC built produces smaller boot binary and *.efi compared to XCode does?

Thanks for your great efforts.

r4359_GCC72_Ub1710.zip

Built_r4359_GCC72_Ub17.10_EDK25909.txt.zip

preboot.log_a43sj_10.13.3_r4359.txt.zip

Share this post


Link to post
Share on other sites

Sorry, but with latest Build_Clover script v4.6.2 i get the following error when building with XCode 9.2:

Attempting to detect HOST_ARCH from 'uname -m': x86_64
Detected HOST_ARCH of X64 using uname.
mkdir -p .
make -C Common
gcc  -c -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror -Wno-deprecated-declarations -Wno-self-assign -Wno-unused-result -nostdlib -c -g  -I .. -I ../Include/Common -I ../Include/ -I ../Include/IndustryStandard -I ../Common/ -I .. -I . -I ../Include/X64/  -O2 PcdValueCommon.c -o PcdValueCommon.o
PcdValueCommon.c:270:47: error: format specifies type 'unsigned long' but the argument has
      type 'UINT64' (aka 'unsigned long long') [-Werror,-Wformat]
    sprintf(PcdList[Index].Value, "0x%016lx", Value);
                                     ~~~~~~   ^~~~~
                                     %016llx
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/secure/_stdio.h:47:56: note: 
      expanded from macro 'sprintf'
  __builtin___sprintf_chk (str, 0, __darwin_obsz(str), __VA_ARGS__)
                                                       ^~~~~~~~~~~
1 error generated.
make[2]: *** [PcdValueCommon.o] Error 1
make[1]: *** [Common] Error 2
make: *** [Source/C] Error 2

o_Ops, ./ebuild.sh exited with error(s), aborting..

any help is appreciated. Thx. in advance

 

PS: maybe i have to mention the following:

================================================================================
Build_Clover script v4.6.2                                  No update available.
                             <--------------------------------------------------
================================================================================
By Micky1979 based on Slice, Zenith432, STLVNUB, JrCs, cecekpawon, Needy,
cvad, Rehabman, philip_petev, ErmaC

Supported OSes: macOS X, Ubuntu (16.04/16.10), Debian Jessie and Stretch
                             <--------------------------------------------------
CLOVER	Remote revision: 4360	Local revision: 4360
EDK2	Remote revision: 26006	Local revision: 26006

The current local EDK2 revision is the suggested one (26006). 
Used settings: /Users/md/BuildCloverConfig.txt 

Share this post


Link to post
Share on other sites

PS: maybe i have to mention the following:

================================================================================
Build_Clover script v4.6.2                                  No update available.
                             <--------------------------------------------------
================================================================================
By Micky1979 based on Slice, Zenith432, STLVNUB, JrCs, cecekpawon, Needy,
cvad, Rehabman, philip_petev, ErmaC

Supported OSes: macOS X, Ubuntu (16.04/16.10), Debian Jessie and Stretch
                             <--------------------------------------------------
CLOVER	Remote revision: 4360	Local revision: 4360
EDK2	Remote revision: 26006	Local revision: 26006

The current local EDK2 revision is the suggested one (26006). 
Used settings: /Users/md/BuildCloverConfig.txt 

Already try to restore the suggested EDK2 revision? 25909 (for 4.6.2)

 

ErmaC

Share this post


Link to post
Share on other sites

Hi all and Merry Christmas holidays to all.

Two days ago I see a new option show up about clover configurator pro, so I decide to take a look, really good. Anyone knows how to contact Mickey1979?

As a developer I'm interested in its job about that plist editor, but I notice only now is marked as retired and did not even read my private message (email nowhere  :mad: ). Let me know in pm, thanks and sorry for the OT.

Share this post


Link to post
Share on other sites

Hi all and Merry Christmas holidays to all.

Two days ago I see a new option show up about clover configurator pro, so I decide to take a look, really good. Anyone knows how to contact Mickey1979?

As a developer I'm interested in its job about that plist editor, but I notice only now is marked as retired and did not even read my private message (email nowhere  :mad: ). Let me know in pm, thanks and sorry for the OT.

 

You can contact him throw github...

https://github.com/Micky1979

 

ErmaC

Share this post


Link to post
Share on other sites

Sorry, but with latest Build_Clover script v4.6.2 i get the following error when building with XCode 9.2:

 

 

Attempting to detect HOST_ARCH from 'uname -m': x86_64
Detected HOST_ARCH of X64 using uname.
mkdir -p .
make -C Common
gcc  -c -MD -fshort-wchar -fno-strict-aliasing -Wall -Werror -Wno-deprecated-declarations -Wno-self-assign -Wno-unused-result -nostdlib -c -g  -I .. -I ../Include/Common -I ../Include/ -I ../Include/IndustryStandard -I ../Common/ -I .. -I . -I ../Include/X64/  -O2 PcdValueCommon.c -o PcdValueCommon.o
PcdValueCommon.c:270:47: error: format specifies type 'unsigned long' but the argument has
      type 'UINT64' (aka 'unsigned long long') [-Werror,-Wformat]
    sprintf(PcdList[Index].Value, "0x%016lx", Value);
                                     ~~~~~~   ^~~~~
                                     %016llx
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/secure/_stdio.h:47:56: note: 
      expanded from macro 'sprintf'
  __builtin___sprintf_chk (str, 0, __darwin_obsz(str), __VA_ARGS__)
                                                       ^~~~~~~~~~~
1 error generated.
make[2]: *** [PcdValueCommon.o] Error 1
make[1]: *** [Common] Error 2
make: *** [Source/C] Error 2

o_Ops, ./ebuild.sh exited with error(s), aborting..

 

 

 

Also confirmed by me, I can't build new BaseTools with latest edk revision atm.

Share this post


Link to post
Share on other sites

This issue was introduced in edk2 r25984 and I'm pretty sure it has something to do with lines 269-273 in edk2/BaseTools/Source/C/Common/PcdValueCommon.c:

#ifdef __GNUC__
    sprintf(PcdList[Index].Value, "0x%016lx", Value);
#else
    sprintf(PcdList[Index].Value, "0x%016llx", Value);
#endif

Whatever defines that GNUC macro, it also breaks the Basetools build. Enforcing the "else" part solves (maybe?!?) the build problem.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By STLVNUB
      Script file to clone Clover, Opencore (official and unofficial) repos
      Script will create link to itself in /usr/local/bin/bob
      Wouldn't hurt to check there are no "Bob"'s there, i "Hope" there isn't.
      Then you only need to type bob. and a parameter
      "n" for NDK repo, unofficial
      "a" for ACID repo, official
      "c" for CLOVER
      It also takes "all" for ALL, if your game
       
      Easier typing bob than.....usual stuff
      Enjoy
       
    • By TimothyF
      My PROBLEM: I followed the Plain Vanilla guide (https://hackintosh.gitbook.io/-r-hackintosh-vanilla-desktop-guide/) to a T in creating the OS X Catalina installer USB. I'm totally new to Hackintosh, and just want an Apple environment to Time Machine migrate my files and system from my ageing MacBook Pro. When I start to use the USB on the target PC (Dell Inspiron 3847 desktop), I ONLY see the Microsoft (which is the original OS, and on a SEPARATE Hard drive from where I want to install Mac OS), ZERO option for installing the OSX Catalina! Please SEE PICTURE link: https://imgur.com/a/FnLB2Q9   I'm a beginner, but I tried to google my problem. The answers were either incomplete, hard for me to understand and put into action, or were outdated and applied to older OSXs. I appreciate any help in diagnosing and solving this problem!   Clover USB specs OS installer used: Catalina (10.15) Clover revision: 5103 Kexts included: ATH9KFixup.kext AppleALC.kext Lilu.kext RealtekRTL8111.kext USBInjectAll.kext VirtualSMC.kext WhateverGreen.kext config.plist: see attached ------------------------------------------ Target Desktop specs: Dell Inspiron 3847 (64 bit) CPU: Intel Core i5-4460, 3.2 GHz, 4 cores Architecture: Haswell GPU: Intel HD 4600 Motherboard: Dell 088DT1 (version A01) Chipset: Intel H81 Install method: with USB, configured with Clover, 100% following Plain Vanilla guide for Desktops RAM: 12 GB, 2 slots Hard drive for installation: SATA HDD 4TB, by HGST LAN: RTL8111/8168/8411 WLAN: AR9565 (atheros) Audio: Realtek ALC661 (not 100% sure this is correct)   ------------------------------------ Attached:
      Screenshot of Clover installer not showing the Mac OSX option
      config.plist of my installer USB
      Clover_Install_Log.txt (not sure if this is relevant)   THANK YOU VERY MUCH!     config.plist
      Clover_Install_Log.txt
    • By Simon's InsaneMac
      Hi, I'm kind of lost when scrolling to Clover Configurator, so I decided to use an EFI from the web and just configure the most basic stuff. But that sadly didn't work, im always getting the attached screen IMG_0054.HEIC (and I don't know whether all the errors are listed, as I can't scroll). 
      Anyways I thought it'd be better to do a custom setup. Can anyone give me some help with what to choose in the settings? Here's my rig:
      i7 8700k
      Asus z370-G (Rog Strix)
      gtx 1060 6gb
      samsung ssd (SATA)
      WD hard drive
       
      Your help would be much appreciated!
    • By kylon
      A big thanks to wegface for teaching me a lot of things.
       
       
      Tested on Catalina 10.15.4 and Clover EFI 5104 (Catalina Patcher)
       
      Not Working:
      - realtek sd card reader (pm me if you have a fix)
       
      Notes:
      **CPU patches are disabled, if you are using a locked BIOS you must enable them**
       
      Clover EFI:
      - Install it in UEFI Mode and change your hdd partition table to GPT.
      - You will be able to install ANY OS in EFI mode, even if this pc does not support EFI at all! (No guide available for this)
       
      You will need:
      My unlocked BIOS (OPTIONAL) (here) Latest Clover config from CCE Bank (here) (asus k53sj-kylon) Rehabman Voodoo PS2 Controller (here) acidanthera AppleALC (here) acidanthera Lilu (here) acidanthera VirtualSMC (here) acidanthera SMCBatteryManager (here) acidanthera SMCLightSensor (here) acidanthera WhateverGreen (here) Mieze Realtek RTL8111 (here)
    • By Rohan20
      Opencore is running really really slow on Catalina 10.15.4. So It was running perfectly before I put the ssdt-pnlf for enabling Brightness control. it is running really slow and I verified my config with the sanity checker and its all correct. can someone please help. I am attaching my oc folder.

       
      https://www.dropbox.com/s/drkek0eaz19ina5/OC.zip?dl=0
       
×