Jump to content
ErmaC

Clover Problems and Solutions

3,013 posts in this topic

Recommended Posts

I found one problem with -xcode5 - is that varargs were being handled by the wrong section in patched Base.h - and this was causing mayhem.  Fixed in #3429.  Now the result for -xcode5 build is that CloverGUI works when run with boot6/7 made by gcc, but boot6/7 made by xcode5 crash with a CPU exception of "undefined opcode".  I don't know how to locate the place in the code where it crashes from the register dump.  I looked at some of the map files in Build, but couldn't figure it out.

 

I can confirm that build 3430 compiles a fully working bootx64.efi binary using -clang build flag. This is a first for me so great work Zenith432! It weighs in at only 647KB as opposed to 668KB for a binary compiled with GCC 5.3. Thanks to all working hard to improve this great bootloader

Share this post


Link to post
Share on other sites
Advertisement

I can confirm that build 3430 compiles a fully working bootx64.efi binary using -clang build flag. This is a first for me so great work Zenith432! It weighs in at only 647KB as opposed to 668KB for a binary compiled with GCC 5.3. Thanks to all working hard to improve this great bootloader

It was working before. The problem always was with boot files only.

As well working Shell and OVMF compiled by clang.

Share this post


Link to post
Share on other sites

It was working before for people that don't use patched MdePkg/Include/Base.h from Patches_for_EDK2.  The relevant part is

-#elif defined(__GNUC__) && !defined(NO_BUILTIN_VA_FUNCS)
+//#elif defined(__GNUC__) && !defined(NO_BUILTIN_VA_FUNCS)
+#elif defined(__GNUC__) && !defined(__x86_64__)

For clang builds, the symbol NO_BUILTIN_VA_FUNCS is not defined in tools_def.txt, so clang would use the builtin varargs implementation (with ms abi) - and it works.  However, due to patch, the builtin varargs for x64 were only used with GCC 4.8 or above (not clang which reports 4.2.1).  This would cause clang to use the varargs implementation defined after the #else clause.  The fallback implementation after the #else is incorrect for clang in ms-abi mode, and messes up the stack.  I tried CloverGUI built with xcode together with boot7 built with gcc53 before rev #3429 - and it hung.

Share this post


Link to post
Share on other sites

It worked before 3319

--- a/Patches_for_EDK2/MdePkg/Include/Base.h
+++ b/Patches_for_EDK2/MdePkg/Include/Base.h
@@ -479,7 +479,7 @@
 #define VA_COPY(Dest, Start)          __va_copy (Dest, Start)
 
 //#elif defined(__GNUC__) && !defined(NO_BUILTIN_VA_FUNCS)
-#elif defined(__GNUC__) && !defined(__x86_64__) || __APPLE__
+#elif defined(__GNUC__) && !defined(__x86_64__)
 //
 // Use GCC built-in macros for variable argument lists.
 //

Take into account that clang before 3.7 was not correctly supported ms_va_args.

Only with ElCapitan we got good clang.

Share this post


Link to post
Share on other sites

Just compiled Clover r3430 under Clang/XCode 7.3. It works.

 

Funny. Whereas CLOVERX64.efi became smaller (664K → 647K), the drivers became much larger—e.g. OsxAptioFix2Drv.efi went 18K → 24K.

Share this post


Link to post
Share on other sites

Funny. Whereas CLOVERX64.efi became smaller (664K → 647K), the drivers became much larger—e.g. OsxAptioFix2Drv.efi went 18K → 24K.

clang is set up in Clover.dsc to use -Os on all modules.  GCC uses -O3 on a couple, and -O0 on others.  However, GCC is set up to use lto (link-time-optimization). clang isn't.  clang has -flto as well, but it needs modifying the command given to ld in order to set up.  I haven't tried that because the firmware crashes with an exception anyway.

 

About the exception - there's a utility in BaseTools VolInfo for listing the contents of a firmware volume (FV).  It's like a tar archive, and there is no way to find the load address for an .efi binary from it.  The binary gets copied into a memory address from the memory allocator.  Binaries are not page-aligned inside the FV, and are not run "in place" from the FV.

So what I'm thinking of is to add code to the exception handler to search down from the exception address for a COFF header, to display the position of the COFF header, and some values from it that are enough to uniquely identify the .efi binary containing the exception point.

Share this post


Link to post
Share on other sites

I found the exception.  It's in BiosVideo

BiosVideo/LegacyBiosThunk.c

