Skip to content

Commit f385e44

Browse files
Enabled Windows Hotplug Support
1 parent 3c866c4 commit f385e44

3 files changed

Lines changed: 8 additions & 4 deletions

File tree

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,3 +86,6 @@ xcuserdata
8686
build/
8787
tags
8888
cscope.out
89+
*.*~
90+
build64
91+

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# MIT License for CMake Build Infrastructure. See COPYING for the license of
22
# libusb itself.
33
#
4-
# Copyright (c) 2023-2024 Kritzel Kratzel.
4+
# Copyright (c) 2023-2026 The OneLuaPro project authors.
55
#
66
# Permission is hereby granted, free of charge, to any person obtaining a copy of
77
# this software and associated documentation files (the "Software"), to deal in
@@ -55,7 +55,7 @@ project(libusb LANGUAGES C)
5555

5656
# ------------------------------------------------------------------------------
5757
# Other settings
58-
set(CMAKE_VERBOSE_MAKEFILE OFF)
58+
set(CMAKE_VERBOSE_MAKEFILE ON)
5959
if(NOT CMAKE_BUILD_TYPE)
6060
# Visual Studio generators irgore this setting
6161
set(CMAKE_BUILD_TYPE Release CACHE STRING "Build type" FORCE)

libusb/CMakeLists.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# ------------------------------------------------------------------------------
2-
# lfs DLL
2+
# libusb DLL
33
add_library(libusb STATIC)
44
# setup platform-specific sources, compile and linker options
55
if(WIN32 AND NOT MinGW)
66
target_compile_options(libusb PRIVATE /D_WIN32 /D_CRT_SECURE_NO_WARNINGS)
7-
# target_link_options(lfs PRIVATE /LIBPATH:${LIBLUA_LIBDIR} liblua.lib)
7+
add_compile_definitions(LIBUSB_WINDOWS_HOTPLUG)
88
else()
99
message(FATAL_ERROR "Not yet fully implemented.")
1010
endif()
@@ -14,6 +14,7 @@ target_sources(libusb
1414
os/events_windows.h os/events_windows.c os/threads_windows.h os/threads_windows.c
1515
os/windows_common.h os/windows_common.c os/windows_usbdk.h os/windows_usbdk.c
1616
os/windows_winusb.h os/windows_winusb.c
17+
os/windows_hotplug.h os/windows_hotplug.c
1718
libusbi.h version.h version_nano.h
1819
core.c descriptor.c hotplug.c io.c strerror.c sync.c
1920
libusbi.h

0 commit comments

Comments
 (0)