https://sourceware.org/bugzilla/show_bug.cgi?id=20070

--- Comment #7 from H.J. Lu <hjl.tools at gmail dot com> ---
Created attachment 9264
  --> https://sourceware.org/bugzilla/attachment.cgi?id=9264&action=edit
A patch

Try this.  But this doesn't fix llvm LTO bug. I got

/tmp/lto-llvm-2a2442.o: In function `UefiDevicePathLibDuplicateDevicePath':
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:394:
undefined reference to `GetDevicePathSize'
/tmp/lto-llvm-2a2442.o: In function `UefiDevicePathLibAppendDevicePath':
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:447:
undefined reference to `DuplicateDevicePath'
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:451:
undefined reference to `DuplicateDevicePath'
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:462:
undefined reference to `GetDevicePathSize'
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:463:
undefined reference to `GetDevicePathSize'
/tmp/lto-llvm-2a2442.o: In function `UefiDevicePathLibAppendDevicePathNode':
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:522:
undefined reference to `DuplicateDevicePath'
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:542:
undefined reference to `AppendDevicePath'
/tmp/lto-llvm-2a2442.o: In function
`UefiDevicePathLibAppendDevicePathInstance':
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:585:
undefined reference to `DuplicateDevicePath'
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:596:
undefined reference to `GetDevicePathSize'
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:597:
undefined reference to `GetDevicePathSize'
/tmp/lto-llvm-2a2442.o: In function
`UefiDevicePathLibGetNextDevicePathInstance':
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:684:
undefined reference to `DuplicateDevicePath'
/tmp/lto-llvm-2a2442.o: In function `FileDevicePath':
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:872:
undefined reference to `AppendDevicePath'
/tmp/lto-llvm-2a2442.o: In function `CatVSPrint':
/home/jshi19/edk2-fork/MdePkg/Library/UefiDevicePathLib/DevicePathUtilities.c:876:
undefined reference to `StrCpyS'
BasePrintLib.lib(PrintLib.obj): In function `UnicodeVSPrint':
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:71: undefined
reference to `DebugAssertEnabled'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:71: undefined
reference to `DebugAssert'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:72: undefined
reference to `DebugAssert'
BasePrintLib.lib(PrintLib.obj): In function `UnicodeVSPrintAsciiFormat':
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:218: undefined
reference to `DebugAssertEnabled'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:218: undefined
reference to `DebugAssert'
BasePrintLib.lib(PrintLib.obj): In function `SPrintLength':
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:730: undefined
reference to `DebugAssertEnabled'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:730: undefined
reference to `DebugAssert'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLib.c:731: undefined
reference to `DebugAssert'
BasePrintLib.lib(PrintLibInternal.obj): In function `BasePrintLibSPrintMarker':
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:366:
undefined reference to `DebugAssertEnabled'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:366:
undefined reference to `DebugAssert'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:397:
undefined reference to `DebugAssertEnabled'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:405:
undefined reference to `AsciiStrSize'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:405:
undefined reference to `DebugAssert'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:397:
undefined reference to `StrSize'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:397:
undefined reference to `DebugAssert'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:701:
undefined reference to `ReadUnaligned32'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:702:
undefined reference to `ReadUnaligned16'
BasePrintLib.lib(PrintLibInternal.obj): In function
`BasePrintLibValueToString':
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:129:
undefined reference to `DivU64x32Remainder'
BasePrintLib.lib(PrintLibInternal.obj): In function `BasePrintLibSPrintMarker':
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:397:
undefined reference to `DebugAssertEnabled'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:973:
undefined reference to `DebugAssert'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:982:
undefined reference to `StrSize'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:982:
undefined reference to `DebugAssert'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:987:
undefined reference to `AsciiStrSize'
/home/jshi19/edk2-fork/MdePkg/Library/BasePrintLib/PrintLibInternal.c:987:
undefined reference to `DebugAssert'
clang-3.9: error: linker command failed with exit code 1 (use -v to see
invocation)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to