BOOLEAN
EFIAPI
LegacyBiosInt86 (
  IN  BIOS_VIDEO_DEV                 *BiosDev,
  IN  UINT8                           BiosInt,
  IN  IA32_REGISTER_SET              *Regs
  )
{
....

  Stack16 = (UINT16 *)((UINT8 *) BiosDev->ThunkContext->RealModeBuffer + BiosDev->ThunkContext->RealModeBufferSize - sizeof (UINT16));
Code generated by clang:
0000000000005f38	488b4620        	movq	0x20(%rsi), %rax
0000000000005f3c	8b4808          	movl	0x8(%rax), %ecx
0000000000005f3f	8b4010          	movl	0x10(%rax), %eax
0000000000005f42	8d4401fe        	leal	-0x2(%rcx,%rax), %eax

  ThunkRegSet.E.SS   = (UINT16) (((UINTN) Stack16 >> 16) << 12);
  ThunkRegSet.E.ESP  = (UINT16) (UINTN) Stack16;
Code generated by clang:
0000000000005f46	0fb7c8          	movzwl	%ax, %ecx
0000000000005f49	c1e804          	shrl	$0x4, %eax
0000000000005f4c	2500f00000      	andl	$0xf000, %eax           ## imm = 0xF000
0000000000005f51	6689442456      	movw	%ax, 0x56(%rsp)
0000000000005f56	894c242c        	movl	%ecx, 0x2c(%rsp)

  ThunkRegSet.E.Eip  = (UINT16)((UINT32 *)NULL)[BiosInt];
  ThunkRegSet.E.CS   = (UINT16)(((UINT32 *)NULL)[BiosInt] >> 16);
Code generated by clang:
0000000000005f5a	0f0b            	ud2
0000000000005f5c	0f0b            	ud2

Share this post


Link to post
Share on other sites

I have new setup to test clover builds on,

Toshiba LX830 AIO, HD4000 appears to be disabled, doesn't show up in Clover UEFI,and Nvidia GT 630m Firmware is InsydeH2O

Anyone got any tips...

Share this post


Link to post
Share on other sites

I found the exception.  It's in BiosVideo

BiosVideo/LegacyBiosThunk.c

BOOLEAN
EFIAPI
LegacyBiosInt86 (
  IN  BIOS_VIDEO_DEV                 *BiosDev,
  IN  UINT8                           BiosInt,
  IN  IA32_REGISTER_SET              *Regs
  )
{
....

  Stack16 = (UINT16 *)((UINT8 *) BiosDev->ThunkContext->RealModeBuffer + BiosDev->ThunkContext->RealModeBufferSize - sizeof (UINT16));
Code generated by clang:
0000000000005f38	488b4620        	movq	0x20(%rsi), %rax
0000000000005f3c	8b4808          	movl	0x8(%rax), %ecx
0000000000005f3f	8b4010          	movl	0x10(%rax), %eax
0000000000005f42	8d4401fe        	leal	-0x2(%rcx,%rax), %eax

  ThunkRegSet.E.SS   = (UINT16) (((UINTN) Stack16 >> 16) << 12);
  ThunkRegSet.E.ESP  = (UINT16) (UINTN) Stack16;
Code generated by clang:
0000000000005f46	0fb7c8          	movzwl	%ax, %ecx
0000000000005f49	c1e804          	shrl	$0x4, %eax
0000000000005f4c	2500f00000      	andl	$0xf000, %eax           ## imm = 0xF000
0000000000005f51	6689442456      	movw	%ax, 0x56(%rsp)
0000000000005f56	894c242c        	movl	%ecx, 0x2c(%rsp)

  ThunkRegSet.E.Eip  = (UINT16)((UINT32 *)NULL)[BiosInt];
  ThunkRegSet.E.CS   = (UINT16)(((UINT32 *)NULL)[BiosInt] >> 16);
Code generated by clang:
0000000000005f5a	0f0b            	ud2
0000000000005f5c	0f0b            	ud2
Update: I changed the code to something else that compiles right. Now it's stuck again on a new problem with a blank screen.

 

Good!

I found 6 such functions in the project, we should find a working one.

Share this post


Link to post
Share on other sites

You're right, that's why it was still hanging.  I found the same code in LegacyBiosThunk following places
DuetPkg/BiosVideoThunkDxe/LegacyBiosThunk.c
BiosKeyboard/LegacyBiosThunk.c
BiosVideo/LegacyBiosThunk.c
LegacyBios/BlockIoDxe/LegacyBiosThunk.c
rEFIt_UEFI/Platform/LegacyBiosThunk.c

I changed them all to working code, and now boot7 built with xcode works  :) 

 

Update: boot6 works too.
 

Good!
I found 6 such functions in the project, we should find a working one.

Share this post


Link to post
Share on other sites
diff --git a/BiosKeyboard/LegacyBiosThunk.c b/BiosKeyboard/LegacyBiosThunk.c
--- a/BiosKeyboard/LegacyBiosThunk.c
+++ b/BiosKeyboard/LegacyBiosThunk.c
@@ -196,8 +196,13 @@ LegacyBiosInt86 (
   ThunkRegSet.E.SS   = (UINT16) (((UINTN) Stack16 >> 16) << 12);
   ThunkRegSet.E.ESP  = (UINT16) (UINTN) Stack16;
 
+#ifdef __clang__
+  ThunkRegSet.E.Eip  = *(UINT16*)(((UINTN)BiosInt) << 2);
+  ThunkRegSet.E.CS   = *(UINT16*)((((UINTN)BiosInt) << 2) + 2U);
+#else
   ThunkRegSet.E.Eip  = (UINT16)((UINT32 *)NULL)[BiosInt];
   ThunkRegSet.E.CS   = (UINT16)(((UINT32 *)NULL)[BiosInt] >> 16);
+#endif
   BiosDev->ThunkContext->RealModeState = &ThunkRegSet;
   AsmThunk16 (BiosDev->ThunkContext);
   
diff --git a/BiosVideo/LegacyBiosThunk.c b/BiosVideo/LegacyBiosThunk.c
--- a/BiosVideo/LegacyBiosThunk.c
+++ b/BiosVideo/LegacyBiosThunk.c
@@ -196,8 +196,13 @@ LegacyBiosInt86 (
   ThunkRegSet.E.SS   = (UINT16) (((UINTN) Stack16 >> 16) << 12);
   ThunkRegSet.E.ESP  = (UINT16) (UINTN) Stack16;
 
+#ifdef __clang__
+  ThunkRegSet.E.Eip  = *(UINT16*)(((UINTN)BiosInt) << 2);
+  ThunkRegSet.E.CS   = *(UINT16*)((((UINTN)BiosInt) << 2) + 2U);
+#else
   ThunkRegSet.E.Eip  = (UINT16)((UINT32 *)NULL)[BiosInt];
   ThunkRegSet.E.CS   = (UINT16)(((UINT32 *)NULL)[BiosInt] >> 16);
+#endif
   BiosDev->ThunkContext->RealModeState = &ThunkRegSet;
   AsmThunk16 (BiosDev->ThunkContext);
   
diff --git a/LegacyBios/BlockIoDxe/LegacyBiosThunk.c b/LegacyBios/BlockIoDxe/LegacyBiosThunk.c
--- a/LegacyBios/BlockIoDxe/LegacyBiosThunk.c
+++ b/LegacyBios/BlockIoDxe/LegacyBiosThunk.c
@@ -196,8 +196,13 @@ LegacyBiosInt86 (
   ThunkRegSet.E.SS   = (UINT16) (((UINTN) Stack16 >> 16) << 12);
   ThunkRegSet.E.ESP  = (UINT16) (UINTN) Stack16;
 
+#ifdef __clang__
+  ThunkRegSet.E.Eip  = *(UINT16*)(((UINTN)BiosInt) << 2);
+  ThunkRegSet.E.CS   = *(UINT16*)((((UINTN)BiosInt) << 2) + 2U);
+#else
   ThunkRegSet.E.Eip  = (UINT16)((UINT32 *)NULL)[BiosInt];
   ThunkRegSet.E.CS   = (UINT16)(((UINT32 *)NULL)[BiosInt] >> 16);
+#endif
   BiosDev->ThunkContext->RealModeState = &ThunkRegSet;
   AsmThunk16 (BiosDev->ThunkContext);
   
diff --git a/rEFIt_UEFI/Platform/LegacyBiosThunk.c b/rEFIt_UEFI/Platform/LegacyBiosThunk.c
--- a/rEFIt_UEFI/Platform/LegacyBiosThunk.c
+++ b/rEFIt_UEFI/Platform/LegacyBiosThunk.c
@@ -256,8 +256,13 @@ LegacyBiosInt86 (
   ThunkRegSet.E.SS   = (UINT16) (((UINTN) Stack16 >> 16) << 12);
   ThunkRegSet.E.ESP  = (UINT16) (UINTN) Stack16;
 
+#ifdef __clang__
+  ThunkRegSet.E.Eip  = *(UINT16*)(((UINTN)BiosInt) << 2);
+  ThunkRegSet.E.CS   = *(UINT16*)((((UINTN)BiosInt) << 2) + 2U);
+#else
   ThunkRegSet.E.Eip  = (UINT16)((UINT32 *)NULL)[BiosInt];
   ThunkRegSet.E.CS   = (UINT16)(((UINT32 *)NULL)[BiosInt] >> 16);
+#endif
   mThunkContext->RealModeState = &ThunkRegSet;
   AsmThunk16 (mThunkContext);
 

What did you change, if I may ask?

The instance in DuetPkg/BiosVideoThunkDxe turned out not to need patching because it's not used by Clover.

 

Update: I've committed rev 3431 with code that works for both gcc and clang, and also uses sizeof() instead of shifting.

Share this post


Link to post
Share on other sites

Try again with rev 3431.  I've set up LTO for clang -xcode5 toolchain, and removed -all_load linker option that was causing unnecessary bloat.

Funny. Whereas CLOVERX64.efi became smaller (664K → 647K), the drivers became much larger—e.g. OsxAptioFix2Drv.efi went 18K → 24K.

Share this post


Link to post
Share on other sites

clang is set up in Clover.dsc to use -Os on all modules.  GCC uses -O3 on a couple, and -O0 on others.  However, GCC is set up to use lto (link-time-optimization). clang isn't.  clang has -flto as well, but it needs modifying the command given to ld in order to set up.  I haven't tried that because the firmware crashes with an exception anyway.

@ Zenith432

If you type ld -v in El Cap 10.11.5 you get:

 

 @(#)PROGRAM:ld  PROJECT:ld64-264.3.101

configured to support archs: armv6 armv7 armv7s arm64 i386 x86_64 x86_64h armv6m armv7k armv7m armv7em (tvOS)

LTO support using: LLVM version 7.3.0

 

So we know that the native toolset supports LTO. I tried compiling with the -flto flag but the build fails:

 

...[CC] Reclaim

[CC] NullMemoryTest

[CC] CapsuleService

ld: in /Users/-/src/edk2/Build/Clover/RELEASE_XCLANG/X64/MdePkg/Library/BaseMemoryLib/BaseMemoryLib/OUTPUT/BaseMemoryLib.lib(SetMem.obj), archive member 'SetMem.obj' with length 1792 is not mach-o or llvm bitcode for architecture x86_64

make: *** [/users/-/src/edk2/Build/Clover/RELEASE_XCLANG/X64/MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer/DEBUG/WatchdogTimer.dll] Error 1...

 

Unfortunately I have no idea how to fix this!

Share this post


Link to post
Share on other sites

Ummm.... sorry, but I only set up the -xcode5 toolchain for compiling with lto :)  If that doesn't work for you, I'll look into adapting the other clang-based toolchains tomorrow.

 

Update: Committed rev 3432 with clang toolchains as follows

  • -clang (XCLANG) updated to use lto and removed -all_load
  • -xcode (XCODE32) removed -all_load, but no lto as this is legacy support for old clang 3.2 on SnowLeopard
  • -llvm (LLVM) made no change as it's some hybrid between clang and gcc linker

-xcode5 is preferred method for building with current xcode.  -clang if you install your own self-built clang from llvm.org.

 

@ Zenith432

If you type ld -v in El Cap 10.11.5 you get:

 

 @(#)PROGRAM:ld  PROJECT:ld64-264.3.101

configured to support archs: armv6 armv7 armv7s arm64 i386 x86_64 x86_64h armv6m armv7k armv7m armv7em (tvOS)

LTO support using: LLVM version 7.3.0

 

So we know that the native toolset supports LTO. I tried compiling with the -flto flag but the build fails:

 

...[CC] Reclaim

[CC] NullMemoryTest

[CC] CapsuleService

ld: in /Users/-/src/edk2/Build/Clover/RELEASE_XCLANG/X64/MdePkg/Library/BaseMemoryLib/BaseMemoryLib/OUTPUT/BaseMemoryLib.lib(SetMem.obj), archive member 'SetMem.obj' with length 1792 is not mach-o or llvm bitcode for architecture x86_64

make: *** [/users/-/src/edk2/Build/Clover/RELEASE_XCLANG/X64/MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer/DEBUG/WatchdogTimer.dll] Error 1...

 

Unfortunately I have no idea how to fix this!

Edited by Zenith432

Share this post


Link to post
Share on other sites

:(  XCODE5, ElCapitan 10.11.5, Xcode 7.2.1

iMac:Clover slice$ clang -v
Apple LLVM version 7.0.2 (clang-700.1.81)
Target: x86_64-apple-darwin15.5.0
Thread model: posix
iMac:Clover slice$
/Volumes/MacHD/Users/slice/src/edk2/MdePkg/Include/Base.h:503:11: error: unknown type name '__builtin_ms_va_list'; did you mean '__builtin_va_list'?
  typedef __builtin_ms_va_list VA_LIST;
          ^~~~~~~~~~~~~~~~~~~~
          __builtin_va_list
note: '__builtin_va_list' declared here
1 error generated.

Share this post


Link to post
Share on other sites

Micky1979: The 32-bit -xcode5 build doesn't work.  It's not because of lto.  I tried turning off lto, and it still doesn't work.  With lto it hangs.  Without lto, it spontaneously reboots.

 

Update: It's probably the ABI, because x64 says x86_64-pc-win32-macho, but x86 does not have any ABI-related settings.  I'll look into it.

 

Slice:  __builtin_ms_va_list is a recent addition to clang.  See here.  You're right, Apple only merged it into their version in Xcode 7.3.  There's no resolution to this.  I tried using the older __builtin_va_list instead.  The result was boot7 works, CloverGUI works partially and can boot OS X, but some things don't work.  For instance, if I try start the shell - it hangs.  So __builtin_va_list works in some instances with ms-abi, and fails in others (I think va_copy is the problem, or maybe the number of fixed parameters.)

The manual implementation of va_list found in Base.h is not going to work anyway - because it assumes variable parameters are on the stack without spilling them.  There's no point in using it at all.

So to compile with -xcode5 need xcode 7.3.

Share this post


Link to post
Share on other sites

Micky1979: The 32-bit -xcode5 build doesn't work.  It's not because of lto.  I tried turning off lto, and it still doesn't work.  With lto it hangs.  Without lto, it spontaneously reboots.

 

Update: It's probably the ABI, because x64 says x86_64-pc-win32-macho, but x86 does not have any ABI-related settings.  I'll look into it.

 

Slice:  __builtin_ms_va_list is a recent addition to clang.  See here.  You're right, Apple only merged it into their version in Xcode 7.3.  There's no resolution to this.  I tried using the older __builtin_va_list instead.  The result was boot7 works, CloverGUI works partially and can boot OS X, but some things don't work.  For instance, if I try start the shell - it hangs.  So __builtin_va_list works in some instances with ms-abi, and fails in others (I think va_copy is the problem, or maybe the number of fixed parameters.)

The manual implementation of va_list found in Base.h is not going to work anyway - because it assumes variable parameters are on the stack without spilling them.  There's no point in using it at all.

So to compile with -xcode5 need xcode 7.3.

OK, thanks for the analysis. Somehow Xcode 7.2.1 don't want to be updated to 7.3.

Anyway I created llvm-clang v3.8 with good support of ms_va_arg. I am using it to compile Wine, and it works! Same ms_abi as expected.

So why there is a toolset named XCLANG. 

But I don't know what is the rule to use LTO with clang. I think it is different from gcc-4.9. For example I have an utility llvm-lto and I see no its usage in our toolset. I want some theory about this.

Share this post


Link to post
Share on other sites

The problem with -xcode5 -ia32 is not in the ABI or var-args.

It is only in boot3.  If I use boot3 from gcc, CloverGUI and bdmesg from xcode work fine.

So it's a new problem specific to boot3.  It displays the digit "3" on top of the screen b4 hanging, so looks like BiosVideo succesfully initializes.

Will need more work.

 

Slice:

It may be that using LTO with vanilla clang requires adding --plugin liblto....  something to the command line to ar.  What error are you getting exactly?

Giving -flto to clang for compilation should work...

Must invoke ld via clang driver as usual with lto.

Does it fail during ar or ld?

 

crusher:

I'm not getting involved with Aptio.

Share this post


Link to post
Share on other sites

Do you have DataHubDxe installed?

 

 

Slice:

It may be that using LTO with vanilla clang requires adding --plugin liblto....  something to the command line to ar.  What error are you getting exactly?

Giving -flto to clang for compilation should work...

Must invoke ld via clang driver as usual with lto.

Does it fail during ar or ld?

 

 

Something like invalid arguments. This evening I may try again.

Tested boot6 compiled as

-clang --std-ebda

Reboot after "6"

This digit printed on screen by INT10 so it has no relation to BiosVideo. It works before Protected mode inited.

#//Slice - switch to graphics mode (1), or 80x25 mono text mode (2)
		movw	$0x0002, %ax 
		int		$0x10
		#put char 6
		movl	$0x000F, %ebx
		movl	$0x0E36, %eax
		movl	$0x0010, %ecx
		int		$0x10

@STLVNUB

INT15h is also here so Coreboot is impossible.

Share this post


Link to post
Share on other sites

  • Recently Browsing   1 member

  • Similar Content

    • By RougeOne
      Budget Workstation MacOS 10.14.1 build: z370 AORUS Gaming 5 - i5-8600K - RX 580 - UHD 630
      flawless iGPU/dGPU integration, fast FCPX editing/rendering, great overall performance for ~$1200 / ~£1000
       
      Update: updated WhateverGreen and Lilu, then updated OS to 10.14.3 and everything is fine! Even iMessage, which previously I hadn't been able to make work, is now working - possibly the update flushed the NVRAM?
       
      I'm gonna come straight out and admit it - I used newb tools which are considered taboo on InsanelyMac, and so this isn't so much an installation guide as it is a green flag to anyone considering the same hardware. My first and previous Hackintosh project was just over ten years ago and this site was massively helpful, so this is my (very small) way of giving back.
       
      EFI DIRECTORY
      http://s000.tinyupload.com/index.php?file_id=97606131925137056003
       
      HARDWARE
      CPU: Intel i5-8600K 3.6GHz hexacore (contains UHD 630 iGPU)
      CPU Cooler: be quiet! Pure Rock Slim (no paste needed, and fan facing front)
      Mobo: GIGABYTE z370 AORUS Gaming 5 (WIFI)
      RAM: 1x 8GB CORSAIR Vengeance LPX C16 2666MHz (in first slot)
      GFX Card: Sapphire RX 580 NITRO+ SE
      SATA: used ports 0, 1, 3, 5 (HDD problems when connected to port 4)
      HDD: generic
      DVD Drive: generic
      PSU: EVGA 500W Semi Modular (but you should get 650W!)
      Case: CoolerMaster CM590 III
      Fans: 2x stock case fans (one sucky on front, one blowy on back), 3x be quiet! BL046 120mm fans (two blowy on top, one sucky on front). Airflow near-perfectly balanced.
       
      ADVICE
      With the Clover configuration, you want to pay close attention to all things relating to graphics. There are some specific settings for ACPI, Boot, Devices and Graphics which should be copied exactly in order to get the iGPU and dGPU to work in perfect harmony. For instance, make sure you use ig-platform-id 59120003 rather than 59120000 if you want FCPX to be usable. With the right settings, FCPX will not only run, but run flawlessly.
       
      I was not able to figure out how to make NVRAM/PRAM behave itself, and I got errors when I tried to issue relevant commands. As a result, I could not at first get iMessage to work properly. It worked once on my first installation attempt but not from subsequent attempts. This Clover configuration therefore has no consideration whatsoever toward iMessage reliability - however, iMessage ended up working somehow, anyway - I noticed it after I'd updated to 10.14.3 but this may just have been coincidence.
       
      Onboard WiFi does not work. There is no driver for it. I'm using wired ethernet to a bridge router as it was cheaper than getting a compatible PCI card.
       
      Audio is working well after I installed the z370 audio patch, then the ALC1220 codecs, then AppleALC.
       
      With kexts for generic 3rd party SATA and generic 3rd party eSATA, my HDDs and DVD drive work perfectly well.
       
      Sleep/Wake functions run perfectly. iCloud functions run perfectly. Shutdown leaves the mobo LEDs on, annoyingly.
       
      My USB 3 ports seem to suffer from low power output, and I don't know why.
       
      Overall, this system appears to run about as well under MacOS 10.14 Mojave as it does under Windows 7. I would solidly recommend this build to anyone looking to build a computer for workstation purposes, on a budget.
    • By JhonneR
      Good morning, everyone, I'm sorry if I was wrong in choosing the topic but I need help.
      I have found it extremely difficult to mount a Hackintosh in my acer.
      Setup;
      I5 2430m 2.4 6GB RAM
      Mobo P5we0 - Intel intel Graphics 3000
      At the moment I have not found out what my audio codecs are.
      but I'll leave the link on the motherboard.
      however, my real problem is several.
      I have already used the itakos image, I have already used several images that could be installed normally and that after installing the image I do not have internet via cable or wireless.
      And another, I already looked in other forums and I know that I will be called a donkey in the logical question but I have not been able to install the [url=&quot;http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/&quot;]#####[/url] or clover to start from the Hard Disk, so I do not know what to do.At the moment I still do not know if there has already been someone who has already installed the High Sierra or just the Sierra in this notebook model and obtained permanent success.
      If anyone can help me, I'll be grateful.
      Installations without success, but with the system already installed in ACER;
      SIERRA
      HIGH SIERRA
      MOJAVE
      All with the same symptom. Starting only by the bootable USB stick and without internet connection via cable and wireless.
      Appreciate ! Acer 5750 Official Page
    • By Slice
      Since rev 4844 Vector Themes are supported and there are ready-to-use Clovy by Clovy, cesium by Slice and BGM_SVG by Blackosx.
      You may see it's structure to create own theme
      -------------------------------------------------------------------------------------------------------------------------------------------------------
       
       
      Now I want to add vector graphics support in Clover. See rev 4560 and later.
      It is not working yet but designers may begin to create Vector Themes.
      It supposed to consist of SVG elements and has design size. It will be rendered to any screen size scaled from design size.
       
      What application in macOS can create SVG graphics?
      Inkscape is not working in macOS 10.11+. Pity.
      LibreOffice Draw works with SVG but buggy.
      Boxy SVG cost 10$ but looks good enough. It creates the best in simplicity files and have more then enough features.
      Illustrator is good but expensive.
       
      How to improve SVG file?
      Clover has restricted support for SVG. It is your job to make compatible file and as small as possible to speedup rendering.
      Some helps:
      Help:Inkscape – From invalid to valid SVG Inkscape files
      From invalid to valid SVG Adobe Illustrator files
      From invalid to valid SVG files of other editors: BKchem, ChemDraw and CorelDRAW
      Help:Illustrator – Assistance with creating and saving SVG images in Adobe Illustrator that will pass W3C validation
      User:Quibik/Cleaning up SVG files manually
      Later I will write own instructions specific to Clover abilities.
       
      How to create SVG fonts?
      You can google to find ready-to-use SVG fonts.  I found some problems with too beaty fonts: slow rendering and overflow crash. Be careful.
      You can get ttf or otf fonts and convert them into svg by using online WEB services. Not a problem to google.
      But then I want to find a way to simplify the font to reduce a size and speedup rendering.
      You can create own font by FontForge It is opensource and available for Windows, Mac and GNU+Linux. It creates otf font which you can convert to svg font.
       
      Pictures from Badruzeus
      https://www.insanelymac.com/forum/applications/core/interface/file/attachment.php?id=301597
    • By PixelLover
      I'm in the middle of my first hackintosh (High Sierra) on my ZenBook Pro UX501VW-US71 laptop using the Vanilla Install. I've tried using different config.plst files and I've gotten the furthest with RehabMan's own (linked here). It hangs at error message IOConsoleUsers: gIOScreenLockState 3, hs 0, bs 0, now 0, sm 0x0.   Can anyone help me figure out what changes to make to the config.plst file for my specific laptop (which is where I assume the problem lies)   System Specs: Intel Skylake Core i7­-6700HQ 2.6 GHz Quad­core
      Intel® HD Graphics 530 Nvidia GTX 960M 2G 15.6" Touch IPS 4K Ultra­-HD display, 3840 x 2160 resolution   Kexts: AppleALC.kext FakeSMC.kext Lilu.kext USBInjectAll.kext WhateverGreen.kext  
    • By gengik84
      Ciro82==>>Thanks
      Uno dei tre Requisiti:
      Hack funzionante Mac vero Macchina virtuale Impostazioni Bios per il boot:
      Cercate una voce  del tipo “Sata Mode”e settatela  in AHCI
      Secure Boot: disabilitare o altri sistemi operativi
      CSM: UEFI o LEGACY, oppure a secondo del tipo di installazione
      VT-x / VT-d disable
      *Nota: Secure boot e csm valido solo per bios UEFI
      Materiale Occorrente 
      "OS X (Versione App.Store)”
      USB 8GB  *nota: nel caso di usb superiori dovrà essere partizionata, in modo da avere una partizione su cui "lavoreremo,di questa dimensione
      ShowAllfiles 
      kext Wizard 
      Bootloader Clover_2.3k_r xxx:                   http: //sourceforge.n.../cloverefiboot/
      Clover Configurator:                                    http: //mackie100proj...a.org/download/
      FakeSmc.kext:                                            https://github.com/kozlek/HWSensors/releases
      In allegato,a fondo pagina troverete un "pacchetto" contenente : ShowAllfiles, Kext Wizard, FakeSmc.kext: 
      App alternative:
      ESP Mounter Pro: per montare la partizione EFI
      Vi illustrerò tre metodi per creare la usb, ma sono ben distinti… quindi usatene soltanto uno
      Metodo 1: “Install Mac_OS_X.command” Metodo 2: “Create Install Media di Apple” Metodo 3:  Metodo Manuale Alla fine delle preparazione dell’installer, tutti i metodi necessitano l’installazione del Bootloader Clover sulla a vostra USB.
      “CONDIZIONI OBBLIGATORIE”
      PUNTO 1: che la vostra usb sia stata preventivamente nominata USB (caratteri maiuscoli) Tabella di partizione GUID e la formattazione in  Mac esteso Journaled.
      PUNTO 2: che l’installer di OSX si trovi in Applicazioni
      Utility Disco 
      Selezionate la pendrive, andate su “partizione”, selezionate “1 partizione”, impostate Mac OS esteso journaled e date il nome USB, poi in basso cliccate su opzioni e scegliete Tabella partizione (GUID), poi “applica”.
      Immagine 
      Riporto nuovamente l’operazione sopra citata adoperando dal nuovo Utility Disco introdotto su El Capitan.
      Rimane ovviamente invariato nome della usb in ==>> USB (maiuscolo), la formattazione in Mac esteso Journaled e sia la mappa partizione in GUID
      Da utility disco selezionate la usb, cliccate su inizializza.
      dal menù a tendina scegliete la relative impostazioni
      Immagine  
      Procedura effettua da High Sierra è la stessa della precedente, l'unica attenzione e operazione da aggiungere in primis  è cliccare nel menù a tendina in alto sulla sinistra di utility disco e selezionare "mostra tutti i dispositivi"
      Immagine 
       
      =====================
        METODO 1: "Install_Mac_OS_X.Command" Lo script che trovate allegato in fondo alla guida permette la creazione dell’installer in maniera automatica
      Include la possibilità di scelta di tre versioni di osx
      Yosemite El Capitan Sierra Il risultato finale è come quello del metodo "manuale" descritto nella guida, per cui l'installazione avverrà in un solo passaggio, non in due come con il metodo createinstallmedia. 
      Offre inoltre la possibilità di inserire un kernel patchato, utile, per esempio, per chi usa AMD.
      Rimane invariato il nome dato alla usb in USB, mappa partizione e tipo di formattazione
      Se la vostra usb non sarà rinominata nel modo corretto, verrete avvisati dal terminale, quindi non dovrete far altro che apportare la relativa modifica e rilanciare nuovamente lo script
      Esempio
      ===========================
      Metodo 2 
      L'intento è quello di usare la procedura fornitaci direttamente da Apple, "createinstallmedia", introdotta  con Mavericks. 
      Tale metodo prevede l’uso del terminale che via via se ne sta perdendo il “valore e l’uso”
      Inizialmente per i neofiti potrà sembrare problematico ma alla fine non è così.
      Durante il post installazione alcune operazioni ne richiedono l’ uso.
      Perciò mi sono chiesto perchè, qualora uno volesse, non far conoscere da subito un po’ questo “strumento”???
      Per favorirvi vi ho allegato i comandi già  “pronti”, i quali li potrete copiare ed incollare sul terminale.
      A questo punto aprite il terminale, copiate ed incollate il comando sottostante e premete invio, digitate la vostra password e premete nuovamente invio.
      Comando per creare USB con Yosemite:
      sudo /Applications/Install\ OS\ X\ Yosemite.app/Contents/Resources/createinstallmedia --volume /Volumes/USB --applicationpath /Applications/Install\ OS\ X\ Yosemite.app --nointeraction  
      Comando per creare USB con El Capitan
      sudo /Applications/Install\ OS\ X\ El\ Capitan.app/Contents/Resources/createinstallmedia --volume /Volumes/USB --applicationpath /Applications/Install\ OS\ X\ El\ Capitan.app --nointeraction Comando per creare USB con Sierra 
      sudo /Applications/Install\ macOS\ Sierra.app/Contents/Resources/createinstallmedia --volume /Volumes/USB --applicationpath /Applications/Install\ macOS\ Sierra.app/ --nointeraction Per creare USB con Hight Sierra o Mojave usate --> C_I_M (aggiornato per 10.14)
       
      Funziona con il drag & drop sul terminale, in questo caso non vi è necessità che la usb sia nominata in un determinato modo ed essendo basato su create install media ovviamente funziona da 10.9 a 10.14.... 
      BENE…IL PROCESSO DI CREAZIONE E’ INIZIATO…
      AVREMO CIRCA 20/30 MINUTI DI TEMPO LIBERO A CUI DEDICARSI A CIO’ CHE VOGLIAMO………………………………………..  
      COLGO L’OCCASIONE PER FARVI NOTARE LA VELOCITA’ E LA SICUREZZA DI QUESTO METODO
      CONFRONTATE QUESTO CON IL TERZO METODO E NOTERETE CHE CON UN SOLO PASSAGGIO, OSSIA IL COMANDO DATO AL TERMINALE, FACCIAMO IN UNA SINGOLA OPERAZIONE TUTTI I VARI STEP DESCRITTI SULL’ ALTRO METODO.
      DETTO QUESTO, MOLTO IMPORTANTE E’ SOTTOLINEARE CHE COSI’ FACENDO EVITEREMO ERRORI  DI DISTRAZIONE RIGUARDO AI PASSAGGI O FRAINTENDIMENTI.
      Immagine 
      Potete adesso passare ad installare il bootloader Clover sulla vostra usb.
      *NOTA*:
      Avendo usato questo metodo l'installazione si dividerà in due fasi, perciò dopo il primo riavvio e necessario far partire nuovamente l'installer, selezionare lo stesso disco senza formattarlo.
      Finita questa ulteriore fase , l'installazione sarà terminata
      =========================
      METODO "MANUALE"....  (lascio per futura memoria-Compatibile fino a 10.12)
      ==========================
      Bootloader
      **Nota:** Installazione in UEFI  dipenderà dalla scheda madre in vostro possesso, quindi se non supporta tale opzione , il bootloader dovrà essere installato in  modalità Legacy.
       Vi invito, qualora non sapeste questa informazione, a recarvi nel sito ufficiale del produttore e controllare le informazioni a riguardo
      Fatto questo dobbiamo installare  Clover sulla usb.
      A seconda del tipo di Bios o al tipo di installazione che vogliamo fare UEFI o Legacy avremo ovviamente configurazioni diverse in questa fase.
      Lanciate il pkg.
      Immagine 

       
      Cambiate la destinazione di installazione ad USB oppure Install Mac_OS_X (a secondo del tipo di creazione eseguita)
      Successivamente clicchiamo su "Ad Hoc"
      Per Installazione UEFI
      Mettete i flag   : Installazione solo per avvio UEFI
                               : installare Clover nella ESP
                               : Driver64UEFI  AptioMemory --> (consigliato) 
                               : Driver64UEFI  ApfsDriverLoader --> (consigliato) --> sostituisce l'uso del driver apfs.efi
                               : Selezionate l'altri driver come da successiva immagine,
       
      *Nota: Altri driver che si possono usare  al suo posto  sono:
       informazioni 
       
      Proseguite con l’installazione.
      Immagine 
      ** Ricordate che avrete accesso a questa cartella dopo aver montato la partizione EFI**
      ===========================
      Per installazione Legacy
      Immagine 
      ===========================
      Impostazione per config.plist:
      Con clover configurator “montate” la partizione EFI della usb.
      1) Per fare questo nel menù di sinistra, cliccate su “Mount EFI”
      2) individuate la partizione relativa alla vostra usb, a questo punto montiamo la relativa partizione EFI  selezionando l’apposito pulsante “Mount Partition”
      Immagine 
      3) Successivamente cliccate su “Open Partition”.. recatevi in EFI/Clover ed aprite il config.plist
      4) Sezione ACPI: Disabilitate tutti i fix sia del menù 1 che del menù 2
      Immagine 
      5) Sezione BOOT: Sole se si sta installando Yosemite mettete il flag su kext-dev-mode=1
      Immagine 
      6) Sezione RT Variables: Se si sta installando El Capitan oppure Sierra, aggiungere i valori: BooterConfig= 0x28, CsrActiveConfig= 0x67
      Immagine 
      7) Sezione System Parameters: Su inject kext mettete YES
      Immagine 
      ===========================
      Nota: Su El Capitan, è stato introdotto SIP (System Integrity Protection)
      Info:
      ===========================
      Recatevi in EFI/Clover/kext/10.x 
      X= alla versione di osx che state installando. Per esempio se installerete Yosemite dovrete recarvi nella cartella 10.10, con El Capitan in 10.11….ecc
      Se non ci fosse tale cartella, createla e nominatela voi a “modo”.
      Copiatevi all’interno FakeSmc.kext
      *Nota se venite già da altre vostre configurazioni, oltre kext sopra citato ,potete mettere gli altri necessari per il vostro hardware
      Stessa cosa se avete DSDT e/o SSDT potete copiarli in EFI/Clover/Acpi/Patched
      Immagine 
      
      Per High Sierra:
      Scaricare il driver apfs.efi a fine guida, collocarlo:
          --> EFI/clover/Driver64UEFI se stiamo usando UEFI
      --> EFI/Clover/Driver64 se stiamo usando Legacy
       
      Per chi volesse continuare ad usare HFS vi rimando a questo post:
        Come installare High Sierra in HFS direttamente dalla usb  
      Utenti Laptop:  Nel 99% è obbligatorio disattivare la grafica discreta Nvidia/Amd per installare questo nuovo osx
                                     Quindi aggiungete --> SSDT-Disable_DGPU.aml.zip
                                     in EFI/Clover/acpi/Patched della usb
      --------------------------------------------------------------------
      Per Mojave:
      Scaricare il driver apfs.efi per 10.14 a fine guida, collocarlo:
          --> EFI/clover/Driver64UEFI se stiamo usando UEFI
      --> EFI/Clover/Driver64 se stiamo usando Legacy
      Versione di clover non antecedente a V_4015
      Volete usare HFS?
      E' possibile fare un installazione diretta su altro disco o partizione, nel caso può essere usato anche per effettuare aggiornamenti...
      nel caso guardate...
       Mojave in HFS 
       Oppure direttamente da usb  
       
      Fatto questo avrete la vostra USB bootable per installare OSX.
      ………Non scordatevi Fakesmc.kext da mettere nella relativa cartella…. senza il quale non farete mai il Boot......
      *NOTA: se usato il terminale per la creazione della usb, l'installazione si dividerà in due fasi, perciò dopo il primo riavvio e necessario far partire nuovamente l'installer, selezionare lo stesso disco senza formattarlo.
      Finita questa ulteriore fase , l'installazione sarà terminata
      **NOTA** Se avete processori Broadwell,Skylake o Kabylake...usate FakeSmc.kext e relativi sensors che trovate all'interno del secondo pacchetto.. (potete usarlo anche sui precedenti senza problemi, essendo una versione più aggiornata ha ulteriore supporto per le cpu più recenti)
      Update: Fakesmc e sensors versione 6.26
      Post installazione... post #2           
       Buon Hack….. 
      Aggiornamento:Install_Mac_OS_X.command.zip (compatibile da 10.10 a 10.12)
      le info le trovate a questo post
      Ringrazio @Ciro82 che mi ha aiutato nel preparare questa guida.
      Pacchetto.zip
      Pacchetto-2.zip
      apfs.efi-10.13-NoLog.zip
      Pacchetto-Fake+Sensors 6.26.1440.zip
      apfs.efi-10.13.1-No_LOG.zip
      apfs.efi-10.13.2_No_Log.zip
      apfs.efi-10.13.3-No_Log.zip
      apfs.efi-10.13.4-No_Log.zip
      apfs.efi-10.13.5_No_Log.zip
      C_I_M.zip
       
      apfs.efi-10.14-beta1_No_Log.zip





       

×