Skip to content

Conversation

@alexey-lysiuk
Copy link
Contributor

Major update of CMake configuration

  • Support Windows (MSVC and MinGW), Linux, and macOS
  • libusb installation can be specified explicitly by defining LIBUSB_INCLUDE_DIRS and LIBUSB_LIBRARIES CMake variables
  • Support the current structure of Windows libusb package, version 1.0.27 and newer
  • Select proper libusb MSVC libraries for various versions of Visual Studio
  • Remove duplicated and redundant command line options
  • Include libusb.h without libusb-1.0 directory
    • pkg-config returns include string with this directory added
    • Windows packages don't have this directory at all
  • Normalize all CMake commands to lower case
  • Normalize indents by using 4 spaces
  • Install udev rules on Linux only

Build and test the following targets

  • Linux 64-bit using Clang and GCC
  • macOS 64-bit for ARM and Intel
  • Windows 64-bit via MinGW
  • Windows 32- and 64-bit via MSVC

Remove obsolete macOS build script, and update readme accordingly.

* Support Windows (MSVC and MinGW), Linux, and macOS
* `libusb` installation can be specified explicitly by defining `LIBUSB_INCLUDE_DIRS` and `LIBUSB_LIBRARIES` CMake variables
* Support the current structure of Windows `libusb` package, version 1.0.27 and newer
* Select proper `libusb` MSVC libraries for various versions of Visual Studio
* Remove duplicated and redundant command line options
* Include `libusb.h` without `libusb-1.0` directory
  * `pkg-config` returns include string with this directory added
  * Windows packages don't have this directory at all
* Normalize all CMake commands to lower case
* Normalize indents by using 4 spaces
* Install udev rules on Linux only
Build and test the following targets
* Linux 64-bit using Clang and GCC
* macOS 64-bit for ARM and Intel
* Windows 64-bit via MinGW
* Windows 32- and 64-bit via MSVC
* It produced unusable library because of name mangling, C code was compiled as C++
* It supported ARM only, Homebrew on Intel Macs uses different prefix
@alexey-lysiuk
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant