libusb_stm32.scons 508 B

12345678910111213141516171819202122232425262728
  1. Import("env")
  2. env.Append(
  3. CPPPATH=[
  4. "#/lib/libusb_stm32/inc",
  5. ],
  6. CPPDEFINES=[
  7. ("USB_PMASIZE", "0x400"),
  8. ],
  9. SDK_HEADERS=env.GlobRecursive(
  10. "*.h",
  11. Dir("libusb_stm32/inc"),
  12. ),
  13. )
  14. libenv = env.Clone(FW_LIB_NAME="usb_stm32")
  15. libenv.ApplyLibFlags()
  16. sources = [
  17. "libusb_stm32/src/usbd_core.c",
  18. "libusb_stm32/src/usbd_stm32wb55_devfs.c",
  19. ]
  20. lib = libenv.StaticLibrary("${FW_LIB_NAME}", sources)
  21. libenv.Install("${LIB_DIST_DIR}", lib)
  22. Return("lib")