cancel
Showing results for 
Search instead for 
Did you mean: 

Wi-Fi Combo

SeKi_2184131
New Contributor

Hello,

for building OpenOCD, i was running './build_all.sh' script using MINGW, Msys, Git. tools in 32-bit Windows System,

but below build error message is printed.

maybe, 'just_libusb.sh' script is built, this error message is printed.

---------------------------------------------------------------

../../libusb-1.0.19/libusb/os/windows_usb.c: In function 'get_windows_version':

../../libusb-1.0.19/libusb/os/windows_usb.c:850:4: error: implicit declaration o

f function 'VerSetConditionMask' [-Werror=implicit-function-declaration]

    major_equal = VerSetConditionMask(0, VER_MAJORVERSION, VER_EQUAL);

    ^

../../libusb-1.0.19/libusb/os/windows_usb.c:850:41: error: 'VER_MAJORVERSION' un

declared (first use in this function)

    major_equal = VerSetConditionMask(0, VER_MAJORVERSION, VER_EQUAL);

                                         ^

../../libusb-1.0.19/libusb/os/windows_usb.c:850:41: note: each undeclared identi

fier is reported only once for each function it appears in

../../libusb-1.0.19/libusb/os/windows_usb.c:850:59: error: 'VER_EQUAL' undeclare

d (first use in this function)

    major_equal = VerSetConditionMask(0, VER_MAJORVERSION, VER_EQUAL);

                                                           ^

../../libusb-1.0.19/libusb/os/windows_usb.c:860:42: error: 'VER_MINORVERSION' un

declared (first use in this function)

     minor_equal = VerSetConditionMask(0, VER_MINORVERSION, VER_EQUAL);

                                          ^

cc1.exe: some warnings being treated as errors

make[1]: *** [os/libusb_1_0_la-windows_usb.lo] Error 1

make[1]: Leaving directory `/home/Ssery/source/libusb-build/libusb'

make: *** [install-recursive] Error 1

------------------------------------------------

how can I resolve this build error?

Thank you.

0 Likes
1 Solution
JoYi_1844281
Contributor II

add export EXTRA_CFLAGS=-DWINVER=0x500,

before build libusb

View solution in original post

0 Likes
2 Replies
JoYi_1844281
Contributor II

add export EXTRA_CFLAGS=-DWINVER=0x500,

before build libusb

View solution in original post

0 Likes
SeKi_2184131
New Contributor

Thank you, jone.

when export EXTRA_CFLAGS=-DWINVER=0x500 is added at 111 Line in just_libusb.sh,

Building this script using MinGW was successful !!

And also, the installation of some libraries and packages in MinGW\bin are required depending on the OS.

+ The related issue was referenced in the website below.

libusb / Mailing Lists

0 Likes