[edk2-devel] including redfish libs results in multiple definitions of symbols

M.T. xzavierpower at gmail.com
Wed May 25 16:23:02 UTC 2022


Hello

I'm working on a small UEFI shell app.
I was hoping to make use of the JsonLib found in the Redfish Package.

When I include the Redfish JsonLib and it's dependencies:
JsonLib|RedfishPkg/Library/JsonLib/JsonLib.inf
Ucs2Utf8Lib|RedfishPkg/Library/BaseUcs2Utf8Lib/BaseUcs2Utf8Lib.inf
RedfishCrtLib|RedfishPkg/PrivateLibrary/RedfishCrtLib/RedfishCrtLib.inf
BaseSortLib|MdeModulePkg/Library/BaseSortLib/BaseSortLib.inf

BaseSortLib has symbol clashes with SortLib resulting in the following:

/usr/bin/ld: UefiSortLib.obj (symbol from plugin): in function
`PerformQuickSort':
(.text+0x0): multiple definition of `PerformQuickSort'; BaseSortLib.obj
(symbol from plugin):(.text+0x0): first defined here
/usr/bin/ld: UefiSortLib.obj (symbol from plugin): in function
`PerformQuickSort':
(.text+0x0): multiple definition of `DevicePathCompare'; BaseSortLib.obj
(symbol from plugin):(.text+0x0): first defined here
/usr/bin/ld: UefiSortLib.obj (symbol from plugin): in function
`PerformQuickSort':
(.text+0x0): multiple definition of `StringNoCaseCompare'; BaseSortLib.obj
(symbol from plugin):(.text+0x0): first defined here
/usr/bin/ld: UefiSortLib.obj (symbol from plugin): in function
`PerformQuickSort':
(.text+0x0): multiple definition of `StringCompare'; BaseSortLib.obj
(symbol from plugin):(.text+0x0): first defined here

I need SortLib for UEFIShell dependencies, and I need BaseSortLib for
JsonLib.
Is there some way around this?  Or is Redfish meant to be standalone?

Thank you in advance
xp


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#90007): https://edk2.groups.io/g/devel/message/90007
Mute This Topic: https://groups.io/mt/91336682/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/edk2-devel-archive/attachments/20220525/52bf659c/attachment.htm>


More information about the edk2-devel-archive mailing list