mirror of
https://review.coreboot.org/flashrom.git
synced 2025-07-01 14:11:15 +02:00
Work around shadowing warnings in libpci headers
This is needed for warning-free compilation on older gcc versions (3.x and probably older). Such a gcc version is the default on i386 OpenBSD. Corresponding to flashrom svn r1061. Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> Acked-by: Stuart Henderson <sthen@openbsd.org>
This commit is contained in:
4
Makefile
4
Makefile
@ -310,7 +310,9 @@ compiler: featuresavailable
|
||||
ifeq ($(CHECK_LIBPCI), yes)
|
||||
pciutils: compiler
|
||||
@printf "Checking for libpci headers... "
|
||||
@$(shell ( echo "#include <pci/pci.h>"; \
|
||||
@# Avoid a failing test due to libpci header symbol shadowing breakage
|
||||
@$(shell ( echo "#define index shadow_workaround_index"; \
|
||||
echo "#include <pci/pci.h>"; \
|
||||
echo "struct pci_access *pacc;"; \
|
||||
echo "int main(int argc, char **argv)"; \
|
||||
echo "{ pacc = pci_alloc(); return 0; }"; ) > .test.c )
|
||||
|
Reference in New Issue
Block a user