1# SPDX-License-Identifier: Apache-2.0
2
3if(CONFIG_USB_DEVICE_STACK)
4  zephyr_include_directories(${ZEPHYR_BASE}/subsys/usb/device)
5
6  zephyr_sources(
7    usb_device.c
8    usb_descriptor.c
9    usb_transfer.c
10    )
11
12  add_subdirectory(class)
13endif()
14
15zephyr_sources_ifdef(CONFIG_USB_DEVICE_BOS bos.c)
16
17zephyr_sources_ifdef(CONFIG_USB_DEVICE_OS_DESC os_desc.c)
18
19zephyr_sources_ifdef(CONFIG_USB_WORKQUEUE usb_work_q.c)
20
21if(CONFIG_USB_DEVICE_VID EQUAL 0x2FE3)
22  message(WARNING
23    "CONFIG_USB_DEVICE_VID has default value 0x2FE3.
24This value is only for testing and MUST be configured for USB products."
25    )
26
27  if(CONFIG_USB_DEVICE_PID EQUAL 0x100)
28    message(WARNING
29      "CONFIG_USB_DEVICE_PID has default value 0x100.
30This value is only for testing and MUST be configured for USB products."
31      )
32  endif()
33
34endif()
35